diff options
author | Matt Johnston <matt@ucc.asn.au> | 2020-10-18 15:08:54 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2020-10-18 15:08:54 +0800 |
commit | 33eba22966a897cb4fca2395912176e2713b050d (patch) | |
tree | afefc1cd425bee9529ba227894d8ae50844cfa3b /cli-kex.c | |
parent | 282fc81981c57e53b6aaa6d3189b66b4a229f0a8 (diff) |
Add fuzzer-client_nomaths, fix client fuzzer
--HG--
branch : fuzz
Diffstat (limited to 'cli-kex.c')
-rw-r--r-- | cli-kex.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -46,6 +46,13 @@ void send_msg_kexdh_init() { TRACE(("send_msg_kexdh_init()")) CHECKCLEARTOWRITE(); + +#if DROPBEAR_FUZZ + if (fuzz.fuzzing && fuzz.skip_kexmaths) { + return; + } +#endif + buf_putbyte(ses.writepayload, SSH_MSG_KEXDH_INIT); switch (ses.newkeys->algo_kex->mode) { #if DROPBEAR_NORMAL_DH @@ -98,6 +105,12 @@ void recv_msg_kexdh_reply() { unsigned char* keyblob = NULL; TRACE(("enter recv_msg_kexdh_reply")) + +#if DROPBEAR_FUZZ + if (fuzz.fuzzing && fuzz.skip_kexmaths) { + return; + } +#endif if (cli_ses.kex_state != KEXDH_INIT_SENT) { dropbear_exit("Received out-of-order kexdhreply"); |