SSH login without password

1
2
3
4
5
ssh-keygen -t rsa -b 2048
set passphase for id_rsa
copy id_rsa.pub to remoteIP's folder .ssh/
cat id_rsa >> authorized_keys
chmod 640 authorized_keys

Login with ssh

1
2
3
4
5
ssh-agent bash --login -i
ssh-add
ssh felix@remoteIP OR ssh -A felix@remoteIP (agent forwarding)
OR
ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no felix@remoteIP (disable host key checking)

Login with putty

1
2
3
4
5
run puttygen.exe to convert id_rsa to putty's format
run pageant.exe to load private key
plink.exe felix@remoteIP
config as enable X11 forwarding in putty, and save the session as passwordless.
plink.exe -load passwordless

Reference

http://linuxcommando.blogspot.hk/2008/10/how-to-disable-ssh-host-key-checking.html
http://www.cnblogs.com/cheche/archive/2011/01/07/1918825.html