Class PKCS11PrivateKeyFactoryBean

    • Field Detail

      • PROVIDER_CLASS_NAME

        private static final String PROVIDER_CLASS_NAME
        The class name for the PKCS#11 provider class.
        See Also:
        Constant Field Values
      • provider

        private static Provider provider
        Singleton Provider for all instances of this factory.
      • log

        private final org.slf4j.Logger log
        Class logger.
      • pkcs11Config

        private String pkcs11Config
        PKCS#11 provider parameter string.
      • keyAlias

        private String keyAlias
        Alias for the private key.
      • keyPassword

        private String keyPassword
        Password for the private key.
      • key

        private PrivateKey key
        The singleton instance of the private key produced by this factory.
    • Constructor Detail

      • PKCS11PrivateKeyFactoryBean

        public PKCS11PrivateKeyFactoryBean()
    • Method Detail

      • getPkcs11Config

        public String getPkcs11Config()
        Returns the PKCS#11 configuration.
        Returns:
        returns the PKCS#11 configuration.
      • setPkcs11Config

        public void setPkcs11Config​(@Nonnull
                                    String config)
        Sets the PKCS#11 configuration to use.
        Parameters:
        config - the PKCS#11 configuration to use
      • getKeyAlias

        public String getKeyAlias()
        Gets the key alias in use.
        Returns:
        returns the key alias in use
      • setKeyAlias

        public void setKeyAlias​(String alias)
        Sets the key alias to use.
        Parameters:
        alias - the key alias to use
      • getKeyPassword

        public String getKeyPassword()
        Gets the key password in use.
        Returns:
        returns the key password in use
      • setKeyPassword

        public void setKeyPassword​(@Nonnull
                                   String password)
        Set the key password to use.
        Parameters:
        password - the key password to use