public abstract class CipherHandler extends Object
Modifier and Type | Class and Description |
---|---|
static class |
CipherHandler.WithEncryptionHeader<T> |
Modifier and Type | Field and Description |
---|---|
protected Cipher |
cipher |
protected MasterKeyProvider |
provider |
Constructor and Description |
---|
CipherHandler(MasterKeyProvider provider) |
Modifier and Type | Method and Description |
---|---|
protected DataKey |
generateDataKey() |
protected byte[] |
generateIV() |
protected SecretKeySpec |
getSecretKeySpec(EncryptionHeader encryptionHeader,
KmsMasterKey decryptionKmsMasterKey) |
Cipher |
initCipher(int mode,
SecretKeySpec dataKeySpec,
EncryptionHeader encryptionHeader) |
protected final Cipher cipher
protected final MasterKeyProvider provider
public CipherHandler(MasterKeyProvider provider)
protected byte[] generateIV()
protected DataKey generateDataKey()
protected SecretKeySpec getSecretKeySpec(EncryptionHeader encryptionHeader, KmsMasterKey decryptionKmsMasterKey)
public Cipher initCipher(int mode, SecretKeySpec dataKeySpec, EncryptionHeader encryptionHeader)
Copyright © 2016–2024. All rights reserved.