de.flexiprovider.core.dsa
Class DSAParamGenParameterSpec

java.lang.Object
  |
  +--de.flexiprovider.core.dsa.DSAParamGenParameterSpec
All Implemented Interfaces:
AlgorithmParameterSpec, java.security.spec.AlgorithmParameterSpec

public class DSAParamGenParameterSpec
extends java.lang.Object
implements AlgorithmParameterSpec

This class specifies parameters used for initializing the DSAParameterGenerator. The parameters consist of the bit size of the prime p.

Author:
Martin Döring

Field Summary
static int DEFAULT_L
          The default bit length of the prime p (1024 bits).
static int DEFAULT_N
          The default bit length of the prime q.
 
Constructor Summary
DSAParamGenParameterSpec()
          Constructor.
DSAParamGenParameterSpec(int keySize)
          Constructor.
DSAParamGenParameterSpec(int L, int N)
          Constructor.
 
Method Summary
 int getL()
           
 int getN()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_L

public static final int DEFAULT_L
The default bit length of the prime p (1024 bits).

DEFAULT_N

public static final int DEFAULT_N
The default bit length of the prime q.
Constructor Detail

DSAParamGenParameterSpec

public DSAParamGenParameterSpec()
Constructor. Set the default parameters.

DSAParamGenParameterSpec

public DSAParamGenParameterSpec(int keySize)
                         throws InvalidParameterException
Constructor.
Parameters:
keySize - the bit length of the prime p (1024 or 2048)
Throws:
InvalidParameterException - if the key size is invalid.

DSAParamGenParameterSpec

public DSAParamGenParameterSpec(int L,
                                int N)
                         throws InvalidParameterException
Constructor.
Parameters:
L - the bit length of the prime p
N - the bit length of the prime q
Throws:
InvalidParameterException - if L < 1 or N < 1.
Method Detail

getL

public int getL()
Returns:
the bit length of the prime p

getN

public int getN()
Returns:
the bit length of the prime q