org.bouncycastle.cms.bc
Class BcCMSContentEncryptorBuilder
java.lang.Object
org.bouncycastle.cms.bc.BcCMSContentEncryptorBuilder
- public class BcCMSContentEncryptorBuilder
- extends java.lang.Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BcCMSContentEncryptorBuilder
public BcCMSContentEncryptorBuilder(org.bouncycastle.asn1.ASN1ObjectIdentifier encryptionOID)
BcCMSContentEncryptorBuilder
public BcCMSContentEncryptorBuilder(org.bouncycastle.asn1.ASN1ObjectIdentifier encryptionOID,
int keySize)
setSecureRandom
public BcCMSContentEncryptorBuilder setSecureRandom(java.security.SecureRandom random)
build
public OutputEncryptor build()
throws CMSException
- Build the OutputEncryptor with an internally generated key.
- Returns:
- an OutputEncryptor configured to use an internal key.
- Throws:
CMSException
build
public OutputEncryptor build(byte[] rawEncKey)
throws CMSException
- Build the OutputEncryptor using a pre-generated key.
- Parameters:
rawEncKey - a raw byte encoding of the key to be used for encryption.
- Returns:
- an OutputEncryptor configured to use rawEncKey.
- Throws:
CMSException