-
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
Unable to send multiple certificates in request using .net core 3.1 within HttpClientHandler #66660
Comments
Tagging subscribers to this area: @dotnet/ncl Issue DetailsDescriptionThe code below is only sending 1 certificate even though it loops through 4 certificates and finds 4 certificates
Reproduction StepsFollow code above Expected behaviorExpect the code to send multiple certificates Actual behaviorSending 1 certificate Regression?No response Known WorkaroundsNo response Configuration.net core 3.1 Other informationNo response
|
Why do you expect the code to send multiple certificates? The underlying SslStream selects one at most one certificate (based on whether client cert is required and on the acceptable issuers specified by the server) and will use that one for the connection. That is how SSL/TLS works. Even though the client may also send other certificates to form a chain from the selected chain to some root trusted certificate (for verification purposes), these generally are not the ones in the client certificate collection. |
The request URL expects multiple certificates in order to be able to send a POST request |
Our PFX contains multiple certificates, when we run this manually with a curl command it works |
I think this is dup of #26323. There is only one certificate with private key but there are intermediate CA certificates, right @jaden-patel? |
Hello @wfurt, yes it is! However we have a requirement to use .net core 3.1 - any way round this issue using .net core 3.1? |
The workaround would be adding the intermediate certificates to the windows cert store, this comment (#55368 (comment)) shows how it can be done programmatically. This needs to happen only once on the machine (or until the certificates change). It can also be done by double-clicking the .pfx file in Windows Explorer. Note that you need to select the "Intermediate Certificate Authorities" store in the dialog. |
I don't know anything else for 3.1 besides what @rzikm recommended @jaden-patel. |
Duplicate of #26323 |
Description
The code below is only sending 1 certificate even though it loops through 4 certificates and finds 4 certificates
Reproduction Steps
Follow code above
Expected behavior
Expect the code to send multiple certificates
Actual behavior
Sending 1 certificate
Regression?
No response
Known Workarounds
No response
Configuration
.net core 3.1
Windows
Other information
No response
The text was updated successfully, but these errors were encountered: