Bug 60913 - (ancient Mono 5.4) HttpClient cannot use TLS 1.2 on linux
Summary: (ancient Mono 5.4) HttpClient cannot use TLS 1.2 on linux
Alias: None
Product: Class Libraries
Classification: Mono
Component: System.Net.Http ()
Version: 5.4 (2017-06)
Hardware: PC Linux
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
Depends on:
Reported: 2017-11-29 19:25 UTC by Nikki Locke
Modified: 2018-02-11 16:30 UTC (History)
5 users (show)

Tags: bugpool-archive
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Nikki Locke 2017-11-29 19:25:16 UTC
I am running mono 5.4 (mono -V reports Mono JIT compiler version (tarball Wed Nov  8 17:02:20 UTC 2017)) on CentOS 6.9 (Final).

It was installed using the instructions at http://www.mono-project.com/download/#download-lin-centos

I have a program that uses Stripe.net to talk to the Stripe credit card provider. But all transactions are rejected with the message "Stripe no longer supports API requests made with TLS 1.0. Please initiate HTTPS connections with TLS 1.2 or later. You can learn more about this at https://stripe.com/blog/upgrading-tls."

I have written a test program to see if mono is using tls1.2, which includes an attempt to force it to do so:

class Program 
    static void Main(string[] args) 
        System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
                   new HttpClient().GetStringAsync("https://www.howsmyssl.com").Result);

When I look at the file, it says (amongst other things):

Bad Your client is open to the BEAST attack. It's using TLS 1.0 or earlier while also supporting a cipher suite that uses Cipher-Block Chaining and doesn't implement the 1/n-1 record splitting mitigation. That combination will leak information.

Is there some way of forcing the mono HttpClient to use TLS1.2?
Comment 1 Nikki Locke 2017-11-30 19:53:07 UTC
Note that the comment in the 4.8 release notes that boring ssl won't compile with gcc 4.7 is no longer true - commit https://github.com/mono/boringssl/commit/2bc26c2772ad0a5d6b0ad4ba2ec77c8183d8932d fixes the problem, or so it says.
Comment 2 Martin Baulig 2018-01-08 10:41:36 UTC
Ancient Mono version.