summaryrefslogtreecommitdiff
path: root/kexecdhc.c
diff options
context:
space:
mode:
Diffstat (limited to 'kexecdhc.c')
-rw-r--r--kexecdhc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/kexecdhc.c b/kexecdhc.c
index 3f362c5b1..90220ce82 100644
--- a/kexecdhc.c
+++ b/kexecdhc.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: kexecdhc.c,v 1.9 2015/01/19 20:16:15 markus Exp $ */ 1/* $OpenBSD: kexecdhc.c,v 1.10 2015/01/26 06:10:03 djm Exp $ */
2/* 2/*
3 * Copyright (c) 2001 Markus Friedl. All rights reserved. 3 * Copyright (c) 2001 Markus Friedl. All rights reserved.
4 * Copyright (c) 2010 Damien Miller. All rights reserved. 4 * Copyright (c) 2010 Damien Miller. All rights reserved.
@@ -124,7 +124,9 @@ input_kex_ecdh_reply(int type, u_int32_t seq, void *ctxt)
124 (r = sshkey_from_blob(server_host_key_blob, sbloblen, 124 (r = sshkey_from_blob(server_host_key_blob, sbloblen,
125 &server_host_key)) != 0) 125 &server_host_key)) != 0)
126 goto out; 126 goto out;
127 if (server_host_key->type != kex->hostkey_type) { 127 if (server_host_key->type != kex->hostkey_type ||
128 (kex->hostkey_type == KEY_ECDSA &&
129 server_host_key->ecdsa_nid != kex->hostkey_nid)) {
128 r = SSH_ERR_KEY_TYPE_MISMATCH; 130 r = SSH_ERR_KEY_TYPE_MISMATCH;
129 goto out; 131 goto out;
130 } 132 }