Skip to content
This repository has been archived by the owner on Feb 11, 2023. It is now read-only.

Don't force TLS 1.0 #29

Open
nico159 opened this issue Sep 19, 2017 · 7 comments
Open

Don't force TLS 1.0 #29

nico159 opened this issue Sep 19, 2017 · 7 comments

Comments

@nico159
Copy link

nico159 commented Sep 19, 2017

Hi,

In ExecuteRequest nemiro.oauth is forcing the use of TLS 1.0 as security protocol.
This make impossible to connect to web servers that only support TLS 1.1/1.2 failing with "An existing connection was forcibly closed by the remote host".

One quick fix is simply replacing that line with:
ServicePointManager.SecurityProtocol |= SecurityProtocolType.Tls;
So that it will allow TLS 1.0 while still keeping the other protocols enabled.

But I think that don't enabling TLS 1.0 at all would be the a wiser way to go. I don't think that a library should touch ServicePointManager.SecurityProtocol.

@alekseynemiro
Copy link
Member

I will check it.

Unfortunately now there is no time and I can not say when the result will be.

Thank you for message.

@cboyce428
Copy link

This must be why linkedin has stopped working! https://developer.linkedin.com/docs/guide/v2/concepts/authentication

Starting 10 October 2017 developers must use TLS 1.1 or 1.2 when calling LinkedIn APIs. LinkedIn no longer supports TLS 1.0 for security reasons.

@bveldkamp
Copy link

bveldkamp commented Jul 11, 2019

Any chance of fixing this anytime soon?

@securigy
Copy link

securigy commented Feb 6, 2020

I wonder if the TLS 1.2 protocol issue was ever resolved for LinkedIn login...
When I try the LinkedIn login - after user approves/authorizes I get an error message:
"The request was aborted: could not create SSL/TLS secure channel."

I tried to comment the line:
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls;

I also tried this:
ServicePointManager.SecurityProtocol |= SecurityProtocolType.Tls;
and tried to use a real numeric value 3072, which is enumeration value for TLS 1.2
ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072;

However, it did not resolve the issue...
Any ideas/solutions?

EDIT: Correction - after recompiling either of the lines in bold above works!

@adamtoakley
Copy link

Anytime this will get fixed?

@bveldkamp
Copy link

Still doesn't work. More and more services are TLS 1.2 only so this is a real show-stopper

@bjoernisemann
Copy link

Guys, its pretty easy to fix by yourself: File: OAuthUtility.cs, Line around 495

var securityProtocol = ServicePointManager.SecurityProtocol;

  ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;

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

No branches or pull requests

7 participants