Class SecretKeyResolver


  • public class SecretKeyResolver
    extends KeyResolverSpi
    Resolves a SecretKey within a KeyStore based on the KeyName. The KeyName is the key entry alias within the KeyStore.
    • Field Detail

      • LOG

        private static final org.slf4j.Logger LOG
      • keyStore

        private java.security.KeyStore keyStore
      • password

        private char[] password
    • Constructor Detail

      • SecretKeyResolver

        public SecretKeyResolver​(java.security.KeyStore keyStore,
                                 char[] password)
        Constructor.
    • Method Detail

      • engineCanResolve

        public boolean engineCanResolve​(org.w3c.dom.Element element,
                                        java.lang.String baseURI,
                                        StorageResolver storage)
        This method returns whether the KeyResolverSpi is able to perform the requested action.
        Overrides:
        engineCanResolve in class KeyResolverSpi
        Parameters:
        element -
        baseURI -
        storage -
        Returns:
        whether the KeyResolverSpi is able to perform the requested action.
      • engineLookupResolveX509Certificate

        public java.security.cert.X509Certificate engineLookupResolveX509Certificate​(org.w3c.dom.Element element,
                                                                                     java.lang.String baseURI,
                                                                                     StorageResolver storage)
                                                                              throws KeyResolverException
        Method engineResolveX509Certificate Method engineLookupResolveX509Certificate
        Overrides:
        engineLookupResolveX509Certificate in class KeyResolverSpi
        Parameters:
        element -
        baseURI -
        storage -
        Returns:
        resolved X509Certificate key from the registered from the elements
        Throws:
        KeyResolverException