Git Clone : Unknown SSL protocol error in connection to github.com:443

13,396

Solution 1

Make sure to use the latest Git (2.12.2) to check if the issue persists.

If it does, see the various settings I mention in "Unknown SSL protocol error in connection" in order to debug this:

# Windows
set GIT_CURL_VERBOSE=1
set GIT_TRACE_PACKET=2

# Unix
export GIT_CURL_VERBOSE=1
export GIT_TRACE_PACKET=2

Update Feb. 2018: after issue 587 (Disable TLSv1.0 and Disable Cipher), this is finally in place: no more TLSv1.0.
See "Discontinue support for weak cryptographic standards", updated in 2018 with "Weak cryptographic standards removal notice".

On February 8, 2018 we’ll start disabling the following:

  • TLSv1/TLSv1.1: This applies to all HTTPS connections, including web, API, and git connections to https://github.com and https://api.github.com.
  • diffie-hellman-group1-sha1: This applies to all SSH connections to github.com
  • diffie-hellman-group14-sha1: This applies to all SSH connections to github.com

So make sure your:

  • Git Credential Manager is greater than 1.14.0
  • Git on RedHat is (for RedHart) in 7.2 or more
  • JDK is 8 or more.

Solution 2

Make sure your proxy is set correctly if you have one: git config --global http.proxy http://User:PASSWORD@PROXY:PORT

Share:
13,396
Ankur
Author by

Ankur

Updated on June 09, 2022

Comments

  • Ankur
    Ankur almost 2 years

    I am trying to clone a GitHub project in my office system.

    set HTTPS_PROXY=http://<UN>:<PWD>@<PROXYSERVER>:<PORT>
    set HTTP_PROXY=http://<UN>:<PWD>@<PROXYSERVER>:<PORT>
    

    I have set HTTPS and HTTP proxies also set sslVerify to false

    [https]
        sslVerify = false
    [http]
        sslVerify = false
    

    still, I am getting "Unknown SSL protocol error in connection to github.com:443".

    Can someone advise me what do I need to do?