diff options
author | Matt Johnston <matt@ucc.asn.au> | 2018-02-26 22:44:48 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2018-02-26 22:44:48 +0800 |
commit | 5df73215f887bbc4ebd122e725fe5497d92f511f (patch) | |
tree | 5eaaab331c7f481b736dcd6d0e526de1e2248a14 /svr-session.c | |
parent | 573838a0278e56225bf2a4a1e386105525a6a91a (diff) | |
parent | 3996e93a2045b68cbec6d645e7a166358dac95f7 (diff) |
merge from main
--HG--
branch : fuzz
Diffstat (limited to 'svr-session.c')
-rw-r--r-- | svr-session.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/svr-session.c b/svr-session.c index 4b351e6..b097ff2 100644 --- a/svr-session.c +++ b/svr-session.c @@ -43,6 +43,7 @@ #include "fuzz.h" static void svr_remoteclosed(void); +static void svr_algos_initialise(void); struct serversession svr_ses; /* GLOBAL */ @@ -103,6 +104,7 @@ void svr_session(int sock, int childpipe) { svr_authinitialise(); chaninitialise(svr_chantypes); svr_chansessinitialise(); + svr_algos_initialise(); /* for logging the remote address */ get_socket_address(ses.sock_in, NULL, NULL, &host, &port, 0); @@ -254,3 +256,14 @@ static void svr_remoteclosed() { } +static void svr_algos_initialise(void) { +#if DROPBEAR_DH_GROUP1 && DROPBEAR_DH_GROUP1_CLIENTONLY + algo_type *algo; + for (algo = sshkex; algo->name; algo++) { + if (strcmp(algo->name, "diffie-hellman-group1-sha1") == 0) { + algo->usable = 0; + } + } +#endif +} + |