Git error: gnutls_handshake () failed to click

I used git for a while without any problems, and then suddenly started throwing this error when using git push:

Error: gnutls_handshake () failed: A TLS packet with unexpected length was received. on access ... fatal: HTTP request failed

It worked great and then suddenly stopped.

What is the problem?

thank

+5
source share
4 answers

There seems to be a problem with the package gnutls. As a workaround, you can try to compile gitwith openssl. More information on how to do this can be found here .

+3
source

askubuntu git, . :

sudo dpkg-source -x git_1.7.9.5-1.dsc
cd git_1.7.9.5 8.

git, . 1.8.xxxxx.

sudo dpkg-source -x git_<git-version-number>.dsc
cd git_<git-version-number>

- , Tab . , .

+1

.

Debian Wheezy Jessie, , , apache 2.2.22 2.4.10. git https://www.example.com error: gnutls_handshake() failed: A TLS packet with unexpected length was received

, www.example.com IPv4, IPv6, Apache <Virtualhost x.y.w.z:443> IPv4-. <Virtualhost _default_:443> .

(just like that, if it helps someone with the same problem ... just found it after tedious recompilation of git with openssl didn't change anything)

0
source

This answer may help. I was surprised that the problems are nowhere related to each other, although the question is old.

To be sure that useful information is not lost, I will copy a short solution to the question:

hostname=XXX
port=443
trust_cert_file_location=`curl-config --ca`

sudo bash -c "echo -n | openssl s_client -showcerts -connect $hostname:$port 2>/dev/null  | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' >> $trust_cert_file_location"
0
source

All Articles