cryptix.provider.elgamal

Class BaseElGamalParams

Implemented Interfaces:
ElGamalParams

public class BaseElGamalParams
extends java.lang.Object
implements ElGamalParams

Class representing an ElGamal-specific set of key parameters, which defines an ElGamal key family.

The same key parameters apply to both the signature and encryption algorithms.

References:

  1. Bruce Schneier, "Section 19.6 ElGamal," Applied Cryptography, 2nd Edition, John Wiley & Sons, 1996.

  2. IEEE P1363 draft standard, http://stdsbbs.ieee.org/groups/1363/index.html

Copyright © 1997 Systemics Ltd on behalf of the Cryptix Development Team.
All rights reserved.

$Revision: 1.2 $

Author:
David Hopwood
Since:
Cryptix 2.2.2
See Also:
ElGamalKey, java.security.Key, java.security.Cipher, java.security.Signature

Field Summary

protected BigInteger
g
protected BigInteger
p

Constructor Summary

BaseElGamalParams(BigInteger p, BigInteger g)
Construct an ElGamalParams object with the specified prime p, and base g.

Method Summary

BigInteger
getG()
Returns the base, g.
BigInteger
getP()
Returns the prime, p.

Field Details

g

protected BigInteger g

p

protected BigInteger p

Constructor Details

BaseElGamalParams

public BaseElGamalParams(BigInteger p,
                         BigInteger g)
Construct an ElGamalParams object with the specified prime p, and base g.

Method Details

getG

public BigInteger getG()
Returns the base, g.
Specified by:
getG in interface ElGamalParams
Returns:
the base as a java.math.BigInteger

getP

public BigInteger getP()
Returns the prime, p.
Specified by:
getP in interface ElGamalParams
Returns:
the prime as a java.math.BigInteger