diff options
author | Matt Johnston <matt@ucc.asn.au> | 2017-05-12 23:14:54 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2017-05-12 23:14:54 +0800 |
commit | b650b9761888ad18c4ffb84dd64625e0d045199c (patch) | |
tree | 5726abac050102a977cecae831c08374e855dc5d /svr-auth.c | |
parent | eebfc9e3c8c3eb8a0b0dc366c417a7ec6e045f2b (diff) | |
download | dropbear-b650b9761888ad18c4ffb84dd64625e0d045199c.tar.gz |
copy over some fuzzing code from AFL branch
Diffstat (limited to 'svr-auth.c')
-rw-r--r-- | svr-auth.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -358,7 +358,11 @@ void send_msg_userauth_failure(int partial, int incrfail) { genrandom((unsigned char*)&delay, sizeof(delay)); /* We delay for 300ms +- 50ms */ delay = 250000 + (delay % 100000); - usleep(delay); +#ifndef DROPBEAR_FUZZ + if (!opts.fuzz.fuzzing) { + usleep(delay); + } +#endif ses.authstate.failcount++; } |