summaryrefslogtreecommitdiff
path: root/sshd.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2014-01-10 10:59:24 +1100
committerDamien Miller <djm@mindrot.org>2014-01-10 10:59:24 +1100
commit58cd63bc63038acddfb4051ed14e11179d8f4941 (patch)
treeeb65dbe7f28e207756131ad75ec746310ff5eaa2 /sshd.c
parentb3051d01e505c9c2dc00faab472a0d06fa6b0e65 (diff)
- djm@cvs.openbsd.org 2014/01/09 23:26:48
[sshconnect.c sshd.c] ban clients/servers that suffer from SSH_BUG_DERIVEKEY, they are ancient, deranged and might make some attacks on KEX easier; ok markus@
Diffstat (limited to 'sshd.c')
-rw-r--r--sshd.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sshd.c b/sshd.c
index 87795bea5..60b416e30 100644
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sshd.c,v 1.413 2013/12/30 23:52:28 djm Exp $ */ 1/* $OpenBSD: sshd.c,v 1.414 2014/01/09 23:26:48 djm Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -502,9 +502,14 @@ sshd_exchange_identification(int sock_in, int sock_out)
502 get_remote_ipaddr(), client_version_string); 502 get_remote_ipaddr(), client_version_string);
503 cleanup_exit(255); 503 cleanup_exit(255);
504 } 504 }
505 if ((datafellows & SSH_BUG_RSASIGMD5) != 0) 505 if ((datafellows & SSH_BUG_RSASIGMD5) != 0) {
506 logit("Client version \"%.100s\" uses unsafe RSA signature " 506 logit("Client version \"%.100s\" uses unsafe RSA signature "
507 "scheme; disabling use of RSA keys", remote_version); 507 "scheme; disabling use of RSA keys", remote_version);
508 }
509 if ((datafellows & SSH_BUG_DERIVEKEY) != 0) {
510 fatal("Client version \"%.100s\" uses unsafe key agreement; "
511 "refusing connection", remote_version);
512 }
508 513
509 mismatch = 0; 514 mismatch = 0;
510 switch (remote_major) { 515 switch (remote_major) {