Class IdentityKeyStoreWrapper

java.lang.Object
org.apache.synapse.securevault.keystore.KeyStoreWrapper
org.apache.synapse.securevault.keystore.IdentityKeyStoreWrapper

public class IdentityKeyStoreWrapper extends KeyStoreWrapper
Represents the private keyStore entry To provide that abstraction , this class exposes both getter methods to public, private and secret keys
  • Constructor Details

    • IdentityKeyStoreWrapper

      public IdentityKeyStoreWrapper()
  • Method Details

    • init

      public void init(IdentityKeyStoreInformation information, String keyPassword)
    • getPrivateKey

      public PrivateKey getPrivateKey(String alias, String keyPassword)
      Returns the private or secret key based on given password and alias
      Parameters:
      alias - The alias of the certificate in the specified keyStore
      keyPassword - Password to access private key
      Returns:
      PrivateKey if there is a one , otherwise null
    • getPrivateKey

      public PrivateKey getPrivateKey()
      Returns the private key based on initialization data
      Returns:
      PrivateKey if there is a one , otherwise null
    • getPrivateKey

      public PrivateKey getPrivateKey(String alias)
      Returns the private key based on initialization data
      Overrides:
      getPrivateKey in class KeyStoreWrapper
      Parameters:
      alias - The alias
      Returns:
      PrivateKey if there is a one , otherwise null
    • getIdentityKeyStore

      public KeyStore getIdentityKeyStore()
      Abstraction for getting Private Entry KeyStore(Identity)
      Returns:
      KeyStore Instance