public class KexManager extends Object implements MessageHandler
Constructor and Description |
---|
KexManager(TransportManager tm,
ClientServerHello csh,
CryptoWishList initialCwl,
String hostname,
int port,
ServerHostKeyVerifier keyVerifier,
SecureRandom rnd) |
Modifier and Type | Method and Description |
---|---|
static void |
checkKexAlgorithmList(String[] algos) |
static void |
checkServerHostkeyAlgorithmsList(String[] algos) |
static String[] |
getDefaultKexAlgorithmList() |
static String[] |
getDefaultServerHostkeyAlgorithmList() |
ConnectionInfo |
getOrWaitForConnectionInfo(int minKexCount) |
void |
handleEndMessage(Throwable cause)
Called to inform that no more messages will be delivered.
|
void |
handleMessage(byte[] msg,
int msglen)
Handle message.
|
void |
initiateKEX(CryptoWishList cwl,
DHGexParameters dhgex) |
public KexManager(TransportManager tm, ClientServerHello csh, CryptoWishList initialCwl, String hostname, int port, ServerHostKeyVerifier keyVerifier, SecureRandom rnd)
public ConnectionInfo getOrWaitForConnectionInfo(int minKexCount) throws IOException
IOException
public void initiateKEX(CryptoWishList cwl, DHGexParameters dhgex) throws IOException
IOException
public static String[] getDefaultServerHostkeyAlgorithmList()
public static void checkServerHostkeyAlgorithmsList(String[] algos)
public static String[] getDefaultKexAlgorithmList()
public static void checkKexAlgorithmList(String[] algos)
public void handleMessage(byte[] msg, int msglen) throws IOException
MessageHandler
handleMessage
in interface MessageHandler
msg
- the msgmsglen
- the msglenIOException
- the io exceptionpublic void handleEndMessage(Throwable cause) throws IOException
MessageHandler
handleEndMessage
in interface MessageHandler
cause
- For diagnosis, the reason that caused the transport to close down.IOException
- the io exceptionCopyright © 2020. All rights reserved.