ssl - Java WebSocket get distinguished name of client -


I have a Java website server running on the glassfish, and users want to connect using client TLS certificates that we Give them The certificate has a specific name that we used to identify the user once a connection has been made to server endpoint , my @OnOpen method is called And it is called the session object.

I can tell that if is session.isSecure () , but nothing more than that, the session object does not give me any visibility in the properties of the TLS connection. How do I obtain the client's specific name when I'm connected via WebSocket?

I believe that can be done in webbook handshake () only.

Websocket is "upgraded" from an HTTP request and the request details are only available during that upgrade request. You can try to remove the user principal from HandshakeRequest , which is normally sent to you by X500Principal .


Comments

Popular posts from this blog

sqlite3 - UPDATE a table from the SELECT of another one -

c# - Showing a SelectedItem's Property -

javascript - Render HTML after each iteration in loop -