Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

""error: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version while accessing" #5806

Closed
vasim-farooqui opened this issue Mar 30, 2018 · 14 comments

Comments

@vasim-farooqui
Copy link

Hi I am facing error while using git fetch

"error: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version while accessing https://github.com/organisationname/reponame/info/refs?service=git-upload-pack
fatal: HTTP request failed.

After this error updated openssl version from 0.9 to 1.0.1e
Still getting same error.

@mspncp
Copy link
Contributor

mspncp commented Mar 30, 2018

Hi, the versions 0.9 and 1.0.1 are outdated and not supported anymore. Please upgrade to version 1.0.2, see https://www.openssl.org/source.

@mspncp mspncp closed this as completed Mar 30, 2018
@vasim-farooqui
Copy link
Author

vasim-farooqui commented Mar 30, 2018 via email

@mattcaswell
Copy link
Member

What platform are you on? How did you do the upgrade? i.e. did you download and build from source, or did you get OpenSSL from your OS vendor repository?

@mattcaswell mattcaswell reopened this Mar 30, 2018
@vasim-farooqui
Copy link
Author

CentOS release 5.7 (Final) x86_64 Yes Downloaded the package from below url and build from source.
https://www.openssl.org/source/openssl-1.0.2a.tar.gz

@mattcaswell
Copy link
Member

Ok. I don't know why you chose 1.0.2a since that is not the most recent 1.0.2 release and has security issues. You should really use 1.0.2o (the most up to date version).

The most likely explanation is that you still have the system version of OpenSSL installed and your git is using that one. If your git command is linked against OpenSSL 0.9.x then you probably need a newer version of that too.

@vasim-farooqui
Copy link
Author

How do i make git to use to new version of openssl installed.
Is there any way to config that for git

@kroeckx
Copy link
Member

kroeckx commented Mar 30, 2018

You really need to recompile it and make sure it uses the correct headers and links to the correct library

@vasim-farooqui
Copy link
Author

Recompile git or openssl, is there any way where i can re-install git with higher version and keep the existing setting as it is.

@levitte
Copy link
Member

levitte commented Mar 31, 2018

This is really a question you should ask the git folks... their README might be helpful. As for rebuilding git, I suggest you have a look at their INSTALL, where you will find nothing about OpenSSL, but everything about libcurl, which is a HTTP transport library that uses, among others, OpenSSL:

- Git is reasonably self-sufficient, but does depend on a few external
  programs and libraries. ...
...
	- "libcurl" library is used by git-http-fetch, git-fetch, and, if
	  the curl version >= 7.34.0, for git-imap-send.  You might also
	  want the "curl" executable for debugging purposes. If you do not
	  use http:// or https:// repositories, and do not want to put
	  patches into an IMAP mailbox, you do not have to have them
	  (use NO_CURL).

So all in all, you will need to build newer versions of OpenSSL, libcurl and git, at the very least... and to build git, you will need to make sure that you have installed the development packages for everything else that you want git to use.

For further information specifically about git, I suggest that you talk with the git folks, as they are much better informed than any of us. The README I pointed at has the contact details.

@mspncp
Copy link
Contributor

mspncp commented Mar 31, 2018

The normal way to update git would be to use the package manager of your Linux distribution (CentOS in your case) and not to build and install from source. IMHO, your real problem is that you are using a relative old and outdated CentOS release. CentOS 5.7 was released in September 2011 and is end-of-life since end of March 2017. So maybe an update of your CentOS would solve all your problems.

Hope that helps, Matthias

@richsalz
Copy link
Contributor

And now I think this issue can be closed.

@vasim-farooqui
Copy link
Author

@kroeckx Yes definitely i need to upgrade git .
Do you happened to know the way to do it in which it does not break the system.

@kjr247
Copy link

kjr247 commented May 29, 2019

@vasim-farooqui
https://gitforwindows.org/
download here.

@JulienDesurmont
Copy link

Hello.
I've faced the same issue :

Use this command to pull / fetch : git remote add origin git@github.com:*****.git

instead of git remote add origin https://github.com/*********.git

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants