Added more fuzz targets
This commit is contained in:
@@ -10,17 +10,24 @@ cargo-fuzz = true
|
|||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
libfuzzer-sys = { version = "0.3"}
|
libfuzzer-sys = { version = "0.3"}
|
||||||
arrayref = "0.3.6"
|
fuzz_helper = { path = "fuzz_helper" }
|
||||||
libtock_drivers = { path = "../third_party/libtock-drivers" }
|
|
||||||
crypto = { path = "../libraries/crypto", features = ['std'] }
|
|
||||||
cbor = { path = "../libraries/cbor", features = ['std'] }
|
|
||||||
ctap2 = { path = "..", features = ['std', 'ram_storage'] }
|
|
||||||
lang_items = { path = "../third_party/lang-items", features = ['std'] }
|
|
||||||
|
|
||||||
# Prevent this from interfering with workspaces
|
# Prevent this from interfering with workspaces
|
||||||
[workspace]
|
[workspace]
|
||||||
members = ["."]
|
members = ["."]
|
||||||
|
|
||||||
|
[[bin]]
|
||||||
|
name = "fuzz_target_process_ctap1"
|
||||||
|
path = "fuzz_targets/fuzz_target_process_ctap1.rs"
|
||||||
|
test = false
|
||||||
|
doc = false
|
||||||
|
|
||||||
|
[[bin]]
|
||||||
|
name = "fuzz_target_process_ctap2_make_credential"
|
||||||
|
path = "fuzz_targets/fuzz_target_process_ctap2_make_credential.rs"
|
||||||
|
test = false
|
||||||
|
doc = false
|
||||||
|
|
||||||
[[bin]]
|
[[bin]]
|
||||||
name = "fuzz_target_split_assemble"
|
name = "fuzz_target_split_assemble"
|
||||||
path = "fuzz_targets/fuzz_target_split_assemble.rs"
|
path = "fuzz_targets/fuzz_target_split_assemble.rs"
|
||||||
|
|||||||
9
fuzz/fuzz_targets/fuzz_target_process_ctap1.rs
Normal file
9
fuzz/fuzz_targets/fuzz_target_process_ctap1.rs
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
#![no_main]
|
||||||
|
|
||||||
|
use fuzz_helper::{process_input, InputType};
|
||||||
|
use libfuzzer_sys::fuzz_target;
|
||||||
|
|
||||||
|
// Fuzz inputs as CTAP1 U2F raw message.
|
||||||
|
fuzz_target!(|data: &[u8]| {
|
||||||
|
process_input(data, InputType::Ctap1);
|
||||||
|
});
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
#![no_main]
|
||||||
|
|
||||||
|
use fuzz_helper::{process_input, InputType};
|
||||||
|
use libfuzzer_sys::fuzz_target;
|
||||||
|
|
||||||
|
// Fuzz inputs as CTAP2 make credential command parameters encoded in cbor.
|
||||||
|
fuzz_target!(|data: &[u8]| {
|
||||||
|
process_input(data, InputType::CborMakeCredentialParameter);
|
||||||
|
});
|
||||||
Reference in New Issue
Block a user