I had wondered why we couldn't just catch SSH_MSG_UNIMPLEMENTED, and
now I know: OpenSSH disconnects if the client sends
SSH_MSG_KEX_DH_GEX_REQUEST.
(wc_match("OpenSSH_2.[235]*", imp)))) {
/*
* These versions only support the original (pre-RFC4419)
- * SSH-2 GEX request.
+ * SSH-2 GEX request, and disconnect with a protocol error if
+ * we use the newer version.
*/
ssh->remote_bugs |= BUG_SSH2_OLDGEX;
logevent("We believe remote version has outdated SSH-2 GEX");