[Gllug] rssh with public key authentication?

gvim gvimrc at gmail.com
Wed Dec 8 12:53:39 UTC 2010

On 08/12/2010 02:20, John Edwards wrote:
> Yes, works fine.
> Easiest way is to test that the keys work with the shell set to
> /bin/bash (or similar) and then switch the shell to rssh.
> Make sure the ~/.ssh/ directory and authorized_keys file (note the
> US spelling) are owned by the user and only readable by the user.
> Use the verbose flag on the ssh client to show info on what is
> going on and where things are failing, eg:
> 	rsync -va -e 'ssh -v' /dir/file remote-server:/dir/file
> Check the authentication syslog files on the server (eg
> /var/log/auth.log for Debian or /var/log/secure for RedHat)
> for errors from the server end.

It now seems to be a public key problem even with a normal bash login. Steps (CentOS 5.4):

- useradd <user>
- cp -R ~<existing user>/.ssh   ~<new user>/
- chown -R <new user>:<new user>  ~<new user>/.ssh
- Append to AllowUser line in sshd_config:   <new user>@<my ip>
- service sshd restart

So now the new user account has the same .ssh/authorized_keys file as an existing user with a working login. However when I try to login all I get is:

Permission denied (publickey)


... says nothing other than "Connection closed by <my ip>"

Gllug mailing list  -  Gllug at gllug.org.uk

More information about the GLLUG mailing list