This class represents a PKCS#7 RecipientInfo structure. It is defined as follows:
RecipientInfo ::= SEQUENCE { version Version, -- 0 for version 1.5 of PKCS#7 issuerAndSerialNumber IssuerAndSerialNumber, keyEncryptionAlgorithm KeyEncryptionAlgorithmIdentifier, encryptedKey EncryptedKey } EncryptedKey ::= OCTET STRING KeyEncryptionAlgorithmIdentifier ::= AlgorithmIdentifier
For completeness, we also present the structures referenced in the RecipientInfo structure.
IssuerAndSerialNumber ::= SEQUENCE { issuer Name, serialNumber CertificateSerialNumber } CertificateSerialNumber ::= INTEGER
This class provides methods to create a RecipientInfo structure from a certificate and a BEK. BEK stands for
Bulk Encryption Key. The BEK is in general a symmetric key that is used to encrypt bulk data. The BEK is then encrypted with the public key of the recipient of the bulk data. The public key is sometimes called the
Key Encryption Key (KEK).
The BEK can be retrieved easily from instances of this structure as long as the algorithm of the DEK is known. This information is not stored in this class but in the {@link EncryptedContentInfo EncryptedContentInfo} structure,which contains RecipientInfo structures for each intended recipient of the bulk data.
This class is completely JCE integrated. It determines the instances to use for encrypting and decrypting based on the OID contained in its instances. The OID are mapped to algorithm names and vice versa by the {@link JCA JCA}class, which requires appropriate aliases to be defined for algorithm implementations as described in the JCE documentation. If your installed providers do not support the aliasing scheme then request such support from your provider's supplier, or add a provider that properly defines the aliases (aliases are global to all providers).
@author Volker Roth
@version "$Id: RecipientInfo.java,v 1.6 2007/08/30 08:45:05 pebinger Exp $"