[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [K12OSN] how to set up passwordless ssh access

Seth Hasani wrote:

On 6/15/07, Krsnendu dasa <krsnendu108 gmail com> wrote:
I have run ssh-keygen on my home Ubuntu computer.
Then I pasted the contents of id_rsa.pub into ~/.ssh/authorized_keys
on the K12LTSP server.

When I ssh in it still prompts me for my password.

Makes sense because your client doesnt have the server's key but your
server surely does have the client's key. The client needs the
server's key to connect passwordless. (and all of that permissions
stuff given in this thread has to be in place as well.)

I believe this is incorrect. You never need to create a key pair on a server, only on the client computer that needs to connect to the server.
What else do have have to do so I don't have to enter my password
every time I ssh in?

1- On your client computer create a key pair using: ssh-keygen -t dsa. Do *not* enter a passphrase. 2- Copy the contents of the file ~/.ssh/id_dsa.pub from your client computer (public half of the key) into the file ~/.ssh/authorized_keys on the server. You can do this easily with scp. Or open a second terminal and ssh (with password for now) into the server, then copy/paste from the local file to the server using the mouse. 3- Make sure permissions are correct. On the server ~.ssh/authorized_keys must be read only for the user, i.e. chmod 0600 ~/.ssh/authorized_keys.
That should do it.


Arava Development Co, Sapir, Israel
tel: +972(8)-6592270
cell: +972(52)-3665918

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]