1.On your Home-comp
ssh-keygen -t rsa
This will generate ~/.ssh/id_rsa.pub file
2.
cat ~/.ssh/id_rsa.pub | ssh office-user@office-comp "cat >> ~/.ssh/authorized_keys"
This will ask you password for one last time. Note that we have used cat command over ssh. Hence we will require the password at least once.
Make sure that you have following permissions on "office-comp" :
chmod 750 ~
chmod 700 ~/.ssh
chmod 600 ~/.ssh/authorized_keys
No comments:
Post a Comment