diff options
Diffstat (limited to 'kex.c')
-rw-r--r-- | kex.c | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -49,6 +49,10 @@ | |||
49 | #include "dispatch.h" | 49 | #include "dispatch.h" |
50 | #include "monitor.h" | 50 | #include "monitor.h" |
51 | 51 | ||
52 | #ifdef GSSAPI | ||
53 | #include "ssh-gss.h" | ||
54 | #endif | ||
55 | |||
52 | #define KEX_COOKIE_LEN 16 | 56 | #define KEX_COOKIE_LEN 16 |
53 | 57 | ||
54 | #if OPENSSL_VERSION_NUMBER >= 0x00907000L | 58 | #if OPENSSL_VERSION_NUMBER >= 0x00907000L |
@@ -327,6 +331,20 @@ choose_kex(Kex *k, char *client, char *server) | |||
327 | k->kex_type = KEX_DH_GEX_SHA256; | 331 | k->kex_type = KEX_DH_GEX_SHA256; |
328 | k->evp_md = evp_ssh_sha256(); | 332 | k->evp_md = evp_ssh_sha256(); |
329 | #endif | 333 | #endif |
334 | #ifdef GSSAPI | ||
335 | } else if (strncmp(k->name, KEX_GSS_GEX_SHA1_ID, | ||
336 | sizeof(KEX_GSS_GEX_SHA1_ID) - 1) == 0) { | ||
337 | k->kex_type = KEX_GSS_GEX_SHA1; | ||
338 | k->evp_md = EVP_sha1(); | ||
339 | } else if (strncmp(k->name, KEX_GSS_GRP1_SHA1_ID, | ||
340 | sizeof(KEX_GSS_GRP1_SHA1_ID) - 1) == 0) { | ||
341 | k->kex_type = KEX_GSS_GRP1_SHA1; | ||
342 | k->evp_md = EVP_sha1(); | ||
343 | } else if (strncmp(k->name, KEX_GSS_GRP14_SHA1_ID, | ||
344 | sizeof(KEX_GSS_GRP14_SHA1_ID) - 1) == 0) { | ||
345 | k->kex_type = KEX_GSS_GRP14_SHA1; | ||
346 | k->evp_md = EVP_sha1(); | ||
347 | #endif | ||
330 | } else | 348 | } else |
331 | fatal("bad kex alg %s", k->name); | 349 | fatal("bad kex alg %s", k->name); |
332 | } | 350 | } |