public class KeyStoreKeyManager extends Object implements TrustKeyManager
| Modifier and Type | Field and Description |
|---|---|
static String |
KEYSTORE_PASS |
static String |
KEYSTORE_URL |
static String |
SIGNING_KEY_ALIAS |
static String |
SIGNING_KEY_PASS |
| Constructor and Description |
|---|
KeyStoreKeyManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
addAdditionalOption(String key,
Object value)
Add general options
|
Object |
getAdditionalOption(String key)
Get additional option
|
Certificate |
getCertificate(String alias)
Get the certificate given an alias
|
SecretKey |
getEncryptionKey(String domain,
String encryptionAlgorithm,
int keyLength)
Given a domain, obtain a secret key
|
PublicKey |
getPublicKey(String alias)
Get a Public Key given an alias
|
PrivateKey |
getSigningKey()
Get the Signing Key
|
KeyPair |
getSigningKeyPair()
Constructs a
KeyPair instance containing the signing key (PrivateKey) and associated PublicKey. |
PublicKey |
getValidatingKey(String domain)
Get the validating public key Note:: The domain is mapped to an alias in the keystore
|
void |
setAuthProperties(List<org.picketlink.config.federation.AuthPropertyType> authList)
Provide a set of properties used for authentication into the storage of keys - keystore, ldap, db, HSM etc
|
void |
setValidatingAlias(List<org.picketlink.config.federation.KeyValueType> aliases)
Set a list of (domain,alias) tuple to trust domains The alias is a string that represents the validating key stored for a
domain
|
public static final String KEYSTORE_URL
public static final String KEYSTORE_PASS
public static final String SIGNING_KEY_PASS
public static final String SIGNING_KEY_ALIAS
public PrivateKey getSigningKey() throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagergetSigningKey in interface TrustKeyManagerorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.getSigningKey()public KeyPair getSigningKeyPair() throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManager
Constructs a KeyPair instance containing the signing key (PrivateKey) and associated PublicKey.
getSigningKeyPair in interface TrustKeyManagerKeyPair object.org.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionpublic Certificate getCertificate(String alias) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagergetCertificate in interface TrustKeyManagerorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.getCertificate(String)public PublicKey getPublicKey(String alias) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagergetPublicKey in interface TrustKeyManagerorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.getPublicKey(String)public PublicKey getValidatingKey(String domain) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
getValidatingKey in interface TrustKeyManagerIOExceptionorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.getValidatingKey(String),
TrustKeyManager.getPublicKey(String)public void setAuthProperties(List<org.picketlink.config.federation.AuthPropertyType> authList) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagersetAuthProperties in interface TrustKeyManagerorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.setAuthProperties(List)public void setValidatingAlias(List<org.picketlink.config.federation.KeyValueType> aliases) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagersetValidatingAlias in interface TrustKeyManagerorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager.setValidatingAlias(List)public SecretKey getEncryptionKey(String domain, String encryptionAlgorithm, int keyLength) throws org.picketlink.common.exceptions.TrustKeyConfigurationException, org.picketlink.common.exceptions.TrustKeyProcessingException
TrustKeyManagergetEncryptionKey in interface TrustKeyManagerencryptionAlgorithm - Encryption AlgorithmkeyLength - length of keysGeneralSecurityExceptionorg.picketlink.common.exceptions.TrustKeyConfigurationExceptionorg.picketlink.common.exceptions.TrustKeyProcessingExceptionTrustKeyManager#getEncryptionKey(String)public void addAdditionalOption(String key, Object value)
TrustKeyManageraddAdditionalOption in interface TrustKeyManagerTrustKeyManager.addAdditionalOption(java.lang.String,
java.lang.Object)public Object getAdditionalOption(String key)
TrustKeyManagergetAdditionalOption in interface TrustKeyManagerTrustKeyManager.getAdditionalOption(java.lang.String)Copyright © 2013 JBoss Inc.. All Rights Reserved.