public class DHParameterSpec extends Object implements AlgorithmParameterSpec
Each set of parameters consists of a base generator
g, a prime modulus p, and an
optional length, in bits, of the private exponent.
See PKCS #3 - Diffie-Hellman Key Agreement Standard for more information.
KeyAgreement| Constructor and Description |
|---|
DHParameterSpec(BigInteger p,
BigInteger g)
Create a new set of Diffie-Hellman parameters.
|
DHParameterSpec(BigInteger p,
BigInteger g,
int l)
Create a new set of Diffie-Hellman parameters.
|
| Modifier and Type | Method and Description |
|---|---|
BigInteger |
getG()
Get the base generator, g.
|
int |
getL()
Get the length of the private exponent, in bits.
|
BigInteger |
getP()
Get the prime modulus, p.
|
public DHParameterSpec(BigInteger p, BigInteger g)
p - The prime modulus.g - The base generator.public DHParameterSpec(BigInteger p, BigInteger g, int l)
p - The prime modulus.g - The base generator.l - The size of the private exponent, in bits.public BigInteger getG()
public int getL()
public BigInteger getP()