Top Description Methods
org.bouncycastle.openpgp.operator

public Interface PGPDataDecryptorFactory

Known Direct Subinterfaces
org.bouncycastle.openpgp.operator.PublicKeyDataDecryptorFactory, org.bouncycastle.openpgp.operator.SessionKeyDataDecryptorFactory
Known Direct Implementers
org.bouncycastle.openpgp.operator.PBEDataDecryptorFactory
Imports
org.bouncycastle.bcpg.AEADEncDataPacket, .SymmetricEncIntegrityPacket, .SymmetricKeyAlgorithmTags, org.bouncycastle.openpgp.PGPException, .PGPSessionKey

Base interface of factories for PGPDataDecryptor.

Method Summary

Modifier and TypeMethod and Description
public PGPDataDecryptor

Returns:

a data decryptor that can decrypt (and verify) streams of encrypted data.
createDataDecryptor
(boolean
true if the packet to be decrypted has integrity checking enabled.
withIntegrityPacket
,
int
the identifier of the encryption algorithm to decrypt with.
encAlgorithm
,
byte[]
the bytes of the key for the cipher.
key
)

Constructs a data decryptor for SED or v1 SEIPD packets.

public PGPDataDecryptor

Returns:

a data decryptor that can decrypt (and verify) streams of encrypted data.
createDataDecryptor
(AEADEncDataPacket
AEAD encrypted data packet
aeadEncDataPacket
,
PGPSessionKey
decrypted session key
sessionKey
)

Constructs a data decryptor for AEAD Encrypted Data packets.

public PGPDataDecryptor

Returns:

a data decryptor that can decrypt (and verify) streams of encrypted data.
createDataDecryptor
(SymmetricEncIntegrityPacket
version 2 symmetrically encrypted integrity-protected data packet using AEAD.
seipd
,
PGPSessionKey
decrypted session key
sessionKey
)

Constructs a data decryptor for v2 SEIPD packets.

Method Detail

createDataDecryptorback to summary
public PGPDataDecryptor createDataDecryptor(boolean withIntegrityPacket, int encAlgorithm, byte[] key) throws PGPException

Constructs a data decryptor for SED or v1 SEIPD packets.

Parameters
withIntegrityPacket:boolean

true if the packet to be decrypted has integrity checking enabled.

encAlgorithm:int

the identifier of the encryption algorithm to decrypt with.

key:byte[]

the bytes of the key for the cipher.

Returns:PGPDataDecryptor

a data decryptor that can decrypt (and verify) streams of encrypted data.

Exceptions
PGPException:
if an error occurs initialising the decryption and integrity checking functions.
createDataDecryptorback to summary
public PGPDataDecryptor createDataDecryptor(AEADEncDataPacket aeadEncDataPacket, PGPSessionKey sessionKey) throws PGPException

Constructs a data decryptor for AEAD Encrypted Data packets. This method is used with OpenPGP v5 AEAD.

Parameters
aeadEncDataPacket:AEADEncDataPacket

AEAD encrypted data packet

sessionKey:PGPSessionKey

decrypted session key

Returns:PGPDataDecryptor

a data decryptor that can decrypt (and verify) streams of encrypted data.

Exceptions
PGPException:
if an error occurs initialising the decryption and integrity checking functions.
createDataDecryptorback to summary
public PGPDataDecryptor createDataDecryptor(SymmetricEncIntegrityPacket seipd, PGPSessionKey sessionKey) throws PGPException

Constructs a data decryptor for v2 SEIPD packets. This method is used with OpenPGP v6 AEAD.

Parameters
seipd:SymmetricEncIntegrityPacket

version 2 symmetrically encrypted integrity-protected data packet using AEAD.

sessionKey:PGPSessionKey

decrypted session key

Returns:PGPDataDecryptor

a data decryptor that can decrypt (and verify) streams of encrypted data.

Exceptions
PGPException:
if an error occurs initialising the decryption and integrity checking functions.