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

GitHub error - "ssh_exchange_identification: read: Connection reset by peer"

我刚刚在 Git Bash 中为我想推送到 GitHub 的应用程序生成了 ssh 密钥。我添加了代理和代理身份,复制了密钥并在我的 GitHub 帐户中创建了一个新的 SSH 密钥。当我尝试 运行 $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

其次,如果你的办公室里有 proxy/firewall,应该阻止传出的 ssh 连接。
使用 https URL(带凭证缓存)是您的最佳选择。