public abstract class PublicKeyKeyEncryptionMethodGenerator extends PGPKeyEncryptionMethodGenerator
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
SESSION_KEY_OBFUSCATION_PROPERTY |
protected boolean |
sessionKeyObfuscation |
protected boolean |
useWildcardKeyID |
static long |
WILDCARD |
Modifier | Constructor and Description |
---|---|
protected |
PublicKeyKeyEncryptionMethodGenerator(PGPPublicKey pubKey) |
Modifier and Type | Method and Description |
---|---|
protected abstract byte[] |
encryptSessionInfo(PGPPublicKey pubKey,
byte[] sessionInfo) |
ContainedPacket |
generate(int encAlgorithm,
byte[] sessionInfo) |
ContainedPacket |
generateV5(int encAlgorithm,
int aeadAlgorithm,
byte[] sessionInfo) |
ContainedPacket |
generateV6(int encAlgorithm,
int aeadAlgorithm,
byte[] sessionInfo) |
byte[][] |
processSessionInfo(byte[] encryptedSessionInfo) |
PublicKeyKeyEncryptionMethodGenerator |
setSessionKeyObfuscation(boolean enabled)
Controls whether to obfuscate the size of ECDH session keys using extra padding where necessary.
|
PublicKeyKeyEncryptionMethodGenerator |
setUseWildcardKeyID(boolean enabled)
Controls whether the recipient key ID is hidden (replaced by a wildcard ID
|
public static final java.lang.String SESSION_KEY_OBFUSCATION_PROPERTY
public static final long WILDCARD
protected boolean sessionKeyObfuscation
protected boolean useWildcardKeyID
protected PublicKeyKeyEncryptionMethodGenerator(PGPPublicKey pubKey)
public PublicKeyKeyEncryptionMethodGenerator setSessionKeyObfuscation(boolean enabled)
The default behaviour can be configured using the system property "", or else it will default to enabled.
public PublicKeyKeyEncryptionMethodGenerator setUseWildcardKeyID(boolean enabled)
0).
enabled
- booleanpublic byte[][] processSessionInfo(byte[] encryptedSessionInfo) throws PGPException
PGPException
public ContainedPacket generate(int encAlgorithm, byte[] sessionInfo) throws PGPException
generate
in class PGPKeyEncryptionMethodGenerator
PGPException
public ContainedPacket generateV5(int encAlgorithm, int aeadAlgorithm, byte[] sessionInfo) throws PGPException
generateV5
in class PGPKeyEncryptionMethodGenerator
PGPException
public ContainedPacket generateV6(int encAlgorithm, int aeadAlgorithm, byte[] sessionInfo) throws PGPException
generateV6
in class PGPKeyEncryptionMethodGenerator
PGPException
protected abstract byte[] encryptSessionInfo(PGPPublicKey pubKey, byte[] sessionInfo) throws PGPException
PGPException