public key authentication

Adam Myrow amyrow at midsouth.rr.com
Sat Jun 5 20:43:10 EDT 2004


You can still use pass phrases without it being as inconvenient like this.
Assuming you've got public key authentication set up correctly on all
hosts, do the following on the host with the private key.  That is, this
must be done on the host that you will be using to connect to other hosts
which only have the public key.  Put this line in your .profile or
.bash_profile, or .bash_login file.

eval `ssh-agent` > /dev/null

Then, put this line in your .bash_logout file.

eval `ssh-agent -k` > /dev/null

Use the equivalent files if you use a shell besides Bash.  Now, with those
lines in place, log out and back in.  Assuming all goes well, you can now
type "ssh-add" and be prompted for your pass phrases.  After typing them
in once, any future SSH sessions to hosts which have your public key will
not require you to type your pass phrase.  This is a good compromise
between the lack of security of no pass phrase (especially if you let root
log in via SSH,) and the annoyance of constantly typing possibly long pass
phrases.







More information about the Speakup mailing list