Package org.fuin.ddd4j.ddd
Interface EncryptedData.Decrypter
-
- Enclosing class:
- EncryptedData
public static interface EncryptedData.DecrypterDecrypts some data.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @javax.validation.constraints.NotEmpty byte[]decrypt(@NotNull EncryptedData encryptedData)Decrypts the data using the information provided by the parameter.
-
-
-
Method Detail
-
decrypt
@NotEmpty @javax.validation.constraints.NotEmpty byte[] decrypt(@NotNull @NotNull EncryptedData encryptedData) throws EncryptionKeyIdUnknownException, EncryptionKeyVersionUnknownException, EncryptionIvVersionUnknownException, DecryptionFailedExceptionDecrypts the data using the information provided by the parameter. The data itself will only be decrypted, means no transformation in regard to mime and data type will take place. It's up to the caller to use this information to transform the returned byte array to the target type.- Parameters:
encryptedData- Encrypted data and meta information about it.- Returns:
- Decrypted data.
- Throws:
EncryptionKeyIdUnknownException- The given key identifier is unknown.EncryptionKeyVersionUnknownException- The given version of the key is unknown.EncryptionIvVersionUnknownException- The given initialization vector version is unknown.DecryptionFailedException- Decrypting the data using they key, version and (optional) IV version failed.
-
-