Top Fields Constructors Methods
org.bouncycastle.cms.jcajce

public Class JceKEMRecipientInfoGenerator

extends KEMRecipientInfoGenerator
Class Inheritance
Imports
java.security.Provider, .PublicKey, .SecureRandom, java.security.cert.CertificateEncodingException, .X509Certificate, org.bouncycastle.asn1.ASN1ObjectIdentifier, org.bouncycastle.asn1.cms.IssuerAndSerialNumber, org.bouncycastle.asn1.x509.AlgorithmIdentifier, org.bouncycastle.cert.jcajce.JcaX509CertificateHolder, org.bouncycastle.cms.KEMRecipientInfoGenerator

Field Summary

Inherited from org.bouncycastle.cms.KEMRecipientInfoGenerator:
wrapper

Constructor Summary

AccessConstructor and Description
public
public
JceKEMRecipientInfoGenerator(byte[] subjectKeyIdentifier, PublicKey publicKey, ASN1ObjectIdentifier symWrapAlgorithm)

Method Summary

Modifier and TypeMethod and Description
public JceKEMRecipientInfoGenerator

Returns:

the current RecipientInfoGenerator.
setAlgorithmMapping
(ASN1ObjectIdentifier
OID of algorithm in recipient.
algorithm
,
String
JCE algorithm name to use.
algorithmName
)

Internally algorithm ids are converted into cipher names using a lookup table.

public JceKEMRecipientInfoGenerator
public JceKEMRecipientInfoGenerator
setProvider(String providerName)

public JceKEMRecipientInfoGenerator
public JceKEMRecipientInfoGenerator
Inherited from org.bouncycastle.cms.KEMRecipientInfoGenerator:
generate

Constructor Detail

JceKEMRecipientInfoGeneratorback to summary
public JceKEMRecipientInfoGenerator(X509Certificate recipientCert, ASN1ObjectIdentifier symWrapAlgorithm) throws CertificateEncodingException
JceKEMRecipientInfoGeneratorback to summary
public JceKEMRecipientInfoGenerator(byte[] subjectKeyIdentifier, PublicKey publicKey, ASN1ObjectIdentifier symWrapAlgorithm)

Method Detail

setAlgorithmMappingback to summary
public JceKEMRecipientInfoGenerator setAlgorithmMapping(ASN1ObjectIdentifier algorithm, String algorithmName)

Internally algorithm ids are converted into cipher names using a lookup table. For some providers the standard lookup table won't work. Use this method to establish a specific mapping from an algorithm identifier to a specific algorithm.

For example:

    unwrapper.setAlgorithmMapping(PKCSObjectIdentifiers.rsaEncryption, "RSA");
Parameters
algorithm:ASN1ObjectIdentifier

OID of algorithm in recipient.

algorithmName:String

JCE algorithm name to use.

Returns:JceKEMRecipientInfoGenerator

the current RecipientInfoGenerator.

setKDFback to summary
public JceKEMRecipientInfoGenerator setKDF(AlgorithmIdentifier kdfAlgorithm)
setProviderback to summary
public JceKEMRecipientInfoGenerator setProvider(String providerName)
setProviderback to summary
public JceKEMRecipientInfoGenerator setProvider(Provider provider)
setSecureRandomback to summary
public JceKEMRecipientInfoGenerator setSecureRandom(SecureRandom random)