I'm currently using RedHat Enterprise 6. Git had issues cloning Github repos using HTTPS. After some investigation (e.g. enabling GIT_CURL_VERBOSE and GIT_TRACE) the problem was narrowed to a certificate validation issue, which was solved updating the certificate DB, i.e.:
curl http://curl.haxx.se/ca/cacert.pem -o /etc/pki/tls/certs/ca-bundle.crt
Things worked fine for a while. However, after a system upgrade now I'm getting a different error:
Couldn't find host github.com in the .netrc file; using defaults * About to connect() to github.com port 443 (#0) * Trying 126.96.36.199... * Connected to github.com (188.8.131.52) port 443 (#0) * Initializing NSS with certpath: sql:/etc/pki/nssdb * NSS error -5978 * Expire cleared
Unfortunately I can't find that error code description on the documentation. It seems that the updated CURL system lib defaults to NSS and relies exclusively on the certificates on /etc/pki/nssdb I've been trying to solve this issue trying different commands to add the certificates to NSS, but failed.
Can you recommend a solution? Is it possible to force Git and/or CURL to use the ca-bundle DB, or even disable certificate validation?
Any solution that could allow Git commands to be run using Github's repos wil be welcome.
Curl version curl 7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/184.108.40.206 zlib/1.2.3 libidn/1.18 libssh2/1.4.2