Peter's Portfolio

[WDMyCloud] Unable to connect to SSH with “no matching host key type found. Their offer: ssh-dss” error.

Issue Overview

When I connect to WD My Cloud SSH for setting up a backup tunnel for our file server. An error with “unable to connect to SSH with “no matching host key type found. Their offer: ssh-dss” error.” shows to me.

Error Message:
ssh root@myserverip

Unable to negotiate with myserverip port 22: no matching host key type found. Their offer: ssh-dss

Solution

This problem occurs by the version of OpenSSH included in 16.04 disables ssh-dss.
More information: http://www.openssh.com/legacy.html

To solve this problem you should add the option -oHostKeyAlgorithms=+ssh-dss to the SSH command.

ssh -oHostKeyAlgorithms=+ssh-dss root@myserverip
EXAMPLE:
ssh -oHostKeyAlgorithms=+ssh-dss [email protected]

You can also add a host pattern in your ~/.ssh/config so you don’t have to specify the key algorithm every time.

Host myservername
HostName myserverip
HostKeyAlgorithms=+ssh-dss
EXAMPLE:
Host bkkserver
HostName 172.21.85.13
HostKeyAlgorithms=+ssh-dss

 

REF:
https://askubuntu.com/questions/836048/ssh-returns-no-matching-host-key-type-found-their-offer-ssh-dss
http://www.openssh.com/legacy.html

 

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *

這個網站採用 Akismet 服務減少垃圾留言。進一步了解 Akismet 如何處理網站訪客的留言資料