Module org.apache.santuario.xmlsec
Class SecretKeyResolver
java.lang.Object
org.apache.xml.security.keys.keyresolver.KeyResolverSpi
org.apache.xml.security.keys.keyresolver.implementations.SecretKeyResolver
Resolves a SecretKey within a KeyStore based on the KeyName.
The KeyName is the key entry alias within the KeyStore.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final KeyStoreprivate static final System.Loggerprivate final char[] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanengineCanResolve(Element element, String baseURI, StorageResolver storage) This method returns whether the KeyResolverSpi is able to perform the requested action.protected PrivateKeyengineResolvePrivateKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) Method engineResolvePrivateKeyprotected PublicKeyengineResolvePublicKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) Method engineResolvePublicKeyprotected SecretKeyengineResolveSecretKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) Method engineResolveSecretKeyprotected X509CertificateengineResolveX509Certificate(Element element, String baseURI, StorageResolver storage, boolean secureValidation) Method engineResolveCertificateMethods inherited from class org.apache.xml.security.keys.keyresolver.KeyResolverSpi
engineLookupAndResolvePrivateKey, engineLookupAndResolvePublicKey, engineLookupAndResolveSecretKey, engineLookupResolveX509Certificate, getDocFromBytes
-
Field Details
-
LOG
-
keyStore
-
password
private final char[] password
-
-
Constructor Details
-
SecretKeyResolver
Constructor.
-
-
Method Details
-
engineCanResolve
This method returns whether the KeyResolverSpi is able to perform the requested action.- Specified by:
engineCanResolvein classKeyResolverSpi- Returns:
- whether the KeyResolverSpi is able to perform the requested action.
-
engineResolvePublicKey
protected PublicKey engineResolvePublicKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) throws KeyResolverException Method engineResolvePublicKey- Specified by:
engineResolvePublicKeyin classKeyResolverSpi- Returns:
- resolved public key from the registered from the element.
- Throws:
KeyResolverException
-
engineResolveX509Certificate
protected X509Certificate engineResolveX509Certificate(Element element, String baseURI, StorageResolver storage, boolean secureValidation) throws KeyResolverException Method engineResolveCertificate- Specified by:
engineResolveX509Certificatein classKeyResolverSpi- Returns:
- resolved X509Certificate key from the registered from the elements
- Throws:
KeyResolverException
-
engineResolveSecretKey
protected SecretKey engineResolveSecretKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) throws KeyResolverException Method engineResolveSecretKey- Specified by:
engineResolveSecretKeyin classKeyResolverSpi- Returns:
- resolved SecretKey key from the registered from the elements
- Throws:
KeyResolverException
-
engineResolvePrivateKey
protected PrivateKey engineResolvePrivateKey(Element element, String baseURI, StorageResolver storage, boolean secureValidation) Method engineResolvePrivateKey- Specified by:
engineResolvePrivateKeyin classKeyResolverSpi- Returns:
- resolved PrivateKey key from the registered from the elements
-