|
|
| Line 1: |
Line 1: |
| {{seed}} | | {{seed}} |
| ==Notes== | | ==Notes== |
| To enable logging in from a specific remote client with no password (typically so scripts can connect with ssh or [[rsync]]): | | To enable logging in from a specific remote client with no password (most often used for scripts), see [[keyed login]]. |
| * Generate a public/private key pair on the client using [[ssh-keygen]]
| |
| * Add the public key file (~/.ssh/id_rsa.pub) from the client to ~/.ssh/authorized_keys on the host.
| |
| ** If the latter file doesn't already exist, then it can just be a direct copy of id_rsa.pub.
| |
| ** If the latter file ''does'' already exist, then id_rsa.pub can just be appended to authorized_keys.
| |
| ** The following command should work for either case:
| |
| *** <bash>cat .ssh/id_rsa.pub | ssh user@host 'cat >> .ssh/authorized_keys'</bash>
| |
| * It may be necessary to manually log on once to the client from the host (using the same usernames as above) in order to add the client to the host's known_hosts file; I'm not sure about this part. Need to test.
| |
| * Manually log on from the client to the host to make sure that the host is added to the client's known_hosts file, otherwise the verification prompt may interrupt any processes trying to log on automatically.
| |
| * If you disable logins now (e.g. via [[Webmin]]'s "No login allowed" option), you will still be able to log in from a client with an authorized key.
| |
| | |
| Specific commands for doing this may be found [http://linuxproblem.org/art_9.html here].
| |
<hide>
page status::seed
</hide>
Notes
To enable logging in from a specific remote client with no password (most often used for scripts), see keyed login.