Class KeystoreManager

java.lang.Object
com.sun.enterprise.admin.servermgmt.KeystoreManager
Direct Known Subclasses:
MasterPasswordFileManager, NodeKeystoreManager

public class KeystoreManager extends Object
Author:
kebbs
  • Field Details

  • Constructor Details

    • KeystoreManager

      public KeystoreManager()
  • Method Details

    • getCertificateDN

      protected static String getCertificateDN(RepositoryConfig cfg, String CNSuffix)
    • getFileLayout

      protected PEFileLayout getFileLayout(RepositoryConfig config)
    • createKeyStore

      protected void createKeyStore(File keyStore, RepositoryConfig config, String masterPassword) throws DomainException
      Create the default SSL key store using keytool to generate a self signed certificate.
      Parameters:
      keyStore -
      config -
      masterPassword -
      Throws:
      DomainException
    • copyCertificatesToTrustStore

      protected final void copyCertificatesToTrustStore(File configRoot, String masterPassword) throws DomainException
      Throws:
      DomainException
    • changeKeystorePassword

      protected void changeKeystorePassword(String oldPassword, String newPassword, File keyStore) throws DomainException
      Changes the keystore password
      Parameters:
      oldPassword - the old keystore password
      newPassword - the new keystore password
      keyStore - the keystore whose password is to be changed.
      Throws:
      DomainException
    • changeSSLCertificateDatabasePassword

      protected void changeSSLCertificateDatabasePassword(RepositoryConfig config, String oldPassword, String newPassword) throws DomainException
      Changes the password of the keystore, truststore and the key password of the s1as alias. It is expected that the key / truststores may not exist. This is due to the fact that the user may have deleted them and wishes to set up their own key/truststore
      Parameters:
      config -
      oldPassword -
      newPassword -
      Throws:
      DomainException
    • chmod

      protected void chmod(String args, File file) throws IOException
      Throws:
      IOException
    • getDASCertDN

      public static String getDASCertDN(RepositoryConfig cfg)
    • getInstanceCertDN

      public static String getInstanceCertDN(RepositoryConfig cfg)