Ticket #275 (closed defect: fixed)

Opened 7 years ago

Last modified 7 years ago

Unable to connect to a server if an unsupported key type is present in known_hosts.

Reported by: Alexander De Sousa Macedo <aphanic@hotmail.com> Owned by: alamaison
Priority: major (affects peripheral workflow) Milestone:
Component: libssh2 Version: 0.8.0
Keywords: Cc:


I just setup a local SSH and SFTP server using OpenSSH 6.5 and upon installation various server keys were also generated: ECDSA, RSA, DSA. When connecting via SSH to the machine the public key included in the known_hosts file is the ECDSA one (by default, unless RSA is explicitly required).

If you try to access the machine via SFTP through Swish after that key is in known_hosts an error dialog appears explaining that the key format is unknown. I couldn't select the text of the actual exception but it can be seen in the attached image.

If ECDSA keys are not supported in my opinion such keys should be ignored and the server asked for one of a supported format, unless there's already one present besides the unsupported one in the file.

The Swish version I was using is actually 0.8.1 but it isn't available jet in the version selector, the operating system is a 64-bit Windows 8.1 Pro.


Swish - Unkown key format.png Download (146.3 KB) - added by Alexander De Sousa Macedo <aphanic@hotmail.com> 7 years ago.
Image with the dialog showing the exception message.

Change History

Changed 7 years ago by Alexander De Sousa Macedo <aphanic@hotmail.com>

Image with the dialog showing the exception message.

comment:1 Changed 7 years ago by alamaison

  • Status changed from new to closed
  • Resolution set to fixed

In [b4a1dab80593c16cf705db1bde37e875c530082e/swish]:

Don't error when known_hosts contains keys in unrecognised format.

Fixes #275.

Note: See TracTickets for help on using tickets.