Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Expose QUIC TLS details on QuicConnection. #106391

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

Merged
merged 5 commits into from
Aug 15, 2024
Merged

Conversation

rzikm
Copy link
Member

@rzikm rzikm commented Aug 14, 2024

Alternative to #106368
Implements #70184.

Since TLS state is dropped by MsQuic after handshake since it is no longer needed, we need to retrieve TLS info during the CONNECTED event (as we do for negotiated ALPN)

cc: @wfurt

Copy link

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

Copy link

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

Copy link
Contributor

Tagging subscribers to this area: @dotnet/ncl
See info in area-owners.md if you want to be subscribed.

@rzikm rzikm requested a review from a team August 14, 2024 13:02
@rzikm rzikm added this to the 10.0.0 milestone Aug 14, 2024
@rzikm rzikm added the NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) label Aug 14, 2024
@rzikm
Copy link
Member Author

rzikm commented Aug 14, 2024

No-Merge until main becomes 10.0

QUIC_CIPHER_SUITE.TLS_CHACHA20_POLY1305_SHA256 => TlsCipherSuite.TLS_CHACHA20_POLY1305_SHA256,
_ => default
};
_negotiatedSslProtocol = info.TlsProtocolVersion switch
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if we need to bother at all ... at least until there is Tls 1.4. If anythiung I would Debug.Assert here as reminder.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we actually don't need to bother with either of the switches, the enum values are the same so we can cast directly.

I added assert for TLS 1.3 and unit test for cipher suites so that we notice if something changes.

@rzikm rzikm removed the NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) label Aug 15, 2024
@rzikm rzikm merged commit 042cc95 into dotnet:main Aug 15, 2024
84 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Sep 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants