ssh login error fix solution:ECDSA host key for xxx has changed and you have

忘是亡心i 2023-01-20 06:55 53阅读 0赞

ssh login error:ECDSA host key for xxx has changed and you have

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

Linux fix solution:

  1. mkdir -p ~/.ssh
  2. echo 'Host *
  3. StrictHostKeyChecking no
  4. UserKnownHostsFile=/dev/null'>~/.ssh/config

Windows fix solution:

  1. md C:\Users\yourcurrentuser\.ssh
  2. echo 'Host *
  3. StrictHostKeyChecking no
  4. UserKnownHostsFile=/dev/null'>C:\Users\yourcurrentuser\.ssh\config

发表评论

表情:
评论列表 (有 0 条评论,53人围观)

还没有评论,来说两句吧...

相关阅读