summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--kexgen.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/kexgen.c b/kexgen.c
index bb0cb5c1b..2abbb9ef6 100644
--- a/kexgen.c
+++ b/kexgen.c
@@ -101,6 +101,7 @@ kex_gen_client(struct ssh *ssh)
101 int r; 101 int r;
102 102
103 switch (kex->kex_type) { 103 switch (kex->kex_type) {
104#ifdef WITH_OPENSSL
104 case KEX_DH_GRP1_SHA1: 105 case KEX_DH_GRP1_SHA1:
105 case KEX_DH_GRP14_SHA1: 106 case KEX_DH_GRP14_SHA1:
106 case KEX_DH_GRP14_SHA256: 107 case KEX_DH_GRP14_SHA256:
@@ -111,6 +112,7 @@ kex_gen_client(struct ssh *ssh)
111 case KEX_ECDH_SHA2: 112 case KEX_ECDH_SHA2:
112 r = kex_ecdh_keypair(kex); 113 r = kex_ecdh_keypair(kex);
113 break; 114 break;
115#endif
114 case KEX_C25519_SHA256: 116 case KEX_C25519_SHA256:
115 r = kex_c25519_keypair(kex); 117 r = kex_c25519_keypair(kex);
116 break; 118 break;
@@ -167,6 +169,7 @@ input_kex_gen_reply(int type, u_int32_t seq, struct ssh *ssh)
167 169
168 /* compute shared secret */ 170 /* compute shared secret */
169 switch (kex->kex_type) { 171 switch (kex->kex_type) {
172#ifdef WITH_OPENSSL
170 case KEX_DH_GRP1_SHA1: 173 case KEX_DH_GRP1_SHA1:
171 case KEX_DH_GRP14_SHA1: 174 case KEX_DH_GRP14_SHA1:
172 case KEX_DH_GRP14_SHA256: 175 case KEX_DH_GRP14_SHA256:
@@ -177,6 +180,7 @@ input_kex_gen_reply(int type, u_int32_t seq, struct ssh *ssh)
177 case KEX_ECDH_SHA2: 180 case KEX_ECDH_SHA2:
178 r = kex_ecdh_dec(kex, server_blob, &shared_secret); 181 r = kex_ecdh_dec(kex, server_blob, &shared_secret);
179 break; 182 break;
183#endif
180 case KEX_C25519_SHA256: 184 case KEX_C25519_SHA256:
181 r = kex_c25519_dec(kex, server_blob, &shared_secret); 185 r = kex_c25519_dec(kex, server_blob, &shared_secret);
182 break; 186 break;
@@ -259,6 +263,7 @@ input_kex_gen_init(int type, u_int32_t seq, struct ssh *ssh)
259 263
260 /* compute shared secret */ 264 /* compute shared secret */
261 switch (kex->kex_type) { 265 switch (kex->kex_type) {
266#ifdef WITH_OPENSSL
262 case KEX_DH_GRP1_SHA1: 267 case KEX_DH_GRP1_SHA1:
263 case KEX_DH_GRP14_SHA1: 268 case KEX_DH_GRP14_SHA1:
264 case KEX_DH_GRP14_SHA256: 269 case KEX_DH_GRP14_SHA256:
@@ -271,6 +276,7 @@ input_kex_gen_init(int type, u_int32_t seq, struct ssh *ssh)
271 r = kex_ecdh_enc(kex, client_pubkey, &server_pubkey, 276 r = kex_ecdh_enc(kex, client_pubkey, &server_pubkey,
272 &shared_secret); 277 &shared_secret);
273 break; 278 break;
279#endif
274 case KEX_C25519_SHA256: 280 case KEX_C25519_SHA256:
275 r = kex_c25519_enc(kex, client_pubkey, &server_pubkey, 281 r = kex_c25519_enc(kex, client_pubkey, &server_pubkey,
276 &shared_secret); 282 &shared_secret);