0

Possible Duplicate:
How do I set up SSH so I don’t have to type my password?

Anyone knows about this?

  • 1
    Duplicate of http://superuser.com/questions/8077/how-do-i-set-up-ssh-so-i-dont-have-to-type-my-password – dbr Oct 28 '09 at 01:49

3 Answers3

5

This should probably be on superuser ...

This guide discusses setting up ssh keys based authentication: http://pkeck.myweb.uga.edu/ssh/.

Basically you create ~/.ssh/authorized_keys (or ~/.ssh/authorized_keys2) and populate it with your public key as created by ssh-keygen. PuTTY for Windows also comes with a key generation tool (and key agent) if you want to automatically log in from Windows.

Update: How do I set up SSH so I don't have to type my password? (It was already there even! :) )

opello
  • 746
  • 5
  • 8
  • 1
    Another tutorial with screenshots is here: http://wowtutorial.org/tutorial/22.html :) –  Oct 28 '09 at 00:18
0

Sure. ssh-keygen to build an SSH key. Fill in the information, leave the password blank. The private key was stored in ~/.ssh/id_dsa and the public key in ~/.ssh/id_dsa.pub. SSH into the server of your choice, and append the contents of your public key file into ~/.ssh/authorized_keys on the server. Create the file and the .ssh directory as necessary.

And this question belongs on ServerFault, not SuperUser IMHO.

Bob Aman
  • 152
  • 1
  • 10
  • It's over there too, heh: http://serverfault.com/questions/2429/how-do-you-setup-ssh-to-authenticate-using-keys-instead-of-a-username-password – opello Oct 28 '09 at 00:21
0

After you use ssh-keygen to generate the key see if you have the command ssh-copy-id which you use like this

$ ssh-keygen -t dsa
$ ssh-copy-id -i ~/.ssh/id_dsa.pub remotehost

If you don't have ssh-copy-id you'll have to log into the remotehost and add the contents of your local ~/.ssh/id_dsa.pub to remotehost's ~/.ssh/authorized_keys

gnibbler
  • 256
  • 1
  • 7