GitHub 错误 - "ssh_exchange_identification: read: Connection reset by peer"

标签 git github ssh ssh-keys

我刚刚在我的 Git Bash 中为我想推送到 GitHub 的应用程序生成了 ssh key 。我添加了代理和代理身份,复制了 key 并在我的 GitHub 帐户中创建了一个新的 SSH key 。当我尝试运行 $ssh -T github@github.com 时,我收到一条错误消息,内容为 "ssh_exchange_identification: read: Connection reset by peer"。我之前看到过这个问题,但与 GitHub 没有直接关系(如果我错了请纠正我)。我在我的 User\.ssh 文件夹中看到了我的 id_ras 和 id_rsa.pub 文件。导致此错误消息的问题可能是什么?注意:我在我的办公室内运行它,想知道这是否可能是由办公室网络防火墙引起的?

最佳答案

首先 ssh -T github@github.com 不会工作
ssh -T git@github.com

第二,如果你的办公室有任何代理/防火墙,应该阻止传出的 ssh 连接。
使用 https URL(带凭证缓存)是您的最佳选择。

关于GitHub 错误 - "ssh_exchange_identification: read: Connection reset by peer",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46798348/

相关文章:

github - Jenkins GitHub OAuth 插件出现“用户缺少总体/读取权限”错误

git - 这个工作流程可以用 git-svn 实现吗?

git - heroku git :clone creates empty repository

所有分支的 Git 克隆

php - 由于子模块,Heroku 不会接受推送

git - 总是覆盖一个 git 部署分支

mysql - 通过 SSH 连接到 R 中的 MySQL 数据库

mysql - Openshift:如何通过 RHC 或 SSH 将数据库导入 MySQL?

ubuntu - 当 AuthorizedKeysCommand 存在时 Openssh 连接被拒绝

git 和 "Server aborted the SSL handshake"错误