AsymmetricCipherKeyPair keys = SecurityHandler.getInstance().getKeyPair(keySize, keyAlgorithm);
byte[] randombyte = new byte[4];
random.nextBytes(randombyte);
session.getDataMap().put("verifytoken", randombyte);
byte[] secret = SecurityHandler.getInstance().encodeKey(keys.getPublic());
session.send(Session.SendType.FORCE, new EncryptionKeyRequestMessage(sessionId, false, secret, randombyte));
} else {
session.disconnect("Handshake already exchanged.");
}
}