public class EncryptionConfig
extends java.lang.Object
AtmosEncryptionClient.
Both keystore keys and bare RSA KeyPairs are supported.| Constructor and Description |
|---|
EncryptionConfig(java.security.KeyPair masterEncryptionKey,
java.util.Set<java.security.KeyPair> decryptionKeys,
java.security.Provider provider,
int keySize)
Creates a new EncryptionConfig object that uses bare KeyPair objects.
|
EncryptionConfig(java.security.KeyStore keystore,
char[] masterKeyPassword,
java.lang.String masterKeyAlias,
java.security.Provider provider,
int keySize)
Creates a new EncryptionConfig object that will retrieve keys from a Keystore
object.
|
| Modifier and Type | Method and Description |
|---|---|
com.emc.vipr.transform.encryption.EncryptionTransformFactory<com.emc.vipr.transform.encryption.BasicEncryptionOutputTransform,com.emc.vipr.transform.encryption.BasicEncryptionInputTransform> |
getFactory()
Returns the configured EncryptionTransformFactory.
|
public EncryptionConfig(java.security.KeyStore keystore,
char[] masterKeyPassword,
java.lang.String masterKeyAlias,
java.security.Provider provider,
int keySize)
throws java.security.InvalidKeyException,
java.security.NoSuchAlgorithmException,
javax.crypto.NoSuchPaddingException,
com.emc.vipr.transform.TransformException
keystore - the Keystore containing the master encryption key and any
additional decryption key(s).masterKeyPassword - password for the master keys. Note that this
implementation assumes that all master keys use the same password.masterKeyAlias - name of the master encryption key in the Keystore object.provider - (optional) if not-null, the Provider object to use for all
encryption operations. If null, the default provider(s) will be used from your
java.security file.keySize - size of encryption key to use, either 128 or 256. Note that to use
256-bit AES keys, you will probably need the unlimited strength jurisdiction files
installed in your JRE.java.security.InvalidKeyException - if the master encryption key cannot be loaded.java.security.NoSuchAlgorithmException - if the AES encryption algorithm is not available.javax.crypto.NoSuchPaddingException - if PKCS5Padding is not available.com.emc.vipr.transform.TransformException - if some other error occurred initializing the encryption.public EncryptionConfig(java.security.KeyPair masterEncryptionKey,
java.util.Set<java.security.KeyPair> decryptionKeys,
java.security.Provider provider,
int keySize)
throws java.security.InvalidKeyException,
java.security.NoSuchAlgorithmException,
javax.crypto.NoSuchPaddingException,
com.emc.vipr.transform.TransformException
masterEncryptionKey - the KeyPair to use for encryption.decryptionKeys - (optional) additional KeyPair objects available to
decrypt objects.provider - (optional) if not-null, the Provider object to use for all
encryption operations. If null, the default provider(s) will be used from your
java.security file.keySize - size of encryption key to use, either 128 or 256. Note that to use
256-bit AES keys, you will probably need the unlimited strength jurisdiction files
installed in your JRE.java.security.InvalidKeyException - if the master encryption key is not validjava.security.NoSuchAlgorithmException - if the AES encryption algorithm is not available.javax.crypto.NoSuchPaddingException - if PKCS5Padding is not available.com.emc.vipr.transform.TransformException - if some other error occurred initializing the encryption.public com.emc.vipr.transform.encryption.EncryptionTransformFactory<com.emc.vipr.transform.encryption.BasicEncryptionOutputTransform,com.emc.vipr.transform.encryption.BasicEncryptionInputTransform> getFactory()