Package naga
Interface NIOSocketSSL
-
- All Superinterfaces:
NIOAbstractSocket
,NIOSocket
public interface NIOSocketSSL extends NIOSocket
Interface for a SSL Socket- Author:
- Christoffer Lerno
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
beginHandshake()
Initiates SSL-handshake, starts encrypted communication.javax.net.ssl.SSLEngine
getSSLEngine()
Returns the SSLEngine in use for this socket.boolean
isEncrypted()
-
Methods inherited from interface naga.NIOAbstractSocket
close, getAddress, getIp, getPort, getTag, isOpen, setTag
-
Methods inherited from interface naga.NIOSocket
closeAfterWrite, getBytesRead, getBytesWritten, getMaxQueueSize, getTimeOpen, getWriteQueueSize, listen, queue, setMaxQueueSize, setPacketReader, setPacketWriter, socket, write, write
-
-
-
-
Method Detail
-
getSSLEngine
javax.net.ssl.SSLEngine getSSLEngine()
Returns the SSLEngine in use for this socket.- Returns:
- an SSLEngine.
-
beginHandshake
void beginHandshake() throws javax.net.ssl.SSLException
Initiates SSL-handshake, starts encrypted communication.- Throws:
javax.net.ssl.SSLException
-
isEncrypted
boolean isEncrypted()
- Returns:
- true if handshake is initiated and consequent data will be encrypted.
-
-