Wednesday, July 4, 2007

SSH Public Key Authentication

#On the computer that is making the inital connection (Call this Computer A)
ssh-keygen -t rsa
ssh user@computer_b "cat >> .ssh/authorized_keys" < .ssh/id_rsa.pub

#On Computer B (authorized_keys needs to have 600 permissions or it won't work)
chmod 600 .ssh/authorized_keys

No comments: