Initialise fuzzing for ssz

This commit is contained in:
Kirk Baird 2019-02-20 14:16:07 +11:00
parent e9f4cc134e
commit 3517ef6513
No known key found for this signature in database
GPG Key ID: BF864B7ED0BEA33F
3 changed files with 33 additions and 0 deletions

4
eth2/utils/ssz/fuzz/.gitignore vendored Normal file
View File

@ -0,0 +1,4 @@
target
corpus
artifacts

View File

@ -0,0 +1,22 @@
[package]
name = "ssz-fuzz"
version = "0.0.1"
authors = ["Automatically generated"]
publish = false
[package.metadata]
cargo-fuzz = true
[dependencies.ssz]
path = ".."
[dependencies.libfuzzer-sys]
git = "https://github.com/rust-fuzz/libfuzzer-sys.git"
# Prevent this from interfering with workspaces
[workspace]
members = ["."]
[[bin]]
name = "fuzz_target_1"
path = "fuzz_targets/fuzz_target_1.rs"

View File

@ -0,0 +1,7 @@
#![no_main]
#[macro_use] extern crate libfuzzer_sys;
extern crate ssz;
fuzz_target!(|data: &[u8]| {
// fuzzed code goes here
});