5

I'm using a VWWare image of Ubuntu 8.04 and experiencing problems while setting up git access over SSH

I get the following output

debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: 
debug1: Authentications that can continue: publickey
debug1: Offering public key: 
debug1: Authentications that can continue: publickey
debug1: Offering public key: 
debug1: Authentications that can continue: publickey
debug1: Offering public key: 
debug1: Authentications that can continue: publickey
debug1: Trying private key: /home/jars/.ssh/identity
debug1: PEM_read_PrivateKey failed
debug1: read PEM private key done: type <unknown>
Enter passphrase for key '/home/jars/.ssh/identity': 
debug1: read PEM private key done: type RSA
debug1: Authentications that can continue: publickey
debug1: No more authentication methods to try.
Permission denied (publickey).

I have generated the keys with ssh-keygen -t rsa

and renamed them to identity (private) and ida_rsa (public), because initially they wheren't found by ssh.

I also created a config file as depicted here...

http://help.github.com/troubleshooting-ssh/

Nothing changed.

Am I missing something or is there generally something wrong with using SSH in VMWare?

Regards

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
Jeremy S.
  • 6,423
  • 13
  • 48
  • 67
  • Note to moderators: any Git question has NOTHING TO DO with superuser. Git is a **programming** tool, and as such 100% belongs on SO. – VonC Oct 04 '10 at 20:40
  • 'private'? I thought a ssh rsa private key was name `id_rsa`, not `private`... – VonC Oct 04 '10 at 20:41
  • @Von: It's not a GitHub question, it has to do with issues creating and using a public / private key. – Josh K Oct 04 '10 at 20:42
  • @Josh K: I realize this not about GitHub. It is certainly about Git (using ssh). And I commented on the name of said private key: it should be `id_rsa`, not `private`. – VonC Oct 04 '10 at 20:44
  • @Von: And how does this relate to programming? Git is a VCS, do we ask questions about Firebug here? No, they go on SU. – Josh K Oct 04 '10 at 20:55
  • @Josh: my bad, if you limit the question to the ssh aspect, it does indeed fit the SU domain (and its 494 ssh questions there). I simply had too much "pure" git questions migrated on SU (even if Git belongs to SO), hence my initial reaction. – VonC Oct 04 '10 at 21:09
  • @Von: No problem, I agree that pure git questions are probably best asked here. I wouldn't ask `sed` or `awk` questions on SU, I might ask them on the unix.SE though. – Josh K Oct 04 '10 at 21:13

1 Answers1

5

Check your permissions on your .ssh directory on the local and remote sides:

drwx------ 3 xxx xxx 216 10-04 12:30 .ssh/
-rw------- 1 xxx xxx  745 06-19 12:37 authorized_keys
-rw------- 1 xxx xxx  783 05-08 22:15 config
-rw------- 1 xxx xxx 3.3K 2009-02-21  id_rsa
-rw------- 1 xxx xxx  745 2009-03-06  id_rsa.pub
-rw-r--r-- 1 xxx xxx  53K 09-27 15:51 known_hosts

If that doesn't work, run the SSH server from the command line in debug mode. It may give you more information why it is rejecting the login.

sudo /usr/sbin/sshd -Dd
cmcginty
  • 113,384
  • 42
  • 163
  • 163