ktorio / ktor

Framework for quickly creating connected applications in Kotlin with minimal effort
https://ktor.io
Apache License 2.0
12.71k stars 1.04k forks source link

Allow configuring client certificate auth in Netty engine #595

Closed mwudka closed 1 year ago

mwudka commented 5 years ago

The Netty engine config allows configuring the server's SSL parameters, but it doesn't expose the SslContextBuilder. This makes it hard to create a ktor server that requires clients to supply a certificate verified against a custom CA. It would be great if the Netty engine config allowed specifying that client certificates are required, and a custom trust store for validating them.

belobrov-andrey commented 4 years ago

@mwudka Is there a workaround? Can you provide code sample how to enable client certificate verification in Ktor server?

oleg-larshin commented 4 years ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.