michaeljmarshall opened a new pull request, #3310:
URL: https://github.com/apache/bookkeeper/pull/3310

   ### Motivation
   
   Currently, we initiate hostname verification for the Bookkeeper Client in 
the `PerChannelBookieClient` class. In order to simplify the code, I propose 
that we refactor the client so it relies on Netty, its SslHandler, and the JVM, 
to perform the hostname verification.
   
   When HTTPS is configured as the endpoint verification algorithm, it uses 
[RFC 2818](https://datatracker.ietf.org/doc/html/rfc2818) to perform hostname 
verification. This is defined by the Java Security Standard Algorithm Names 
documentation for JDK versions 8, 11, and 17. Here are the official docs:
   
       
https://docs.oracle.com/javase/8/docs/technotes/guides/security/StandardNames.html
       
https://docs.oracle.com/en/java/javase/11/docs/specs/security/standard-names.html
       
https://docs.oracle.com/en/java/javase/17/docs/specs/security/standard-names.html
   
   ### Changes
   
   * Rely on Netty and the SslEngine to perform hostname verification. With 
this change, CN matching is now deprecated, which brings the bookkeeper client 
in alignment with RFC 2818.
   * Add new method to the `SecurityHandlerFactory` interface. It is named 
`newTLSHandler` and takes the `host` and `port` of the remote peer when 
creating a new SslEngine. To ensure backwards compatibility, the default 
implementation will call the original method. Note that the remote host and 
port are only needed when a client is using them for hostname verification.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to