Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release/6.0] fix TLS 1.3 in WinHttpHandler #59159

Merged
merged 6 commits into from
Sep 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ public static partial class PlatformDetection

public static bool IsWindows10Version2004Build19573OrGreater => IsWindowsVersionOrLater(10, 0, 19573);

// Windows 11 aka 21H2
public static bool IsWindows10Version22000OrGreater => IsWindowsVersionOrLater(10, 0, 22000);

public static bool IsWindowsIoTCore
{
get
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ public void ToXml()
[ConditionalFact(typeof(Helpers), nameof(Helpers.SupportsEventLogs))]
public void ExceptionOnce()
{
if (PlatformDetection.IsWindows7) // Null events in PowerShell log
if (PlatformDetection.IsWindows7 || // Null events in PowerShell log
PlatformDetection.IsWindows10Version22000OrGreater) // ActiveIssue("https://github.com/dotnet/runtime/issues/58829")
return;
var query = new EventLogQuery("Application", PathType.LogName, "*[System]") { ReverseDirection = true };
var eventLog = new EventLogReader(query, Helpers.GetBookmark("Application", PathType.LogName));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ public void SourceDoesNotExist_Throws()
[InlineData(false)]
public void ProviderNameTests(bool noProviderName)
{
if (PlatformDetection.IsWindows10Version22000OrGreater) // ActiveIssue("https://github.com/dotnet/runtime/issues/58829")
return;

string log = "Application";
string source = "Source_" + nameof(ProviderNameTests);
using (var session = new EventLogSession())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public class WinHttpHandler : HttpMessageHandler

private static readonly StringWithQualityHeaderValue s_gzipHeaderValue = new StringWithQualityHeaderValue("gzip");
private static readonly StringWithQualityHeaderValue s_deflateHeaderValue = new StringWithQualityHeaderValue("deflate");
private static readonly Lazy<bool> s_supportsTls13 = new Lazy<bool>(CheckTls13Support());
private static readonly Lazy<bool> s_supportsTls13 = new Lazy<bool>(() => CheckTls13Support());

[ThreadStatic]
private static StringBuilder? t_requestHeadersBuilder;
Expand Down