Operating System - HP-UX
1834455 Members
2697 Online
110067 Solutions
New Discussion

Re: SSH automatic login error

 
sheevm
Regular Advisor

SSH automatic login error


Hi All,

We are able to ssh in, but when we attempt to load certificiates and automatically log in, we are denied and given a 'man-in-the-middle' error.

Does anyone know what this error mean?

Thanks
Rajim

be good and do good
6 REPLIES 6
IT_2007
Honored Contributor

Re: SSH automatic login error

remove entry in ~/.ssh/known_hosts for the server name to login.
sheevm
Regular Advisor

Re: SSH automatic login error

Can you please tell me where this file is located? Is this a variable in SSHD_CONFIG file? or is this a separate file?

You really save my day in life if this fixes the problem.

Thanks a million

Rajim
be good and do good
Jonathan Fife
Honored Contributor

Re: SSH automatic login error

To follow up on IT_2007's post --

Basically the man-in-the-middle is an SSH attack where someone intercepts your login request and then forwards it onto the server using its own IP as the source, hoping to establish a secure communication with the server, and then to establish a second secure communication with the client using the data returned from the server. It could then de-encrypt all communications back and forth, and re-encrypt them when it forwards them on to the intended destination. Neither the host nor the client would know that someone was de-encrypting and re-encrypting the data mid-stream.

Your server thinks someone is trying to pull this attack and thus denies the attempted login. The file is located in $HOME/.ssh/ for whatever user is logging in.
Decay is inherent in all compounded things. Strive on with diligence
Steven E. Protter
Exalted Contributor

Re: SSH automatic login error

Shalom,

ssh is smart, stores info in /home/.ssh/known_hosts

If it sees a key change or something similar it squawks for good reason.

Remove the offending entry which is often referred to by line number.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
sheevm
Regular Advisor

Re: SSH automatic login error

Hi,

This solution seems to eliminate the "Middle man attack" error. But it keeps prompting for password. What is the way to make it work to automatically login without password?

Thanks.
Rajim
be good and do good
IT_2007
Honored Contributor

Re: SSH automatic login error

copy id_dsa.pub key to authorized_keys file and copy to the destination server at user home directory/.ssh directory.