ssh 停留在等待 SSH2_MSG_KEX_ECDH_REPLY 的状态

Far*_* PM 5 ssh

我在另一个国家的服务器上遇到了这个问题。我将 mtu 更改为 1200 到 1500 之间的值,但没有任何变化。我重新安装 openssh 但什么也没发生。请帮忙。tnx.将 HostKeyAlgorithms 强制为一种算法也没有帮助。还从服务器测试了 ssh,它工作正常。我认为问题与网络参数有关,但我不知道应该更改哪些参数。

debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ssh-rsa
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit                                                                                                                                                             > compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit                                                                                                                                                             > compression: none
debug3: send packet: type 30
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
Run Code Online (Sandbox Code Playgroud)

小智 6

我遇到了完全相同的问题并通过以下方式解决:

方案一一次性使用):在命令行提交SSH connect命令时,添加-o KexAlgorithms=ecdh-sha2-nistp521参数

选项2最终):添加KexAlgorithms=ecdh-sha2-nistp521相应的ssh_config文件