Class SslSocket
java.lang.Object
java.net.Socket
javax.net.ssl.SSLSocket
ecmwf.common.security.SslSocket
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds the handshake completed listener.void
bind
(SocketAddress bindpoint) Bind.void
close()
Close.void
connect
(SocketAddress endpoint) Connect.void
connect
(SocketAddress endpoint, int timeout) Connect.boolean
Equals.Gets the channel.String[]
Gets the enabled cipher suites.String[]
Gets the enabled protocols.boolean
Gets the enable session creation.Gets the inet address.Gets the input stream.boolean
Gets the keep alive.Gets the local address.int
Gets the local port.Gets the local socket address.boolean
Gets the need client auth.boolean
Gets the OOB inline.Gets the output stream.int
getPort()
Gets the port.int
Gets the receive buffer size.Gets the remote socket address.boolean
Gets the reuse address.int
Gets the send buffer size.Gets the session.int
Gets the so linger.int
Gets the so timeout.String[]
Gets the supported cipher suites.String[]
Gets the supported protocols.boolean
Gets the tcp no delay.int
Gets the traffic class.boolean
Gets the use client mode.boolean
Gets the want client auth.int
hashCode()
Hash code.boolean
isBound()
Checks if is bound.boolean
isClosed()
Checks if is closed.boolean
Checks if is connected.boolean
Checks if is input shutdown.boolean
Checks if is output shutdown.void
Removes the handshake completed listener.void
sendUrgentData
(int data) Send urgent data.void
Sets the enabled cipher suites.void
Sets the enabled protocols.void
setEnableSessionCreation
(boolean b) Sets the enable session creation.void
setKeepAlive
(boolean on) Sets the keep alive.void
setNeedClientAuth
(boolean b) Sets the need client auth.void
setOOBInline
(boolean on) Sets the OOB inline.void
setPerformancePreferences
(int connectionTime, int latency, int bandwidth) Sets the performance preferences.void
setReceiveBufferSize
(int size) Sets the receive buffer size.void
setReuseAddress
(boolean on) Sets the reuse address.void
setSendBufferSize
(int size) Sets the send buffer size.void
setSoLinger
(boolean on, int linger) Sets the so linger.void
setSoTimeout
(int timeout) Sets the so timeout.void
setTcpNoDelay
(boolean on) Sets the tcp no delay.void
setTrafficClass
(int tc) Sets the traffic class.void
setUseClientMode
(boolean b) Sets the use client mode.void
setWantClientAuth
(boolean b) Sets the want client auth.void
Shutdown input.void
Shutdown output.void
Start handshake.toString()
To string.Methods inherited from class javax.net.ssl.SSLSocket
getApplicationProtocol, getHandshakeApplicationProtocol, getHandshakeApplicationProtocolSelector, getHandshakeSession, getSSLParameters, setHandshakeApplicationProtocolSelector, setSSLParameters
Methods inherited from class java.net.Socket
getOption, setOption, setSocketImplFactory, supportedOptions
-
Field Details
-
decoratee
The decoratee.
-
-
Method Details
-
bind
Bind.- Overrides:
bind
in classSocket
- Throws:
IOException
-
close
Close.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classSocket
- Throws:
IOException
-
connect
Connect.- Overrides:
connect
in classSocket
- Throws:
IOException
-
connect
Connect.- Overrides:
connect
in classSocket
- Throws:
IOException
-
equals
-
getChannel
-
getInetAddress
Gets the inet address.- Overrides:
getInetAddress
in classSocket
-
getInputStream
Gets the input stream.- Overrides:
getInputStream
in classSocket
- Throws:
IOException
-
getKeepAlive
Gets the keep alive.- Overrides:
getKeepAlive
in classSocket
- Throws:
SocketException
-
getLocalAddress
Gets the local address.- Overrides:
getLocalAddress
in classSocket
-
getLocalPort
-
getLocalSocketAddress
Gets the local socket address.- Overrides:
getLocalSocketAddress
in classSocket
-
getOOBInline
Gets the OOB inline.- Overrides:
getOOBInline
in classSocket
- Throws:
SocketException
-
getOutputStream
Gets the output stream.- Overrides:
getOutputStream
in classSocket
- Throws:
IOException
-
getPort
-
getReceiveBufferSize
Gets the receive buffer size.- Overrides:
getReceiveBufferSize
in classSocket
- Throws:
SocketException
-
getRemoteSocketAddress
Gets the remote socket address.- Overrides:
getRemoteSocketAddress
in classSocket
-
getReuseAddress
Gets the reuse address.- Overrides:
getReuseAddress
in classSocket
- Throws:
SocketException
-
getSendBufferSize
Gets the send buffer size.- Overrides:
getSendBufferSize
in classSocket
- Throws:
SocketException
-
getSoLinger
Gets the so linger.- Overrides:
getSoLinger
in classSocket
- Throws:
SocketException
-
getSoTimeout
Gets the so timeout.- Overrides:
getSoTimeout
in classSocket
- Throws:
SocketException
-
getTcpNoDelay
Gets the tcp no delay.- Overrides:
getTcpNoDelay
in classSocket
- Throws:
SocketException
-
getTrafficClass
Gets the traffic class.- Overrides:
getTrafficClass
in classSocket
- Throws:
SocketException
-
hashCode
-
isBound
-
isClosed
-
isConnected
-
isInputShutdown
public boolean isInputShutdown()Checks if is input shutdown.- Overrides:
isInputShutdown
in classSocket
-
isOutputShutdown
public boolean isOutputShutdown()Checks if is output shutdown.- Overrides:
isOutputShutdown
in classSocket
-
sendUrgentData
Send urgent data.- Overrides:
sendUrgentData
in classSocket
- Throws:
IOException
-
setKeepAlive
Sets the keep alive.- Overrides:
setKeepAlive
in classSocket
- Throws:
SocketException
-
setOOBInline
Sets the OOB inline.- Overrides:
setOOBInline
in classSocket
- Throws:
SocketException
-
setPerformancePreferences
public void setPerformancePreferences(int connectionTime, int latency, int bandwidth) Sets the performance preferences.- Overrides:
setPerformancePreferences
in classSocket
-
setReceiveBufferSize
Sets the receive buffer size.- Overrides:
setReceiveBufferSize
in classSocket
- Throws:
SocketException
-
setReuseAddress
Sets the reuse address.- Overrides:
setReuseAddress
in classSocket
- Throws:
SocketException
-
setSendBufferSize
Sets the send buffer size.- Overrides:
setSendBufferSize
in classSocket
- Throws:
SocketException
-
setSoLinger
Sets the so linger.- Overrides:
setSoLinger
in classSocket
- Throws:
SocketException
-
setSoTimeout
Sets the so timeout.- Overrides:
setSoTimeout
in classSocket
- Throws:
SocketException
-
setTcpNoDelay
Sets the tcp no delay.- Overrides:
setTcpNoDelay
in classSocket
- Throws:
SocketException
-
setTrafficClass
Sets the traffic class.- Overrides:
setTrafficClass
in classSocket
- Throws:
SocketException
-
shutdownInput
Shutdown input.- Overrides:
shutdownInput
in classSocket
- Throws:
IOException
-
shutdownOutput
Shutdown output.- Overrides:
shutdownOutput
in classSocket
- Throws:
IOException
-
toString
-
addHandshakeCompletedListener
Adds the handshake completed listener.- Specified by:
addHandshakeCompletedListener
in classSSLSocket
-
getSupportedProtocols
Gets the supported protocols.- Specified by:
getSupportedProtocols
in classSSLSocket
-
getEnabledProtocols
Gets the enabled protocols.- Specified by:
getEnabledProtocols
in classSSLSocket
-
getSupportedCipherSuites
Gets the supported cipher suites.- Specified by:
getSupportedCipherSuites
in classSSLSocket
-
getEnabledCipherSuites
Gets the enabled cipher suites.- Specified by:
getEnabledCipherSuites
in classSSLSocket
-
setEnabledCipherSuites
Sets the enabled cipher suites.- Specified by:
setEnabledCipherSuites
in classSSLSocket
-
setEnabledProtocols
Sets the enabled protocols.- Specified by:
setEnabledProtocols
in classSSLSocket
-
setUseClientMode
public void setUseClientMode(boolean b) Sets the use client mode.- Specified by:
setUseClientMode
in classSSLSocket
-
getUseClientMode
public boolean getUseClientMode()Gets the use client mode.- Specified by:
getUseClientMode
in classSSLSocket
-
getEnableSessionCreation
public boolean getEnableSessionCreation()Gets the enable session creation.- Specified by:
getEnableSessionCreation
in classSSLSocket
-
removeHandshakeCompletedListener
Removes the handshake completed listener.- Specified by:
removeHandshakeCompletedListener
in classSSLSocket
-
setEnableSessionCreation
public void setEnableSessionCreation(boolean b) Sets the enable session creation.- Specified by:
setEnableSessionCreation
in classSSLSocket
-
setNeedClientAuth
public void setNeedClientAuth(boolean b) Sets the need client auth.- Specified by:
setNeedClientAuth
in classSSLSocket
-
setWantClientAuth
public void setWantClientAuth(boolean b) Sets the want client auth.- Specified by:
setWantClientAuth
in classSSLSocket
-
startHandshake
Start handshake.- Specified by:
startHandshake
in classSSLSocket
- Throws:
IOException
-
getNeedClientAuth
public boolean getNeedClientAuth()Gets the need client auth.- Specified by:
getNeedClientAuth
in classSSLSocket
-
getWantClientAuth
public boolean getWantClientAuth()Gets the want client auth.- Specified by:
getWantClientAuth
in classSSLSocket
-
getSession
-