git:fatal: HTTP request failed

git clone http://github.com/TOGoS/TUN2UDP.git的时候出现

error: while accessing http://github.com/TOGoS/TUN2UDP.git/info/refs

fatal: HTTP request failed

网上说的git版本问题 http.sslVerify问题都不能解决我的问题

分析过程:

curl -v  http://github.com/TOGoS/TUN2UDP.git/info/refs

* About to connect() to github.com port 443 (#0)

*  Trying 13.229.188.59... connected

* Connected to github.com (13.229.188.59) port 443 (#0)

* Initializing NSS with certpath: sql:/etc/pki/nssdb

*  CAfile: /etc/pki/tls/certs/ca-bundle.crt

  CApath: none

* NSS error -12190

* Closing connection #0

* SSL connect error

curl: (35) SSL connect error

在一个正常的机器上 curl -v  http://github.com/TOGoS/TUN2UDP.git/info/refs

* About to connect() to github.com port 443 (#0)

*  Trying 13.229.188.59...

* Connected to github.com (13.229.188.59) port 443 (#0)

* Initializing NSS with certpath: sql:/etc/pki/nssdb

*  CAfile: /etc/pki/tls/certs/ca-bundle.crt

  CApath: none

* SSL connection using TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256

* Server certificate:

。。。。

查询NSS error -12190原因需要安装nss 相关和更新curl

yum update nss nss-util nspr

yum update curl

问题解决!

你可能感兴趣的:(git:fatal: HTTP request failed)