diff options
author | Damien Miller <djm@mindrot.org> | 2002-03-13 12:47:54 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2002-03-13 12:47:54 +1100 |
commit | 646e7cf3d7e7d4231c2d97d27c09fe5fe1d749e2 (patch) | |
tree | a693368c47d2d044514878fbb1516f87b487f78b /kexdh.c | |
parent | 29bdd2c9bca2737e7a246ed50fd827a6ccba0c61 (diff) |
Import of Niels Provos' 20020312 ssh-complete.diff
PAM, Cygwin and OSF SIA will not work for sure
Diffstat (limited to 'kexdh.c')
-rw-r--r-- | kexdh.c | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -37,6 +37,12 @@ RCSID("$OpenBSD: kexdh.c,v 1.17 2002/02/28 15:46:33 markus Exp $"); | |||
37 | #include "packet.h" | 37 | #include "packet.h" |
38 | #include "dh.h" | 38 | #include "dh.h" |
39 | #include "ssh2.h" | 39 | #include "ssh2.h" |
40 | #include "monitor.h" | ||
41 | #include "monitor_wrap.h" | ||
42 | |||
43 | /* Imports */ | ||
44 | extern int use_privsep; | ||
45 | extern int mm_recvfd; | ||
40 | 46 | ||
41 | static u_char * | 47 | static u_char * |
42 | kex_dh_hash( | 48 | kex_dh_hash( |
@@ -275,7 +281,12 @@ kexdh_server(Kex *kex) | |||
275 | 281 | ||
276 | /* sign H */ | 282 | /* sign H */ |
277 | /* XXX hashlen depends on KEX */ | 283 | /* XXX hashlen depends on KEX */ |
278 | key_sign(server_host_key, &signature, &slen, hash, 20); | 284 | if (use_privsep) |
285 | mm_key_sign(mm_recvfd, | ||
286 | kex->host_key_index(server_host_key), | ||
287 | &signature, &slen, hash, 20); | ||
288 | else | ||
289 | key_sign(server_host_key, &signature, &slen, hash, 20); | ||
279 | 290 | ||
280 | /* destroy_sensitive_data(); */ | 291 | /* destroy_sensitive_data(); */ |
281 | 292 | ||