Class OpenSSLEngine
- java.lang.Object
-
- javax.net.ssl.SSLEngine
-
- org.apache.tomcat.util.net.openssl.OpenSSLEngine
-
- All Implemented Interfaces:
SSLUtil.ProtocolInfo
public final class OpenSSLEngine extends SSLEngine implements SSLUtil.ProtocolInfo
Implements aSSLEngineusing OpenSSL BIO abstractions.
-
-
Field Summary
Fields Modifier and Type Field Description static Set<String>AVAILABLE_CIPHER_SUITESstatic Set<String>IMPLEMENTED_PROTOCOLS_SET
-
Method Summary
-
Methods inherited from class javax.net.ssl.SSLEngine
getApplicationProtocol, getHandshakeApplicationProtocol, getHandshakeApplicationProtocolSelector, getHandshakeSession, getPeerHost, getPeerPort, getSSLParameters, setHandshakeApplicationProtocolSelector, setSSLParameters, unwrap, unwrap, wrap, wrap
-
-
-
-
Method Detail
-
getNegotiatedProtocol
public String getNegotiatedProtocol()
Description copied from interface:SSLUtil.ProtocolInfoALPN information.- Specified by:
getNegotiatedProtocolin interfaceSSLUtil.ProtocolInfo- Returns:
- the protocol selected using ALPN
-
shutdown
public void shutdown()
Destroys this engine.
-
wrap
public SSLEngineResult wrap(ByteBuffer[] srcs, int offset, int length, ByteBuffer dst) throws SSLException
- Specified by:
wrapin classSSLEngine- Throws:
SSLException
-
unwrap
public SSLEngineResult unwrap(ByteBuffer src, ByteBuffer[] dsts, int offset, int length) throws SSLException
- Specified by:
unwrapin classSSLEngine- Throws:
SSLException
-
getDelegatedTask
public Runnable getDelegatedTask()
- Specified by:
getDelegatedTaskin classSSLEngine
-
closeInbound
public void closeInbound() throws SSLException- Specified by:
closeInboundin classSSLEngine- Throws:
SSLException
-
isInboundDone
public boolean isInboundDone()
- Specified by:
isInboundDonein classSSLEngine
-
closeOutbound
public void closeOutbound()
- Specified by:
closeOutboundin classSSLEngine
-
isOutboundDone
public boolean isOutboundDone()
- Specified by:
isOutboundDonein classSSLEngine
-
getSupportedCipherSuites
public String[] getSupportedCipherSuites()
- Specified by:
getSupportedCipherSuitesin classSSLEngine
-
getEnabledCipherSuites
public String[] getEnabledCipherSuites()
- Specified by:
getEnabledCipherSuitesin classSSLEngine
-
setEnabledCipherSuites
public void setEnabledCipherSuites(String[] cipherSuites)
- Specified by:
setEnabledCipherSuitesin classSSLEngine
-
getSupportedProtocols
public String[] getSupportedProtocols()
- Specified by:
getSupportedProtocolsin classSSLEngine
-
getEnabledProtocols
public String[] getEnabledProtocols()
- Specified by:
getEnabledProtocolsin classSSLEngine
-
setEnabledProtocols
public void setEnabledProtocols(String[] protocols)
- Specified by:
setEnabledProtocolsin classSSLEngine
-
getSession
public SSLSession getSession()
- Specified by:
getSessionin classSSLEngine
-
beginHandshake
public void beginHandshake() throws SSLException- Specified by:
beginHandshakein classSSLEngine- Throws:
SSLException
-
getHandshakeStatus
public SSLEngineResult.HandshakeStatus getHandshakeStatus()
- Specified by:
getHandshakeStatusin classSSLEngine
-
setUseClientMode
public void setUseClientMode(boolean clientMode)
- Specified by:
setUseClientModein classSSLEngine
-
getUseClientMode
public boolean getUseClientMode()
- Specified by:
getUseClientModein classSSLEngine
-
setNeedClientAuth
public void setNeedClientAuth(boolean b)
- Specified by:
setNeedClientAuthin classSSLEngine
-
getNeedClientAuth
public boolean getNeedClientAuth()
- Specified by:
getNeedClientAuthin classSSLEngine
-
setWantClientAuth
public void setWantClientAuth(boolean b)
- Specified by:
setWantClientAuthin classSSLEngine
-
getWantClientAuth
public boolean getWantClientAuth()
- Specified by:
getWantClientAuthin classSSLEngine
-
setEnableSessionCreation
public void setEnableSessionCreation(boolean b)
- Specified by:
setEnableSessionCreationin classSSLEngine
-
getEnableSessionCreation
public boolean getEnableSessionCreation()
- Specified by:
getEnableSessionCreationin classSSLEngine
-
-