public static AsymmetricCipherKeyPair generateDHKeyPair(SecureRandom random,
DHParameters dhParams)
{
DHBasicKeyPairGenerator dhGen = new DHBasicKeyPairGenerator();
dhGen.init(new DHKeyGenerationParameters(random, dhParams));
return dhGen.generateKeyPair();
}
public static DHPrivateKeyParameters generateEphemeralClientKeyExchange(SecureRandom random,
DHParameters dhParams, OutputStream output)
throws IOException