#!/linuxSucks/Clean Ecdsa Host Key
Dec 01, 2019Sometimes the terminal in Unix/Linux like system shows this warning, when you try to connect to a remote server via ssh
@ 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 the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
06:ea:f1:f8:db:75:5c:0c:af:15:d7:99:2d:ef:08:2a.
Please contact your system administrator.
Add correct host key in /home/user/.ssh/known_hosts to get rid of this message.
Offending key in /home/user/.ssh/known_hosts:4
RSA host key for domain.com has changed and you have requested strict checking. Host key verification failed.
Remove the cached key for IP_ADDRESS on the local machine:
ssh-keygen -R SEVER_IP_ADDRESS
Find the IP address of the server. Not the IP address of your computer.
If you are using ssh terminal (Secure Shell App) in chromeOs or Google chrome it will show something like this warning:
@ 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 the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
06:ea:f1:f8:db:75:5c:0c:af:15:d7:99:2d:ef:08:2a.
Please contact your system administrator.
Add correct host key in /home/user/.ssh/known_hosts to get rid of this message.
Offending key in /home/user/.ssh/known_hosts:4 **<--This is the index number**
RSA host key for domain.com has changed and you have requested strict checking. Host key verification failed.
If the above is the case just press Ctrl-Shift-J from the Secure Shell window to open the JS console, and type:
term_.command.removeKnownHostByIndex(index)
Replace index for the number of your index. After you hit enter it will show something like this:
ECDSA host key for nameHost.local has changed and you have requested strict checking.