开发者

SSH troubles pushing with Git

I'm trying to set up a git repository on Assembla (assembla.com) and I'm having trouble making my first "push". I'm fairly ignorant of git, but I've previously successfully pushed to a repository on github. I'm using git on Windows Vista. When I run git bash from the relevant directory and type "git push", I get:

The authenticity of host 'git.assembla.com (64.250.188.42)' can't be established.
RSA fingerprint is 31:06:...(omitted)...:07:e6.
Are you sure you want to continue connecting (yes/no)?

Entering "yes" is no good, it doesn't accept the passphrase.

I know that this has something to do with SSH keys, but I can't figure out what might be wrong with mine. My git name and email on my local machine match up with the ones I've entered on Assembla, and I've tried generating a new SSH key and uploading the id_rsa.pub file to Assembla to no effect.

A search turned up this forum thread: http://forum.assembla.com/forums/3/topics/2754

As far as I can tell none of the suggestions raised by the administrator in the final post apply. 1 and 2 shouldn't apply because this is a vanilla account on the site and I haven't changed any settings. 3, 4 and 5 I believe I have done. 6 I have done, although I deleted the line "GSSAPIAuthentication" because it generated an additional error message.


NB. I have another open question on StackOverflow regarding Git. This question is unrelated and concerns a different Windows machine. I have not abandoned my other question.


Edit:

Output of ssh -v git@git.assembla.com:

$ ssh -v git@git.assembla.com
OpenSSH_4.6p1, OpenSSL 0.9.8e 23 Feb 2007
debug1: Reading configuration data /c/Users/Philip/.ssh/config
debug开发者_如何学编程1: Applying options for git.assembla.com
debug1: Connecting to git.assembla.com [64.250.188.42] port 22.
debug1: Connection established.
debug1: identity file /c/Users/Philip/.ssh/id_rsa.pub type 1
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.1p1 Debian-5-assembla
debug1: match: OpenSSH_5.1p1 Debian-5-assembla pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.6
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
The authenticity of host 'git.assembla.com (64.250.188.42)' can't be established.
RSA key fingerprint is 31:06:3b:0d:cd:23:1a:41:dc:f2:c5:7d:9c:24:07:e6.
Are you sure you want to continue connecting (yes/no)?

Output of git remote -v:

$ git remote -v
origin  git@git.assembla.com:ksv.git (fetch)
origin  git@git.assembla.com:ksv.git (push)

The password prompt:

$ git push
The authenticity of host 'git.assembla.com (64.250.188.42)' can't be established.
RSA key fingerprint is 31:06:3b:0d:cd:23:1a:41:dc:f2:c5:7d:9c:24:07:e6.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'git.assembla.com,64.250.188.42' (RSA) to the list of known hosts.
Enter passphrase for key '/c/Users/Philip/.ssh/id_rsa.pub':


It looks from the error message as if the problem is that you're specifying your public key (id_dsa.pub) as IdentityFile in your .ssh/config file instead of your private key, which would be just id_dsa.

The questioner has confirmed in the comments above that this was the problem.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜