VScode remote ssh 异常相关

remote host key has changed port forwarding is disabled

点击下方终端机查看详情

1
2
3
4
5
6
7
8
9
10
11
12
13
14
$ ssh ec2-user@ec2-192-168-1-1.compute-1.amazonaws.com
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
SHA256:hotsxb/qVi1/ycUU2wXF6mfGH++Yk7WYZv0r+tIhg4I.
Please contact your system administrator.
Add correct host key in /Users/scott/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /Users/scott/.ssh/known_hosts:47
ECDSA host key for ec2-192-168-1-1.compute-1.amazonaws.com has changed and you have requested strict checking.
Host key verification failed.

即可发现问题出现在.ssh/known_hosts,这便是 macOS 的存根路径,打开访达,前往文件夹,编辑删除对应 IP 即可。

作者

Catooilg

发布于

2021-07-13

更新于

2023-02-05

许可协议

评论