You can login with password or with certificates. To generate certificates use this commands and accept all questions with enter:
1 |
ssh-keygen -t rsa |
1 |
ssh-keygen -t dsa |
This will generate a public and private certificate pair under ~/.ssh/
Now you can authorise a user with the gernated public certificates on other machines. You only need to copy the content from the public certificates to the other remote systems in this file~/.ssh/authorized_keys
For this purpose there is a special ssh tool:
1 2 |
ssh-copy-id -i ~/.ssh/id_rsa.pub user@remote-system ssh-copy-id -i ~/.ssh/id_dsa.pub user@remote-system |
Without that tool you can do it this way:
1 |
cat ~/.ssh/*.pub | ssh user@remote-system 'umask 077; cat >>.ssh/authorized_keys' |