Class PemSslStoreHelper

java.lang.Object
org.springframework.cloud.bindings.boot.pem.PemSslStoreHelper

public class PemSslStoreHelper extends Object
helper for creating stores from PEM-encoded certificates and private keys.
  • Field Details

  • Constructor Details

    • PemSslStoreHelper

      public PemSslStoreHelper()
  • Method Details

    • createKeyStoreFile

      public static Path createKeyStoreFile(String name, String password, String certificate, String privateKey, String keyAlias)
      Utility method to create a KeyStore and save it in the tmp directory with give name.
      Parameters:
      name - the store file name
      password - the store password
      certificate - the certificate to add to the store
      privateKey - the private key to add to the store
      keyAlias - the alias
      Returns:
      the path which store file is saved
    • generatePassword

      public static String generatePassword()
      Generates a password to use for KeyStore and/or TrustStore
      Returns:
      the password