diff options
author | Damien Miller <djm@mindrot.org> | 2015-12-15 15:25:04 +0000 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2015-12-21 16:09:56 +0000 |
commit | 480b475c69faf9cfa748cc445e36201bc7a81b80 (patch) | |
tree | 28522d34ef15018620d3629926320f3b0e72e3d8 | |
parent | a466a627b806905df9c7583af7edcf39e9481201 (diff) |
upstream commit
unbreak connections with peers that set first_kex_follows;
fix from Matt Johnston va bz#2515
Origin: backport, http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/kex.c.diff?r1=1.114&r2=1.115
Forwarded: not-needed
Bug-Ubuntu: https://bugs.launchpad.net/bugs/1526357
Patch-Name: backport-fix-first-kex-follows.patch
-rw-r--r-- | kex.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -286,11 +286,11 @@ kex_buf2prop(struct sshbuf *raw, int *first_kex_follows, char ***propp) | |||
286 | debug2("kex_parse_kexinit: %s", proposal[i]); | 286 | debug2("kex_parse_kexinit: %s", proposal[i]); |
287 | } | 287 | } |
288 | /* first kex follows / reserved */ | 288 | /* first kex follows / reserved */ |
289 | if ((r = sshbuf_get_u8(b, &v)) != 0 || | 289 | if ((r = sshbuf_get_u8(b, &v)) != 0 || /* first_kex_follows */ |
290 | (r = sshbuf_get_u32(b, &i)) != 0) | 290 | (r = sshbuf_get_u32(b, &i)) != 0) /* reserved */ |
291 | goto out; | 291 | goto out; |
292 | if (first_kex_follows != NULL) | 292 | if (first_kex_follows != NULL) |
293 | *first_kex_follows = i; | 293 | *first_kex_follows = v; |
294 | debug2("kex_parse_kexinit: first_kex_follows %d ", v); | 294 | debug2("kex_parse_kexinit: first_kex_follows %d ", v); |
295 | debug2("kex_parse_kexinit: reserved %u ", i); | 295 | debug2("kex_parse_kexinit: reserved %u ", i); |
296 | r = 0; | 296 | r = 0; |