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

ClientHello Callback #90

Closed
SteveSelva opened this issue May 25, 2023 · 4 comments
Closed

ClientHello Callback #90

SteveSelva opened this issue May 25, 2023 · 4 comments

Comments

@SteveSelva
Copy link

Does Fizz has callback function at the ClientHello message in TLS handshake?

@knekritz
Copy link
Contributor

Currently there is no general purpose callback. Depending on your goal though, there are a number of ways to change behavior based on information in the ClientHello (eg, to select a certificate based on SNI you can implement a custom CertManager https://github.com/facebookincubator/fizz/blob/main/fizz/server/CertManager.h#L37, or use the default implementation which will select a certificate based on the SNI and SANs in the configured certificates).

@SteveSelva
Copy link
Author

I want to generate a SSL Certificate on the fly using the SNI extension from the ClientHello message. Is this approach possible with the CertManager and if so how to do? Can you provide a example code please.

@knekritz
Copy link
Contributor

knekritz commented Jun 1, 2023

Yes, it's certainly possible to generate a new cert on the fly in the CertManager (with a custom implementation of getCert()).

@SteveSelva
Copy link
Author

Thanks @knekritz for your assistance.

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

No branches or pull requests

2 participants