Class PasswordRecipientInfoGenerator
java.lang.Object
org.bouncycastle.cms.PasswordRecipientInfoGenerator
- All Implemented Interfaces:
RecipientInfoGenerator
- Direct Known Subclasses:
BcPasswordRecipientInfoGenerator, JcePasswordRecipientInfoGenerator
public abstract class PasswordRecipientInfoGenerator
extends Object
implements RecipientInfoGenerator
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedPasswordRecipientInfoGenerator(org.bouncycastle.asn1.ASN1ObjectIdentifier kekAlgorithm, char[] password) protectedPasswordRecipientInfoGenerator(org.bouncycastle.asn1.ASN1ObjectIdentifier kekAlgorithm, char[] password, int keySize, int blockSize) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract byte[]calculateDerivedKey(int schemeID, org.bouncycastle.asn1.x509.AlgorithmIdentifier derivationAlgorithm, int keySize) org.bouncycastle.asn1.cms.RecipientInfogenerate(GenericKey contentEncryptionKey) protected abstract byte[]generateEncryptedBytes(org.bouncycastle.asn1.x509.AlgorithmIdentifier algorithm, byte[] derivedKey, GenericKey contentEncryptionKey) setPasswordConversionScheme(int schemeID) setSaltAndIterationCount(byte[] salt, int iterationCount) setSecureRandom(SecureRandom random)
-
Field Details
-
password
protected char[] password
-
-
Constructor Details
-
PasswordRecipientInfoGenerator
protected PasswordRecipientInfoGenerator(org.bouncycastle.asn1.ASN1ObjectIdentifier kekAlgorithm, char[] password) -
PasswordRecipientInfoGenerator
protected PasswordRecipientInfoGenerator(org.bouncycastle.asn1.ASN1ObjectIdentifier kekAlgorithm, char[] password, int keySize, int blockSize)
-
-
Method Details
-
setPasswordConversionScheme
-
setPRF
-
setSaltAndIterationCount
-
setSecureRandom
-
generate
public org.bouncycastle.asn1.cms.RecipientInfo generate(GenericKey contentEncryptionKey) throws CMSException - Specified by:
generatein interfaceRecipientInfoGenerator- Throws:
CMSException
-
calculateDerivedKey
protected abstract byte[] calculateDerivedKey(int schemeID, org.bouncycastle.asn1.x509.AlgorithmIdentifier derivationAlgorithm, int keySize) throws CMSException - Throws:
CMSException
-
generateEncryptedBytes
protected abstract byte[] generateEncryptedBytes(org.bouncycastle.asn1.x509.AlgorithmIdentifier algorithm, byte[] derivedKey, GenericKey contentEncryptionKey) throws CMSException - Throws:
CMSException
-