git clone fails with "An unexpected TLS packet was received" error

Bug #1766962 reported by thomas duriez
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
git (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

I just updated from 16.04 to 18.04 beta.

This is the error message I get when I try to clone a repo:

fatal: unable to access 'https://github.com/xxxxxxx/yyyyyyyyy.git/': gnutls_handshake() failed: An unexpected TLS packet was received.

I cannot clone repositories on internet (tried on github and overleaf) when I used to have no pb.
This applies to https repositories (Couldn't try over ssh, IT decision).
I built this version of git to use libcurl4-openssl instead of libcurl4-gnutls to no avail but with a different error message though:

fatal: unable to access 'https://github.com/xxxxxxx/yyyyyyyyy.git/': error:1408F10B:SSL routines:ssl3_get_record:wrong version number

I purged packages and deleted .gitconfig, without results.

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: git 1:2.17.0-1ubuntu1
ProcVersionSignature: Ubuntu 4.15.0-15.16-generic 4.15.15
Uname: Linux 4.15.0-15-generic x86_64
ApportVersion: 2.20.9-0ubuntu7
Architecture: amd64
CurrentDesktop: ubuntu:GNOME
Date: Wed Apr 25 16:43:13 2018
InstallationDate: Installed on 2018-03-28 (28 days ago)
InstallationMedia: Ubuntu 16.04.4 LTS "Xenial Xerus" - Release amd64 (20180228)
SourcePackage: git
UpgradeStatus: Upgraded to bionic on 2018-04-25 (0 days ago)

Revision history for this message
thomas duriez (thomas-duriez-gmail) wrote :
Revision history for this message
thomas duriez (thomas-duriez-gmail) wrote :

Sorry, this is solved, I just had to set

git config --global https.proxy

why this was not retained when upgrading from 16.04 or why it needs now to be set (the $https_proxy environment variable is correctly set) is still a problem though.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in git (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.