Mercurial > dropbear
diff fuzz-common.c @ 1377:d4cc85e6c569 fuzz
rearrange, all fuzzers now call fuzzer_set_input()
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Thu, 25 May 2017 22:21:49 +0800 |
parents | 9891bc31a1b3 |
children | f03cfe9c76ac |
line wrap: on
line diff
--- a/fuzz-common.c Thu May 25 22:21:23 2017 +0800 +++ b/fuzz-common.c Thu May 25 22:21:49 2017 +0800 @@ -31,23 +31,7 @@ memset(&ses, 0x0, sizeof(ses)); memset(&svr_ses, 0x0, sizeof(svr_ses)); - - // get prefix. input format is - // string prefix - // uint32 wrapfd seed - // ... to be extended later - // [bytes] ssh input stream - - // be careful to avoid triggering buffer.c assertions - if (fuzz.input->len < 8) { - return DROPBEAR_FAILURE; - } - size_t prefix_size = buf_getint(fuzz.input); - if (prefix_size != 4) { - return DROPBEAR_FAILURE; - } - uint32_t wrapseed = buf_getint(fuzz.input); - wrapfd_setup(wrapseed); + wrapfd_setup(); fuzz_seed();