public class DHParametersGenerator
extends java.lang.Object
| Constructor | Description |
|---|---|
DHParametersGenerator() |
| Modifier and Type | Method | Description |
|---|---|---|
DHParameters |
generateParameters() |
which generates the p and g values from the given parameters,
returning the DHParameters object.
|
void |
init(int size,
int certainty,
java.security.SecureRandom random) |
Initialise the parameters generator.
|
public void init(int size,
int certainty,
java.security.SecureRandom random)
size - bit length for the prime pcertainty - level of certainty for the prime number testsrandom - a source of randomnesspublic DHParameters generateParameters()
Note: can take a while...