Folks,
I am experiencing an issue where there is a php script which ssh into remote host and get the output of few commands. It was working fine but all of sudden with no changes, it stopped working.
When I try ssh manually using the same key the script use, it works absolutely fine. However this issue happens only through php script.
Below is the command in the script,
Quote:
shell_exec("echo \<FONT FACE="courier"\>;/usr/bin/ssh -i //var/www/html/lte/id_rsa root@xxx
|
I am seeing the http error in log file whenever i load that php script.
Quote:
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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
7f:6b:72:2d:49:38:35:9d:51:a1:af:0f:9c:b3:8c:6f.
Please contact your system administrator.
Add correct host key in /var/www/.ssh/known_hosts to get rid of this message.
Offending key in /var/www/.ssh/known_hosts:106
RSA host key for xxxxx has changed and you have requested strict checking.
Host key verification failed.
|
I know the error is so familiar but I have tried all possible ways mentioned in internet. The error which says "Offending key in /var/www/.ssh/known_hosts:106" . I dont find line 106 on known_host file on both server and client.
I have tried ssh-keygen -R <hostname> on both server and client but no luck.
Could someone give me hand please?