[英]setting up github ssh on windows 7 machine
我刚刚使用git如何引导我的Windows机器上安装了git,但是我遇到了问题。
当我运行ssh -T git@github.com
步骤时,我收到此错误:
ssh_exchange_identification:读取:由对等方重置连接
这是我通过运行ssh -vvv git@github.com
获得的更长的跟踪:
OpenSSH_4.6p1, OpenSSL 0.9.8e 23 Feb 2007 debug2: ssh_connect: needpriv 0 debug1: Connecting to github.com [207.97.227.239] port 22. debug1: Connection established. debug1: identity file /c/Users/bmehanni/.ssh/identity type -1 debug3: Not a RSA1 key file /c/Users/bmehanni/.ssh/id_rsa. debug2: key_type_from_name: unknown key type '-----BEGIN' debug3: key_read: missing keytype debug2: key_type_from_name: unknown key type 'Proc-Type:' debug3: key_read: missing keytype debug2: key_type_from_name: unknown key type 'DEK-Info:' debug3: key_read: missing keytype debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug3: key_read: missing whitespace debug2: key_type_from_name: unknown key type '-----END' debug3: key_read: missing keytype debug1: identity file /c/Users/bmehanni/.ssh/id_rsa type 1 debug1: identity file /c/Users/bmehanni/.ssh/id_dsa type -1 ssh_exchange_identification: read: Connection reset by peer
谢谢
我有同样的问题,但从未找到解决问题的方法。
解决方法是使用https而不是ssh。
看起来你的id_rsa键的类型是错误的
debug2: key_type_from_name: unknown key type
ssh试图从密钥文件名中推断出类型。 生成密钥时,需要使用-t rsa
标志指定类型。
ssh-keygen -t rsa
另外,接受私钥id_rsa
和公钥id_rsa.pub
的文件名的默认值,否则你需要在~/.ssh/config
文件中添加github的配置,指定用于该特定的私钥。主办。
Host github.com
HostName github.com
User git
IdentityFile C:/Users/youruser/.ssh/someotherkeyname
看起来你的ssh密钥有问题,所以我猜你在运行ssh-keygen时出了什么问题。 尝试重新运行该步骤
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.