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

Expose TLS.supportedHashSignatures via TLSSettings #872

Closed
wants to merge 1 commit into from
Closed

Expose TLS.supportedHashSignatures via TLSSettings #872

wants to merge 1 commit into from

Conversation

miguelclean
Copy link
Contributor

Proposal

I noticed that with TLS1.2 the Client Certifiicate Types provided in the Client Certificate Request generated during handskake, are derived from TLS.supportedHashSingatures (see code snipplet below)

I do not see any way to control this value, when using runTLS so propose to expose it via TLSSettings.

excerpt from Network.TLS.Handshake.Server:

(certTypes, hashSigs)
                        | usedVersion < TLS12 = (defaultCertTypes, Nothing)
                        | otherwise =
                            let as = supportedHashSignatures $ ctxSupported ctx
                             in (nub $ mapMaybe hashSigToCertType as, Just as)

Motivation

Some of the Client Certificate Types returned, using the default TLS.supportedHashSignatures seem not to be recognized by calling clients:

$ openssl s_client -tls1_2 -port 1234 -host localhost | grep "Client Certificate Types"
Client Certificate Types: UNKNOWN (0),, UNKNOWN (0),, ECDSA sign, RSA sign, DSA sign

We encountered instances of clients that seem unable to cope with that at all.

@kazu-yamamoto kazu-yamamoto self-requested a review March 7, 2022 19:45
kazu-yamamoto added a commit to kazu-yamamoto/wai that referenced this pull request Mar 7, 2022
Copy link
Contributor

@kazu-yamamoto kazu-yamamoto left a comment

Choose a reason for hiding this comment

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

LGTM

@kazu-yamamoto
Copy link
Contributor

Rebased and merged. Thank you for your contribution!

@kazu-yamamoto
Copy link
Contributor

If you would like to have a new release, please let me know.

@miguelclean
Copy link
Contributor Author

Thanks. No need for new release.

@miguelclean miguelclean closed this Mar 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants