-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Introduce ListenOptions.GetServerCertificate #48054
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
Conversation
...as a way to retrieve the server certificate eagerly (assuming the configuration has been loaded), rather than having to wait until bind-time. Fixes dotnet#28120
|
Waiting for API approval (and PR approval, obviously). |
mitchdenny
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
Is there an API review for this? |
|
| { | ||
| ran1 = true; | ||
| var serverCertificate = listenOptions.GetServerCertificate(); | ||
| Assert.Equal(serverCertificate.SerialNumber, certificate.SerialNumber); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some of the asserts are in the wrong order. It's generally Assert.Something(expected, actual)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, but I was following the pattern of the nearby tests.
Tratcher
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this needs a different design. I've left notes on the API review.
|
We're going to try to fix things without a new API. |
Introduce ListenOptions.GetServerCertificate
An API to retrieve the cert for an endpoint
Description
Introduce ListenOptions.GetServerCertificate as a way to retrieve the server certificate eagerly (assuming the configuration has been loaded), rather than having to wait until bind-time.
Fixes #28120
Unblocks #45801