summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dbrandom.c6
-rw-r--r--fuzz.h3
-rw-r--r--svr-auth.c7
3 files changed, 6 insertions, 10 deletions
diff --git a/dbrandom.c b/dbrandom.c
index 7d2e118..838f8ca 100644
--- a/dbrandom.c
+++ b/dbrandom.c
@@ -146,7 +146,7 @@ void addrandom(const unsigned char * buf, unsigned int len)
hash_state hs;
#if DROPBEAR_FUZZ
- if (fuzz.fuzzing || fuzz.recordf) {
+ if (fuzz.fuzzing) {
return;
}
#endif
@@ -164,7 +164,7 @@ void addrandom(const unsigned char * buf, unsigned int len)
static void write_urandom()
{
#if DROPBEAR_FUZZ
- if (fuzz.fuzzing || fuzz.recordf) {
+ if (fuzz.fuzzing) {
return;
}
#endif
@@ -204,7 +204,7 @@ void seedrandom() {
clock_t clockval;
#if DROPBEAR_FUZZ
- if (fuzz.fuzzing || fuzz.recordf) {
+ if (fuzz.fuzzing) {
return;
}
#endif
diff --git a/fuzz.h b/fuzz.h
index 42ce494..9316a0a 100644
--- a/fuzz.h
+++ b/fuzz.h
@@ -43,9 +43,6 @@ void fuzz_fake_send_kexdh_reply(void);
struct dropbear_fuzz_options {
int fuzzing;
- // to record an unencrypted stream
- FILE* recordf;
-
// fuzzing input
buffer *input;
struct dropbear_cipher recv_cipher;
diff --git a/svr-auth.c b/svr-auth.c
index bc893f9..fb7b294 100644
--- a/svr-auth.c
+++ b/svr-auth.c
@@ -396,12 +396,11 @@ void send_msg_userauth_failure(int partial, int incrfail) {
/* We delay for 300ms +- 50ms */
delay = 250000 + (delay % 100000);
#if DROPBEAR_FUZZ
- if (!fuzz.fuzzing) {
+ if (!fuzz.fuzzing)
+#endif
+ {
usleep(delay);
}
-#else
- usleep(delay);
-#endif
ses.authstate.failcount++;
}