java.security.spec
Class DSAPrivateKeySpec

java.lang.Object sample code for java.lang.Object definition code for java.lang.Object 
  extended by java.security.spec.DSAPrivateKeySpec
All Implemented Interfaces:
KeySpec sample code for java.security.spec.KeySpec definition code for java.security.spec.KeySpec

public class DSAPrivateKeySpec
extends Object sample code for java.lang.Object definition code for java.lang.Object
implements KeySpec sample code for java.security.spec.KeySpec definition code for java.security.spec.KeySpec

This class specifies a DSA private key with its associated parameters.

Since:
1.2
See Also:
Key sample code for java.security.Key definition code for java.security.Key , KeyFactory sample code for java.security.KeyFactory definition code for java.security.KeyFactory , KeySpec sample code for java.security.spec.KeySpec definition code for java.security.spec.KeySpec , DSAPublicKeySpec sample code for java.security.spec.DSAPublicKeySpec definition code for java.security.spec.DSAPublicKeySpec , PKCS8EncodedKeySpec sample code for java.security.spec.PKCS8EncodedKeySpec definition code for java.security.spec.PKCS8EncodedKeySpec

Constructor Summary
DSAPrivateKeySpec sample code for java.security.spec.DSAPrivateKeySpec.DSAPrivateKeySpec(java.math.BigInteger, java.math.BigInteger, java.math.BigInteger, java.math.BigInteger) definition code for java.security.spec.DSAPrivateKeySpec.DSAPrivateKeySpec(java.math.BigInteger, java.math.BigInteger, java.math.BigInteger, java.math.BigInteger) (BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  x, BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  p, BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  q, BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  g)
          Creates a new DSAPrivateKeySpec with the specified parameter values.
 
Method Summary
 BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger getG sample code for java.security.spec.DSAPrivateKeySpec.getG() definition code for java.security.spec.DSAPrivateKeySpec.getG() ()
          Returns the base g.
 BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger getP sample code for java.security.spec.DSAPrivateKeySpec.getP() definition code for java.security.spec.DSAPrivateKeySpec.getP() ()
          Returns the prime p.
 BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger getQ sample code for java.security.spec.DSAPrivateKeySpec.getQ() definition code for java.security.spec.DSAPrivateKeySpec.getQ() ()
          Returns the sub-prime q.
 BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger getX sample code for java.security.spec.DSAPrivateKeySpec.getX() definition code for java.security.spec.DSAPrivateKeySpec.getX() ()
          Returns the private key x.
 
Methods inherited from class java.lang.Object sample code for java.lang.Object definition code for java.lang.Object
clone sample code for java.lang.Object.clone() definition code for java.lang.Object.clone() , equals sample code for java.lang.Object.equals(java.lang.Object) definition code for java.lang.Object.equals(java.lang.Object) , finalize sample code for java.lang.Object.finalize() definition code for java.lang.Object.finalize() , getClass sample code for java.lang.Object.getClass() definition code for java.lang.Object.getClass() , hashCode sample code for java.lang.Object.hashCode() definition code for java.lang.Object.hashCode() , notify sample code for java.lang.Object.notify() definition code for java.lang.Object.notify() , notifyAll sample code for java.lang.Object.notifyAll() definition code for java.lang.Object.notifyAll() , toString sample code for java.lang.Object.toString() definition code for java.lang.Object.toString() , wait sample code for java.lang.Object.wait() definition code for java.lang.Object.wait() , wait sample code for java.lang.Object.wait(long) definition code for java.lang.Object.wait(long) , wait sample code for java.lang.Object.wait(long, int) definition code for java.lang.Object.wait(long, int)
 

Constructor Detail

DSAPrivateKeySpec sample code for java.security.spec.DSAPrivateKeySpec(java.math.BigInteger, java.math.BigInteger, java.math.BigInteger, java.math.BigInteger) definition code for java.security.spec.DSAPrivateKeySpec(java.math.BigInteger, java.math.BigInteger, java.math.BigInteger, java.math.BigInteger)

public DSAPrivateKeySpec(BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  x,
                         BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  p,
                         BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  q,
                         BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  g)
Creates a new DSAPrivateKeySpec with the specified parameter values.

Parameters:
x - the private key.
p - the prime.
q - the sub-prime.
g - the base.
Method Detail

getX sample code for java.security.spec.DSAPrivateKeySpec.getX() definition code for java.security.spec.DSAPrivateKeySpec.getX()

public BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  getX()
Returns the private key x.

Returns:
the private key x.

getP sample code for java.security.spec.DSAPrivateKeySpec.getP() definition code for java.security.spec.DSAPrivateKeySpec.getP()

public BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  getP()
Returns the prime p.

Returns:
the prime p.

getQ sample code for java.security.spec.DSAPrivateKeySpec.getQ() definition code for java.security.spec.DSAPrivateKeySpec.getQ()

public BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  getQ()
Returns the sub-prime q.

Returns:
the sub-prime q.

getG sample code for java.security.spec.DSAPrivateKeySpec.getG() definition code for java.security.spec.DSAPrivateKeySpec.getG()

public BigInteger sample code for java.math.BigInteger definition code for java.math.BigInteger  getG()
Returns the base g.

Returns:
the base g.