Netflix / msl

Message Security Layer
Apache License 2.0
716 stars 79 forks source link

Allow callers to disable handshake attempts #309

Open wmiaw opened 4 years ago

wmiaw commented 4 years ago

There may be some situations where a caller (i.e. MessageContext) would like to prevent any handshake attempts from being made, even if it comes at the cost of successful transmission of their application data.

A MessageContext.isHandshakePermitted() function or something similar could be used by MslControl to throw a local exception if a handshake is required but not permitted.