Home > Net >  git: OpenSSL SSL_connect: Connection was reset in connection to github.com:443
git: OpenSSL SSL_connect: Connection was reset in connection to github.com:443

Time:10-01

This is the pretty old problem, but I couldn't solve it using old answers. When I try to push github (git push origin master), I receive this error:

     OpenSSL SSL_connect: Connection was reset in connection to github.com:443

I tried these solutions :

1-Trying this command:

$ git config --global --add remote.origin.proxy ""

2-Opening new terminal and using push command again.

3-Runing this command:

$ git config --global http.sslBackend "openssl"

4-Unsetting proxy:

$ git config --global --unset http.proxy $ git config --global --unset https.proxy

None of these solutions are working. Any advises could make me happy!

CodePudding user response:

This worked for me: Using SSH Key

  1. Generate a new SSH key / Add it to the ssh-agent

  2. Add the new generated SSH key to your GitHub account

  3. Clone the repository using SSH [click SSH tab!]
    (I recommend you test it on a new folder different from your current working path)

That's it. Now try to pull/push. Everything should be worked
Open the file .git/config If you notice, the URL parameter value in [remote "origin"] is changed!


Useful docs here:
Connecting to GitHub with SSH
Testing your SSH connection
Working with SSH key passphrases

  • Related