|
XML Security, 1.6 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface KeyGenerationEngine
This interface defines methods for key generation. The methods are called by our XML Encryption processor as follows: On key generation from scratch (which is usually done on data or key encryption), init() is called first (if a set of algorithm parameters is specified), and then generateKey() is called. On key generation from an encoded key (which is usually done on key decryption), generateKey(byte[]) only is called.
Instances of this interface are obtained through an instance of the EngineFactory interface. See its documentation for more details.
EngineFactory.getKeyGenerationEngine(String, String),
EngineFactory.releaseKeyGenerationEngine(KeyGenerationEngine)| Method Summary | |
|---|---|
java.security.Key |
generateKey()
Generates a key. |
java.security.Key |
generateKey(byte[] encodedKey)
Generates a key from an encoded key. |
int |
getKeySize()
Returns the size of the key generated by this engine. |
java.lang.String |
getURI()
Returns the algorithm URI of this engine. |
void |
init(java.security.spec.AlgorithmParameterSpec spec)
Initializes this engine with a set of algorithm parameters. |
| Method Detail |
|---|
java.lang.String getURI()
void init(java.security.spec.AlgorithmParameterSpec spec)
throws java.security.InvalidAlgorithmParameterException
spec - algorithm parameters. It may be null.
java.security.InvalidAlgorithmParameterExceptionjava.security.Key generateKey()
java.security.Key generateKey(byte[] encodedKey)
throws java.security.InvalidKeyException
encodedKey - key to be decoded.
java.security.InvalidKeyExceptionint getKeySize()
|
XML Security, 1.6 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||