Package ddf.security.encryption
Interface EncryptionService
- All Superinterfaces:
org.apache.wss4j.common.crypto.PasswordEncryptor
public interface EncryptionService
extends org.apache.wss4j.common.crypto.PasswordEncryptor
-
Method Summary
Modifier and TypeMethodDescriptiondecryptValue(String wrappedEncryptedValue) Decrypts a wrapped encrypted value in the "ENC(*)" format.encryptValue(String unwrappedPlaintext) Encrypts a plaintext string and wraps the encrypted string in a leading "ENC(" and trailing ")".unwrapEncryptedValue(String wrappedEncryptedValue) Unwraps an encrypted value in the "ENC(*)" format.Methods inherited from interface org.apache.wss4j.common.crypto.PasswordEncryptor
decrypt, encrypt
-
Method Details
-
decryptValue
Decrypts a wrapped encrypted value in the "ENC(*)" format. Inputs that are not wrapped are returned as a no-op.- Parameters:
wrappedEncryptedValue- a string of the form "ENC(", followed by an encrypted value, and terminated with ")".- Returns:
- a decryption of the given value after removing the leading "ENC(" and trailing ")".
-
encryptValue
Encrypts a plaintext string and wraps the encrypted string in a leading "ENC(" and trailing ")".- Parameters:
unwrappedPlaintext- a plaintext string to be encrypted.- Returns:
- encrypted text wrapped in a leading "ENC(" and trailing ")".
-
unwrapEncryptedValue
Unwraps an encrypted value in the "ENC(*)" format. Inputs that are not wrapped are returned as a no-op.- Parameters:
wrappedEncryptedValue- a string of the form "ENC(", followed by an encrypted value, and terminated with ")".- Returns:
- the encrypted value without the leading "ENC(" and trailing ")".
-