public class CryptoManager extends Object
Constructor and Description |
---|
CryptoManager()
Creates an instance of Encryption configuration
|
Modifier and Type | Method and Description |
---|---|
CryptoProvider |
getProvider(String name)
Get an encryption algorithm provider
|
void |
registerProvider(String name,
CryptoProvider provider)
Add an encryption algorithm provider
|
void |
throwMissingPublicKeyEx(String alias)
Private interface to workaround eager loading of exception classes in JVM
throws the required public key missing exception
|
void |
throwSigningFailedEx(String alias)
Private interface to workaround eager loading of exception classes in JVM
throws the required Signing failed exception
|
public CryptoManager()
public void registerProvider(String name, CryptoProvider provider) throws Exception
name
- an alias name for the encryption providerprovider
- Encryption provider implementationException
- if the alias name is null or emptypublic CryptoProvider getProvider(String name) throws Exception
name
- an alias name for the encryption providerException
- if the alias is null or empty or not configuredpublic void throwMissingPublicKeyEx(String alias) throws Exception
alias
- the alias name for the providerException
- alwaysCopyright © 2015 Couchbase, Inc.