-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[QUIC] Certificate Validation with OpenSSL on Windows #55544
Comments
Tagging subscribers to this area: @bartonjs, @vcsjones, @krwq, @GrabYourPitchforks Issue DetailsDescription#51015 breaks the OpenSSL alternative of ConfigurationWindows with OpenSSL build of Regression?Bypass certificate loading in Other informationSChannel on Windows 11 works, OpenSSL on Linux works. QUIC could otherwise be supported on older versions of Windows too.
|
Tagging subscribers to this area: @dotnet/ncl Issue DetailsDescription#51015 breaks the OpenSSL alternative of ConfigurationWindows with OpenSSL build of Regression?Bypass certificate loading in Other informationSChannel on Windows 11 works, OpenSSL on Linux works. QUIC could otherwise be supported on older versions of Windows too.
|
@bartonjs Could be security-related too as the exception is thrown from |
I'm not sure I understand the comment @wegylexy. On Windows with channel the Handle is basically raw pointer to memory. When this is called with openssl backend you basically give it pointer to random memory. It is not surprising that it would crash. If you build MsQuic yourself you could fix up the crypto to cover to PCERT_CONTEXT or set it to null. |
@wfurt I see. So either msquic or .NET needs to convert the raw cert to |
avoiding crash is easy. The real question is how you are going to do real validation and certificate management. cc: @nibanks @ThadHouse |
Finally found it! Lines 122 to 126 in 6ebdf24
|
Description
To support QUIC on older versions of Windows, the OpenSSL build of msquic may substitute. However, the raw certificate needs to be converted to
PCERT_CONTEXT
before loading intoX509Certificate2
. #51015 breaks this scenario due to loading the certificate in the wrong format.Moreover, there should be better a way to disable certificate validation altogether and not attempt to load the certificate, than using a lambda that always returns true.
Configuration
Windows with OpenSSL build of
msquic.dll
, self-signed cert without chain.Regression?
Skip this line https://github.com/dotnet/runtime/blob/main/src/libraries/System.Net.Quic/src/System/Net/Quic/Implementations/MsQuic/MsQuicConnection.cs#L368 and return success.
Other information
SChannel on Windows 11 works, OpenSSL on Linux works. QUIC could otherwise be supported on older versions of Windows too.
The text was updated successfully, but these errors were encountered: