de.flexiprovider.core.rprimersa
Class RprimeRSAKeyGenParameterSpec

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

public final class RprimeRSAKeyGenParameterSpec
extends java.lang.Object
implements AlgorithmParameterSpec

This class specifies parameters used by the RprimeRSAKeyPairGenerator.

Author:
Paul Nguentcheu, Martin Döring

Field Summary
static int DEFAULT_KEY_SIZE
          The default bit length of the modulus n (1024 bits)
static int DEFAULT_NUM_PRIMES
          The default number of primes
static int DEFAULT_PRIVATE_EXPONENT_SIZE
          The default bit length of the private exponent d modulo all primes
 
Constructor Summary
RprimeRSAKeyGenParameterSpec()
          Construct the default rebalanced multi-prime RSA key generation parameters.
RprimeRSAKeyGenParameterSpec(int keySize)
          Construct new rebalanced multi-prime RSA key generation parameters from the given key size.
RprimeRSAKeyGenParameterSpec(int keySize, int k)
          Construct new rebalanced multi-prime RSA key generation parameters from the given key size and number of primes.
RprimeRSAKeyGenParameterSpec(int keySize, int k, int s)
          Construct new rebalanced multi-prime RSA key generation parameters from the given key size, number of primes, and bit length of the private exponent d modulo all primes.
 
Method Summary
 int getKeySize()
           
 int getNumPrimes()
           
 int getPrivExpSize()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_KEY_SIZE

public static final int DEFAULT_KEY_SIZE
The default bit length of the modulus n (1024 bits)

DEFAULT_NUM_PRIMES

public static final int DEFAULT_NUM_PRIMES
The default number of primes

DEFAULT_PRIVATE_EXPONENT_SIZE

public static final int DEFAULT_PRIVATE_EXPONENT_SIZE
The default bit length of the private exponent d modulo all primes
Constructor Detail

RprimeRSAKeyGenParameterSpec

public RprimeRSAKeyGenParameterSpec()
Construct the default rebalanced multi-prime RSA key generation parameters. The key size is chosen as DEFAULT_KEY_SIZE. The number of primes is chosen as DEFAULT_NUM_PRIMES. The bit length of the private exponent d modulo all primes is chosen as DEFAULT_PRIVATE_EXPONENT_SIZE.

RprimeRSAKeyGenParameterSpec

public RprimeRSAKeyGenParameterSpec(int keySize)
Construct new rebalanced multi-prime RSA key generation parameters from the given key size. The number of primes is chosen as DEFAULT_NUM_PRIMES. The bit length of the private exponent d modulo all primes is chosen as DEFAULT_PRIVATE_EXPONENT_SIZE. If the key size is invalid, choose the DEFAULT_KEY_SIZE.
Parameters:
keySize - the bit length of the modulus n (>= 512)

RprimeRSAKeyGenParameterSpec

public RprimeRSAKeyGenParameterSpec(int keySize,
                                    int k)
Construct new rebalanced multi-prime RSA key generation parameters from the given key size and number of primes. The bit length of the private exponent d modulo all primes is chosen as DEFAULT_PRIVATE_EXPONENT_SIZE. If the key size is invalid, choose the DEFAULT_KEY_SIZE. If the number of primes is invalid, choose the DEFAULT_NUM_PRIMES.
Parameters:
keySize - the bit length of the modulus n (>= 512)
k - the number of primes (>= 2)

RprimeRSAKeyGenParameterSpec

public RprimeRSAKeyGenParameterSpec(int keySize,
                                    int k,
                                    int s)
Construct new rebalanced multi-prime RSA key generation parameters from the given key size, number of primes, and bit length of the private exponent d modulo all primes. If the key size is invalid, choose the DEFAULT_KEY_SIZE. If the number of primes is invalid, choose the DEFAULT_NUM_PRIMES. If the bit length of the private exponent is invalid, choose the DEFAULT_PRIVATE_EXPONENT_SIZE.
Parameters:
keySize - the bit length of the modulus n (>= 512)
k - the number of primes (>= 2)
s - the bit length of the private exponent d modulo all primes (>= 2)
Method Detail

getKeySize

public int getKeySize()
Returns:
the bit length of the modulus n

getNumPrimes

public int getNumPrimes()
Returns:
the number of primes

getPrivExpSize

public int getPrivExpSize()
Returns:
the bit length of the private exponent d modulo all primes