]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream: Better compat tests with old PuTTY.
authordtucker@openbsd.org <dtucker@openbsd.org>
Tue, 31 Aug 2021 06:13:23 +0000 (06:13 +0000)
committerDarren Tucker <dtucker@dtucker.net>
Tue, 31 Aug 2021 07:08:38 +0000 (17:08 +1000)
When running PuTTY interop tests and using a PuTTY version older than
0.76, re-enable the ssh-rsa host key algorithm (the 256 and 512 variants
of RSA were added some time between 0.73 and 0.76).

OpenBSD-Regress-ID: e6138d6987aa705fa1e4f216db0bb386e1ff38e1

regress/putty-ciphers.sh
regress/putty-kex.sh
regress/putty-transfer.sh

index ace882714935e6d8b5e5263e4ba3240f34459aed..71755c07f6c9257001bb58ccf29202a8b4b7f143 100644 (file)
@@ -1,4 +1,4 @@
-#      $OpenBSD: putty-ciphers.sh,v 1.7 2020/01/23 03:35:07 dtucker Exp $
+#      $OpenBSD: putty-ciphers.sh,v 1.8 2021/08/31 06:13:23 dtucker Exp $
 #      Placed in the Public Domain.
 
 tid="putty ciphers"
@@ -7,6 +7,12 @@ if test "x$REGRESS_INTEROP_PUTTY" != "xyes" ; then
        fatal "putty interop tests not enabled"
 fi
 
+# Re-enable ssh-rsa on older PuTTY versions.
+oldver="`${PLINK} --version | awk '/plink: Release/{if ($3<0.76)print "yes"}'`"
+if [ "x$oldver" = "xyes" ]; then
+       echo "HostKeyalgorithms +ssh-rsa" >> sshd_config
+fi
+
 for c in aes 3des aes128-ctr aes192-ctr aes256-ctr chacha20 ; do
        verbose "$tid: cipher $c"
        cp ${OBJ}/.putty/sessions/localhost_proxy \
index c9214f677a4d176485d2d3f6fb90ae046de1f719..ba32cf0b689962659ded2c5642d762dadcc52831 100644 (file)
@@ -1,4 +1,4 @@
-#      $OpenBSD: putty-kex.sh,v 1.5 2020/01/23 03:24:38 dtucker Exp $
+#      $OpenBSD: putty-kex.sh,v 1.6 2021/08/31 06:13:23 dtucker Exp $
 #      Placed in the Public Domain.
 
 tid="putty KEX"
@@ -7,6 +7,12 @@ if test "x$REGRESS_INTEROP_PUTTY" != "xyes" ; then
        fatal "putty interop tests not enabled"
 fi
 
+# Re-enable ssh-rsa on older PuTTY versions.
+oldver="`${PLINK} --version | awk '/plink: Release/{if ($3<0.76)print "yes"}'`"
+if [ "x$oldver" = "xyes" ]; then
+       echo "HostKeyalgorithms +ssh-rsa" >> sshd_config
+fi
+
 for k in dh-gex-sha1 dh-group1-sha1 dh-group14-sha1 ecdh ; do
        verbose "$tid: kex $k"
        cp ${OBJ}/.putty/sessions/localhost_proxy \
index e36e8284bb84b0bb99dd0be4aaa3bbb4ec3bd0fb..d3e75cb5a523ef7000120b678f3b5f16379e8ec5 100644 (file)
@@ -1,4 +1,4 @@
-#      $OpenBSD: putty-transfer.sh,v 1.7 2020/01/23 11:19:12 dtucker Exp $
+#      $OpenBSD: putty-transfer.sh,v 1.8 2021/08/31 06:13:23 dtucker Exp $
 #      Placed in the Public Domain.
 
 tid="putty transfer data"
@@ -7,6 +7,12 @@ if test "x$REGRESS_INTEROP_PUTTY" != "xyes" ; then
        fatal "putty interop tests not enabled"
 fi
 
+# Re-enable ssh-rsa on older PuTTY versions.
+oldver="`${PLINK} --version | awk '/plink: Release/{if ($3<0.76)print "yes"}'`"
+if [ "x$oldver" = "xyes" ]; then
+       echo "HostKeyalgorithms +ssh-rsa" >> sshd_config
+fi
+
 if [ "`${SSH} -Q compression`" = "none" ]; then
        comp="0"
 else