From b214acbb0c58a1ad1097058c22fb3b5509b98a85 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 21 Mar 2025 14:36:46 +0100 Subject: [PATCH] sshserver: fix excluding obsolete client config lines It was already excluded for OpenSSH-Windows. Extend it to all OpenSSH above v7.3. Syncing up this logic with the sshd server config. Fixing, in `sftp_server.log`: ``` log/server/curl_sftp_config line 33: Unsupported option "rhostsrsaauthentication" log/server/curl_sftp_config line 34: Unsupported option "rsaauthentication" ``` `no` has been the default for these since OpenSSH 3.3 (2002-06-21). Closes #16784 --- tests/sshserver.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/sshserver.pl b/tests/sshserver.pl index 3914ad888a..063e37973a 100755 --- a/tests/sshserver.pl +++ b/tests/sshserver.pl @@ -1016,8 +1016,8 @@ push @cfgarr, 'PasswordAuthentication no'; push @cfgarr, 'PreferredAuthentications publickey'; push @cfgarr, 'PubkeyAuthentication yes'; -# RSA authentication options are not supported by OpenSSH for Windows -if (!($sshdid =~ /OpenSSH-Windows/ || pathhelp::os_is_win())) { +# RSA authentication options are deprecated by newer OpenSSH +if (!($sshid =~ /OpenSSH/) || ($sshvernum <= 730)) { push @cfgarr, 'RhostsRSAAuthentication no'; push @cfgarr, 'RSAAuthentication no'; }