Bug 1499057

Summary: WinSCP 5.1x.x erroneously forced to use a weaker key-exchange due to missing patch to OpenSSH compat.c
Product: [Fedora] Fedora Reporter: Robby <robbyke>
Component: opensshAssignee: Jakub Jelen <jjelen>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 27CC: apjkellyuk, dwalsh, jjelen, lkundrak, lvrabec, martin, mattias.ellert, mgrepl, plautrba, tmraz
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
URL: https://winscp.net/forum/viewtopic.php?t=25354
Whiteboard:
Fixed In Version: openssh-7.6p1-2.fc27 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-12-10 05:04:36 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Robby 2017-10-06 00:59:04 UTC
Description of problem:
The commit/patch at
https://github.com/openssh/openssh-portable/commit/2985d4062ebf4204bbd373456a810d558698f9f5
was never picked up and merged, and now that WinSCP has recently released version 5.11(.x), this is causing problems when wanting to use this WinSCP version to connect to an ssh server running on Fedora 25, 26 and 27 that is configured to only accept diffie-hellman-group-exchange-sha256, using this setting in sshd_config:
KexAlgorithms diffie-hellman-group-exchange-sha256

Version-Release number of selected component (if applicable):
7.4p1-4.fc25
7.5p1-3.fc26
7.5p1-5.fc27

How reproducible:
Always

Steps to reproduce:
1. In sshd_config, configure: KexAlgorithms diffie-hellman-group-exchange-sha256
2. Connect with WinSCP version 5.11.1 to the ssh server

Actual results:
WinSCP cannot connect, and sshd logs the following message:
fatal: No supported key exchange algorithms found [preauth]

Expected results:
This should connect fine with the configured key-exchange algorithm.

Additional info:
With the above setting, the client cannot connect at all and when commenting it out, however, it then causes the ssh server to erroneously force a weaker key-exchange (diffie-hellman-group14-sha1) on the user.

This was reported to WinSCP itself: https://winscp.net/forum/viewtopic.php?t=25354
This was also reported to Debian (added as External Bug).

Comment 1 Fedora Update System 2017-11-22 09:06:15 UTC
openssh-7.6p1-2.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2017-96d1995b70

Comment 2 Fedora Update System 2017-11-22 21:42:47 UTC
openssh-7.6p1-2.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-96d1995b70

Comment 3 Fedora Update System 2017-12-10 05:04:36 UTC
openssh-7.6p1-2.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.