Guest Teeps Posted October 11, 2005 Report Share Posted October 11, 2005 Hi, I'm trying to get key based authentication to work. I've generated the keys I need (I think), but when I type 'ssh -l mtuma matthewx' to log in to the remote machine it fails. The log on the server says: Oct 11 16:50:05 MATTHEWX sshd[312]: debug1: Forked child 328. Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: rexec start in 4 out 4 newsock 4 pipe 6 sock 7 Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: inetd sockets after dupping: 3, 3 Oct 11 16:50:05 MATTHEWX sshd[328]: Connection from ::ffff:192.168.0.111 port 1743 Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: Client protocol version 2.0; client software version OpenSSH_3.9p1 Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: match: OpenSSH_3.9p1 pat OpenSSH* Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: Enabling compatibility mode for protocol 2.0 Oct 11 16:50:05 MATTHEWX sshd[328]: debug1: Local version string SSH-2.0-OpenSSH_3.9p1 Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: temporarily_use_uid: 501/501 (e=0/0) Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: trying public key file /root/.ssh/authorized_keys Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: restore_uid: 0/0 Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: temporarily_use_uid: 501/501 (e=0/0) Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: trying public key file /root/.ssh/authorized_keys Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: restore_uid: 0/0 Oct 11 16:50:13 MATTHEWX sshd[328]: debug1: do_cleanup It looks to me as if it's ignoring the keys in my home directory, and trying to use root's keys instead. The sshd_config is set to look in ~/.ssh/authorized_keys, which I think should make it look in /home/mtuma/.ssh/authorized_keys . This exists, and has the correct permissions. :? Any ideas anyone, please? [moved from Software by spinynorman] Quote Link to comment Share on other sites More sharing options...
Guest anon Posted October 11, 2005 Report Share Posted October 11, 2005 Open a consol as you and try: ssh username@your_server_address Quote Link to comment Share on other sites More sharing options...
Guest Teeps Posted October 12, 2005 Report Share Posted October 12, 2005 (edited) Open a consol as you and try: ssh username@your_server_address <{POST_SNAPBACK}> I tried this, it gives the same problem, with the same log results. Edited October 12, 2005 by Teeps Quote Link to comment Share on other sites More sharing options...
aioshin Posted October 12, 2005 Report Share Posted October 12, 2005 try to chown that file to mtuma Quote Link to comment Share on other sites More sharing options...
Guest Teeps Posted October 12, 2005 Report Share Posted October 12, 2005 I've sorted it, I had to change a line in the sshd_config from this: AuthorizedKeysFile ~/.ssh/authorized_keys to this: AuthorizedKeysFile .ssh/authorized_keys I guess it's assuming the home directory already for some reason. Thanks anyway. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.