Package de.otto.kafka.messaging.e2ee
Class AesEncryptedPayload
java.lang.Object
de.otto.kafka.messaging.e2ee.AesEncryptedPayload
-
Constructor Summary
ConstructorsConstructorDescriptionAesEncryptedPayload(byte[] plainPayload) AesEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, int keyVersion) AesEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, int keyVersion, String encryptionKeyAttributeName) AesEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion) AesEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion, String encryptionKeyAttributeName) -
Method Summary
Modifier and TypeMethodDescriptionbyte[]byte[]booleanintstatic AesEncryptedPayloadofEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, EncryptionCipherSpec cipherSpec) static AesEncryptedPayloadofEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, EncryptionKeyProvider.KeyVersion keyVersion) static AesEncryptedPayloadofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion) static AesEncryptedPayloadofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion, String encryptionKeyAttributeName) static AesEncryptedPayloadofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, EncryptionCipherSpec cipherSpec) static AesEncryptedPayloadofUnencryptedPayload(byte[] plainPayload) toString()
-
Constructor Details
-
AesEncryptedPayload
public AesEncryptedPayload(byte[] plainPayload) -
AesEncryptedPayload
public AesEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, int keyVersion) -
AesEncryptedPayload
public AesEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, int keyVersion, String encryptionKeyAttributeName) -
AesEncryptedPayload
public AesEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion) -
AesEncryptedPayload
-
-
Method Details
-
ofUnencryptedPayload
-
ofEncryptedPayload
public static AesEncryptedPayload ofEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, EncryptionKeyProvider.KeyVersion keyVersion) -
ofEncryptedPayload
public static AesEncryptedPayload ofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion) -
ofEncryptedPayload
public static AesEncryptedPayload ofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, int keyVersion, String encryptionKeyAttributeName) -
ofEncryptedPayload
public static AesEncryptedPayload ofEncryptedPayload(byte[] encryptedPayload, byte[] initializationVector, EncryptionCipherSpec cipherSpec) -
ofEncryptedPayload
public static AesEncryptedPayload ofEncryptedPayload(byte[] encryptedPayload, String initializationVectorBase64, EncryptionCipherSpec cipherSpec) -
isEncrypted
public boolean isEncrypted() -
encryptedPayload
public byte[] encryptedPayload() -
initializationVector
public byte[] initializationVector() -
initializationVectorBase64
-
keyVersion
public int keyVersion() -
encryptionKeyAttributeName
- Returns:
- name of the encryption key property within the vault. When
null, then the default value must be used.
-
toString
-