Can I force git to use TLS only?
When I use git under a specific network environment, it will send out SSL packet rather than TLS one, and says “
gnutls_hanshake() failed(): A TLS packet with unexpected length was receive” . This is the only difference I can discover from the WireShark logs between them:
The SUCCESS result
The FAILED result
I’m using Ubuntu 12.04, x86-64 version. And this problem appeared also on MacBook and 11.10 problem. But when I try with Win7 and Git Gui, it got no errors.
And if I switch to other network environments, like pppoe in my home, or the WiFi in some cafe, the problem disappeared with my Ubuntu 12.04 ( same settings, same OS ).
Please help me to know what can I do. At least if I have to argue this problem with my MIS, I can figure out why this shouldn’t happen.
PS.1. I have tried the solution listed in ask Ubuntu, but it didn’t work.
PS.2. Filezilla seemed had this problem, too. But I can’t find how they solve the problem ( and apply to git ).
One Solution collect form web for “Can I force git to use TLS only?”
Git uses libcurl for HTTP connections.
I am not aware of any runtime configuration of the library (which it might have), but you might be able to modify the Git itself to force it to use TLS-only connections. Checkout http.c. The libcurl function for the purpose should be curl_easy_setopt with argument CURLOPT_SSLVERSION with CURL_SSLVERSION_TLSv1.