| RSA BSAFE CRYPTO-J |
Cryptographic Components for Java |
| JSAFE Javadoc | JCE Javadoc | Search |
JSAFE_KeyPair defines low-level key management and generation routines for a particular algorithm and can instantiate the classes that hold and generate public/private key pairs.
Define the higher-level key management in external classes (such as certification authorities).
See Overview of Crypto-J for background and reference material on using and understanding Crypto-J.
Copyright © RSA Security Inc., 1997-2005. All rights reserved.
Inheritance diagram for JSAFE_KeyPair:

Public Methods | |
| void JSAFE_KeyPair:: | setPrivateKeyAttributes (JSAFE_KeyAttributes attributes) |
| Sets the in-token attributes of the private key. More... | |
| void JSAFE_KeyPair:: | setPublicKeyAttributes (JSAFE_KeyAttributes attributes) |
| Sets the in-token attributes of the public key. More... | |
| String JSAFE_KeyPair:: | getDevice () |
| Returns the name of the device of record. More... | |
| String [] JSAFE_KeyPair:: | getDeviceList () |
Returns a String array that describes all the devices used to execute the transformation. More... | |
| abstract String JSAFE_KeyPair:: | getAlgorithm () |
| Returns the standard algorithm name. More... | |
| void JSAFE_KeyPair:: | setKeys (JSAFE_PublicKey pubKey, JSAFE_PrivateKey priKey) throws JSAFE_InvalidKeyException |
| Copies the public and private keys into this object. More... | |
| JSAFE_PublicKey JSAFE_KeyPair:: | getPublicKey () |
Returns a copy of the public key portion of a key pair as a JSAFE_PublicKey object. More... | |
| JSAFE_PrivateKey JSAFE_KeyPair:: | getPrivateKey () |
Returns a copy of the private key portion of a key pair as a JSAFE_PrivateKey object. More... | |
| Object JSAFE_KeyPair:: | clone () throws CloneNotSupportedException |
| Overrides the default clone to produce a deep clone. More... | |
| void JSAFE_KeyPair:: | generateInit (JSAFE_Parameters sharedParameters, int[] keyPairGenParameters, SecureRandom random) throws JSAFE_InvalidParameterException, JSAFE_InvalidUseException |
| Initializes this object to generate a key pair. More... | |
| void JSAFE_KeyPair:: | generateInit (JSAFE_Parameters sharedParameters, int[] keyPairGenParameters, SecureRandom random, JSAFE_Session[] sessions) throws JSAFE_InvalidParameterException, JSAFE_InvalidUseException |
| Initializes this object to generate a key pair. More... | |
| void JSAFE_KeyPair:: | generateStrongInit (JSAFE_Parameters sharedParameters, int[] keyPairGenParameters, SecureRandom random) throws JSAFE_InvalidParameterException, JSAFE_InvalidUseException |
| Initializes this object to generate a key pair, using techniques to guarantee the use of only strong primes. More... | |
| void JSAFE_KeyPair:: | generateReInit () throws JSAFE_InvalidUseException |
Re-initializes this object to generate a key pair, using the parameters and the random object passed in during a previous call to generateInit(). More... | |
| byte [][] JSAFE_KeyPair:: | generateKeyPair (byte[] xp1, byte[] xp2, byte[] Xp, byte[] xq1, byte[] xq2, byte[] Xq) throws JSAFE_InvalidUseException |
| Generates a strong key pair for testing according to the RSA Validation System. More... | |
| void JSAFE_KeyPair:: | generate () throws JSAFE_InvalidUseException |
| Generates the key pair. More... | |
| void JSAFE_KeyPair:: | clearSensitiveData () |
| This method clears sensitive data from an object. More... | |
Static Public Methods | |
| JSAFE_KeyPair JSAFE_KeyPair:: | getInstance (String transformation, String device) throws JSAFE_UnimplementedException, JSAFE_InvalidParameterException |
Builds a JSAFE_KeyPair object that holds and generates key pairs of type transformation on the given device. More... | |
|
|
This method clears sensitive data from an object. Although the finalizer clears the data, there is no guarantee the garbage collector will quickly call the finalizer. Allows a user to clear data as soon as possible. After calling Reimplemented from JSAFE_Object. |
|
|
Overrides the default clone to produce a deep clone.
Reimplemented from JSAFE_Object. |
|
|
Generates the key pair.
|
|
||||||||||||||||||||
|
Initializes this object to generate a key pair. If the algorithm needs system parameters, pass them in as
The
The
|
|
||||||||||||||||
|
Initializes this object to generate a key pair. If the algorithm needs system parameters, pass them in as
The following table summarizes the
|
|
||||||||||||||||||||||||||||
|
Generates a strong key pair for testing according to the RSA Validation System.
|
|
|
Re-initializes this object to generate a key pair, using the parameters and the random object passed in during a previous call to
|
|
||||||||||||||||
|
Initializes this object to generate a key pair, using techniques to guarantee the use of only strong primes. If the algorithm needs system parameters, pass them in as
If the algorithm does not support strong key-pair generation, this method will throw an exception. Currently, Crypto-J supports strong key-pair generation only with the RSA algorithm. After initializing with this method, generation will utilize prime-finding techniques that guarantee strong primes. The other key-pair generation code is faster, but it may produce weak primes. Note that the probability of producing weak primes is extremely low. The key pairs generated from this method conform to the X9.31 standard.
This method requires a hardware random number generator or a
|
|
|
Returns the standard algorithm name.
|
|
|
Returns the name of the device of record. Possible device values are:
|
|
|
Returns a
|
|
||||||||||||
|
Builds a
|
|
|
Returns a copy of the private key portion of a key pair as a
|
|
|
Returns a copy of the public key portion of a key pair as a
|
|
||||||||||||
|
Copies the public and private keys into this object. This method sets an object with
|
|
|
Sets the in-token attributes of the private key.
|
|
|
Sets the in-token attributes of the public key.
|