Interface SecretEngine

  • All Known Implementing Classes:
    AbstractStorageSecretEngine, NoopSecretEngine

    public interface SecretEngine
    SecretEngines contain service specific functionality in order to decrypt EncryptedSecrets. Identifiers are used in order to identify which SecretEngine an EncryptedSecret refers to. SecretEngines are used by the SecretManager in order to decrypt a given secret.
    • Method Detail

      • identifier

        java.lang.String identifier()
      • validate

        void validate​(EncryptedSecret encryptedSecret)
        In order for a secretEngine to decrypt an EncryptedSecret, it may require extra information (e.g. decryptionKey, location, encryptionMethod, etc). This method takes an EncryptedSecret and validates it contains the required information the service needs for decryption. Parameter names should not contain ':'
        Parameters:
        encryptedSecret - The encrypted secret
        Throws:
        InvalidSecretFormatException - If the encrypted secret is malformed
      • encrypt

        default EncryptedSecret encrypt​(java.lang.String secretToEncrypt)
      • clearCache

        void clearCache()