vert-x3 / vertx-stomp

STOMP client/server implementation
Apache License 2.0
31 stars 28 forks source link

vertx-x3#47 - Class field access for socket is too restrictive #49

Closed lfmunoz closed 5 years ago

lfmunoz commented 5 years ago

Didn't link to https://github.com/vert-x3/vertx-stomp/issues/47

cescoffier commented 5 years ago

Do you have a use case? What about providing a getter method instead?

lfmunoz commented 5 years ago

@cescoffier Use case is: https://github.com/vert-x3/vertx-stomp/issues/47 . The use case is when we need to look at the certificate that is related to a specific socket. Yes providing a getter also works, and also just returning the call from peerCertificateChain() or sslSession() will also work, because both NetSocket (StompServerTCPConnectionImpl) and ServerWebSocket (StompServerWebSocketConnectionImpl) have that function. I'll change it to whatever you think is best. Just need a way to access the certificate.

Edit: We need to look at the certificate because some applications required that not only the certificate be valid but it must have some specific information. For example, look at this standard

https://usp.technology/specification/security/#agent_authentication

it says:

R-SEC.10 - An Agent certificate MUST contain the URN form of the Agent Endpoint ID in the subjectaltName with a type uniformResourceIdentifier attribute.

The requirement is that the certificate must contain some string on the certificate.

lfmunoz commented 5 years ago

yes signed Eclipse CLA

cescoffier commented 5 years ago

Thanks!