summaryrefslogtreecommitdiffstats
path: root/usr.bin/ssh/dh.c
diff options
context:
space:
mode:
authordjm <djm@openbsd.org>2004-08-04 10:37:52 +0000
committerdjm <djm@openbsd.org>2004-08-04 10:37:52 +0000
commit18e35b19cf9036e427d90b32ee2970adf12db3c3 (patch)
tree65eafd51e25d0846cfc29999f7cd8a4fbcb4f2d4 /usr.bin/ssh/dh.c
parentKNF and a spanking in the ddb helper code. (diff)
downloadwireguard-openbsd-18e35b19cf9036e427d90b32ee2970adf12db3c3.tar.xz
wireguard-openbsd-18e35b19cf9036e427d90b32ee2970adf12db3c3.zip
return group14 when no primes found - fixes hang on empty /etc/moduli;
ok markus@
Diffstat (limited to 'usr.bin/ssh/dh.c')
-rw-r--r--usr.bin/ssh/dh.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/dh.c b/usr.bin/ssh/dh.c
index 176fb74696f..044d869fb88 100644
--- a/usr.bin/ssh/dh.c
+++ b/usr.bin/ssh/dh.c
@@ -23,7 +23,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: dh.c,v 1.30 2004/06/13 12:53:24 djm Exp $");
+RCSID("$OpenBSD: dh.c,v 1.31 2004/08/04 10:37:52 djm Exp $");
#include "xmalloc.h"
@@ -145,7 +145,7 @@ choose_dh(int min, int wantbits, int max)
if (bestcount == 0) {
fclose(f);
logit("WARNING: no suitable primes in %s", _PATH_DH_PRIMES);
- return (NULL);
+ return (dh_new_group14());
}
linenum = 0;