git 致命:无法访问“https://github.com/xxx”:LibreSSL SSL_connect:连接到 github.com 的 SSL_ERROR_SYSCALL:443

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/52732686/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 13:12:45  来源:igfitidea点击:

fatal: unable to access 'https://github.com/xxx': LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443

gitopenssl

提问by Esmatullah Arifi

I used git "push" and "pull" commands with success till yesterday, but today it is not working and give me this error: Push failed: Unable to access 'https://github.com/username/repository.git/': LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443

直到昨天,我都成功使用了 git "push" 和 "pull" 命令,但今天它不起作用并给我这个错误: Push failed: Unable to access 'https://github.com/username/repository.git/': LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443

I tried many solutions but no success. Solutions I tried:
1. Using SSH key
2. Updating git
3. Installing curl with openssl (same error while installing)

我尝试了很多解决方案,但没有成功。我尝试过的解决方案:
1. 使用 SSH 密钥
2. 更新 git
3. 使用 openssl 安装 curl(安装时出现相同错误)

This is the result of curl github.com -v:

这是结果curl github.com -v

* Rebuilt URL to: github.com/
*   Trying 192.30.253.112...
* TCP_NODELAY set
* Connected to github.com (127.0.0.1) port 80 (#0)
> GET / HTTP/1.1
> Host: github.com
> User-Agent: curl/7.54.0
> Accept: */*
> 
* Recv failure: Connection reset by peer
* stopped the pause stream!
* Closing connection 0
curl: (56) Recv failure: Connection reset by peer

回答by Esmatullah Arifi

The problem was solved by restarting my computer.

问题是通过重新启动我的计算机解决的。

回答by VonC

As commented in libressl-portable/portable/issue 369

正如libressl-portable/portable/issue 369 中所述

I update with brew, libressl, openssl and curl and reboot my machine. It's now working.

我使用 brew、libressl、openssl 和 curl 进行更新,然后重新启动我的机器。它现在正在工作。

Note that SSH should work, but for that you need to change your origin URL

请注意,SSH 应该可以工作,但为此您需要更改源 URL

git remote set-url origin [email protected]:aUser/aProject

That would not use HTTPS at all then.

那根本就不会使用 HTTPS。

回答by Rodrigo Farias Rezino

We started an investigation internally and we discovered that in our case was a problem with Kaspersky antivirus.

我们在内部开始了一项调查,我们发现在我们的案例中是卡巴斯基防病毒软件的问题。

We raised a bug for their support, waited, waited, got feedback that would be solved some months ago in a new release. We got and tried the release, the problem was still there. We raised again another ticket, a lot of debugging information/files they requested. Still not solved.

我们为他们的支持提出了一个错误,等待,等待,得到反馈,这些反馈将在几个月前在新版本中得到解决。我们得到并尝试了发布,问题仍然存在。我们再次提出了另一张票,他们要求提供很多调试信息/文件。还是没有解决。

We gave up and moved to Avast, no problems so far.

我们放弃并转向 Avast,到目前为止没有任何问题。