Bouncy Castle Cryptography Library 1.79

org.bouncycastle.openpgp.operator
Class PGPKeyEncryptionMethodGenerator

java.lang.Object
  |
  +--org.bouncycastle.openpgp.operator.PGPKeyEncryptionMethodGenerator
Direct Known Subclasses:
PBEKeyEncryptionMethodGenerator, PublicKeyKeyEncryptionMethodGenerator

public abstract class PGPKeyEncryptionMethodGenerator
extends java.lang.Object

An encryption method that can be applied to encrypt data in a PGPEncryptedDataGenerator.


Constructor Summary
PGPKeyEncryptionMethodGenerator()
           
 
Method Summary
abstract  ContainedPacket generate(int encAlgorithm, byte[] sessionInfo)
          Generates a packet encoding the details of this encryption method.
abstract  ContainedPacket generateV5(int encAlgorithm, int aeadAlgorithm, byte[] sessionInfo)
           
abstract  ContainedPacket generateV6(int encAlgorithm, int aeadAlgorithm, byte[] sessionInfo)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PGPKeyEncryptionMethodGenerator

public PGPKeyEncryptionMethodGenerator()
Method Detail

generate

public abstract ContainedPacket generate(int encAlgorithm,
                                         byte[] sessionInfo)
                                  throws PGPException
Generates a packet encoding the details of this encryption method.
Parameters:
encAlgorithm - the encryption algorithm being used
sessionInfo - session data generated by the encrypted data generator.
Returns:
a packet encoding the provided information and the configuration of this instance.
Throws:
PGPException - if an error occurs constructing the packet.

generateV5

public abstract ContainedPacket generateV5(int encAlgorithm,
                                           int aeadAlgorithm,
                                           byte[] sessionInfo)
                                    throws PGPException

generateV6

public abstract ContainedPacket generateV6(int encAlgorithm,
                                           int aeadAlgorithm,
                                           byte[] sessionInfo)
                                    throws PGPException

Bouncy Castle Cryptography Library 1.79