DotNetTor
DotNetTor copied to clipboard
Fix Linux/OSX HTTPS, OpenSSL, .NET Core bug
.NET Core behaves differently on Windows and Linux. Maybe wait until it gets fixed?
3de217ffcacf9bfc2aec2e8388192b4eee852d3a
SslStream httpsStream;
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
httpsStream = new SslStream(stream, leaveInnerStreamOpen: true);
else // TODO: Fix this security vulnerability
{
httpsStream = new SslStream(
stream,
leaveInnerStreamOpen: true,
userCertificateValidationCallback: (a, b, c, d) => true);
}
Made it optional and default false: SocksPortHandler.IgnoreSslCertification
Should be fixed in .NET Core and not just hacked around.
Issue opened: https://github.com/dotnet/corefx/issues/21761
Need .NET Core SNI feature: https://github.com/dotnet/corefx/issues/9608
Fixed in .NET Core 3.1: https://github.com/nopara73/SslStreamBugCore3