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 java.lang.System.Logger LOG
      • keyStore

        private final java.security.KeyStore keyStore
      • password

        private final char[] password
    • Constructor Detail

      • SecretKeyResolver

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

      • engineCanResolve

        protected 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.
        Specified by:
        engineCanResolve in class KeyResolverSpi
        Returns:
        whether the KeyResolverSpi is able to perform the requested action.
      • engineResolvePrivateKey

        protected java.security.PrivateKey engineResolvePrivateKey​(org.w3c.dom.Element element,
                                                                   java.lang.String baseURI,
                                                                   StorageResolver storage,
                                                                   boolean secureValidation)
        Method engineResolvePrivateKey
        Specified by:
        engineResolvePrivateKey in class KeyResolverSpi
        Returns:
        resolved PrivateKey key from the registered from the elements