Class CramerShoupParametersGenerator
java.lang.Object
org.bouncycastle.crypto.generators.CramerShoupParametersGenerator
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionwhich generates the p and g values from the given parameters, returning the CramerShoupParameters object.generateParameters(DHParameters dhParams) voidinit(int size, int certainty, SecureRandom random) Initialise the parameters generator.
-
Constructor Details
-
CramerShoupParametersGenerator
public CramerShoupParametersGenerator()
-
-
Method Details
-
init
Initialise the parameters generator.- Parameters:
size- bit length for the prime pcertainty- a measure of the uncertainty that the caller is willing to tolerate: the probability that the generated modulus is prime exceeds (1 - 1/2^certainty). The execution time of this method is proportional to the value of this parameter.random- a source of randomness
-
generateParameters
which generates the p and g values from the given parameters, returning the CramerShoupParameters object.Note: can take a while...
- Returns:
- a generated CramerShoupParameters object.
-
generateParameters
-