【问题标题】:SSL error when cloning from a https repository using msysgit due to openssl curl由于 openssl curl,使用 msysgit 从 https 存储库克隆时出现 SSL 错误
【发布时间】:2014-03-12 04:12:22
【问题描述】:

尝试从 https 存储库克隆时,出现以下错误:

fatal: unable to access 'https://xxx/': error:14077458:SSL routines:SSL23_GET_SERVER_HELLO:reason(1112)

根据this,这是由 openssl/curl 中的问题引起的,该问题无法正确处理 SSLv23 中的警告级别警报。在命令行上通过 -3 来 curl 解决了这个问题。

如何告诉 git 在克隆时将-3“传递”到curl

其他信息

  • 我使用msysgit:git版本1.8.4.msysgit.0
  • OpenSSL 0.9.8e 2007 年 2 月 23 日
  • 将 http.sslVerify 设置为 false 并解决我的问题(连接未达到这一点并且之前退出)。
  • 我可以用curl 重现这个问题:

.

$ curl -v https://xxx/
* Adding handle: conn: 0x13dc6e8
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x13dc6e8) send_pipe: 1, recv_pipe: 0
* About to connect() to xxx port 443 (#0)
*   Trying 1.2.3.4...
* Connected to xxx (1.2.3.4) port 443 (#0)
* successfully set certificate verify locations:
*   CAfile: C:\Program Files\Git\bin\curl-ca-bundle.crt
  CApath: none
  * SSLv3, TLS handshake, Client hello (1):
  * error:14077458:SSL routines:SSL23_GET_SERVER_HELLO:reason(1112)
  * Closing connection 0
  curl: (35) error:14077458:SSL routines:SSL23_GET_SERVER_HELLO:reason(1112)

传递-3option 可以解决问题:

$ curl -v -3 https://xxx/
* ...
* Connected to xxx (1.2.3.4) port 443 (#0)
* successfully set certificate verify locations:
*   CAfile: C:\Program Files\Git\bin\curl-ca-bundle.crt
  CApath: none
  * SSLv3, TLS handshake, Client hello (1):
  * SSLv3, TLS handshake, Server hello (2):
  ...

编辑

服务器运行 OpenSSL 1.0.1e 2013 年 2 月 11 日,指向 this

【问题讨论】:

    标签: git curl openssl msysgit


    【解决方案1】:

    这是一个 SVN 存储库。

    使用

    git svn clone https://xxx
    

    而不是

    git clone https://xxx
    

    解决问题。


    编辑: 看来我不是唯一一个忘记“svn”的人,我只想补充一点,如果你得到这也是答案

    SSL certificate problem: unable to get local issuer certificate
    

    作为一个错误。

    【讨论】:

      猜你喜欢
      • 2014-06-06
      • 1970-01-01
      • 1970-01-01
      • 2012-04-13
      • 2013-11-13
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-06-25
      相关资源
      最近更新 更多