Unix administration - sshd stil asks for a password

This is Interesting: Free IT Magazines  
Home > Archive > Unix administration > December 2007 > sshd stil asks for a password





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author sshd stil asks for a password
mosfet

2007-12-08, 7:43 pm

Hi,

I am trying to configure access to my ubuntu 7.04(feisty) using sshd and
DSA without success.
So for now I have 3 accounts where I can log into using a ssh with
standard password.
let's says I have an account test@server.com with a password 1234.

Now to log in I do a simple ssh test@server.com and then I enter 1234.
So far so good.

Now I would like to use a DSA key to log so I have created a
public/private DSA key pair with empty passphrase
test@server.com:~/.ssh$ ssh-keygen -t dsa
id_dsa
id_dsa.pub

then I added it to /home/test/.ssh/authorized_keys file
test@server.com:~/.ssh$ cat id_dsa.pub >> authorized_keys

and restart openssh
test@server.com:~/.ssh$ /etc/init.d/ssh restart

I emailed(don't care about security because it's just a test) the
private key to my home PC(running also ubuntu 7.04) and put the id_dsa
in my /home/vince/.ssh.

So now when I try to log like this :
ssh test@server.com
sshd stills asks me a password.

What am I doing wrong ?

Please help

Thnaks a lot






Dave Hinz

2007-12-08, 7:43 pm

On Sat, 08 Dec 2007 15:42:22 +0100, mosfet <john@free.fr> wrote:
> Hi,


Hi John, let's see here...

(snip great problem description)

> So now when I try to log like this :
> ssh test@server.com
> sshd stills asks me a password.
> What am I doing wrong ?


What are the permissions on your .ssh directory and the files in it? I
think they need to be 600, but verify that. If it's world
anything-able, sshd won't use it, for reasons that make sense if you
think about it.

Let us know how it turns out.

Dave

mosfet

2007-12-08, 7:43 pm

Dave Hinz a écrit :
> On Sat, 08 Dec 2007 15:42:22 +0100, mosfet <john@free.fr> wrote:
>
> Hi John, let's see here...
>
> (snip great problem description)
>
>
> What are the permissions on your .ssh directory and the files in it? I
> think they need to be 600, but verify that. If it's world
> anything-able, sshd won't use it, for reasons that make sense if you
> think about it.
>
> Let us know how it turns out.
>
> Dave
>

Ok I think I found the problem.
When I generatethe dsa key I get this :

ssh-dss AAAAB3.........== test@hostname


but hostname is not the right one.
I have changed it and it works.
Teo

2007-12-10, 7:32 am

On Dec 8, 4:32 pm, mosfet <j...@free.fr> wrote:
> Dave Hinz a =E9crit :
>
>
>
>
>
>
>
>
> Ok I think I found the problem.
> When I generatethe dsa key I get this :
>
> ssh-dss AAAAB3.........=3D=3D test@hostname
>
> but hostname is not the right one.
> I have changed it and it works.


Strange, I use a key that I generated a lot of years ago with the name
of a machine that does not exist anymore: and it still works.

Did you also change something else?

Matteo
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com