public class JcaEncryptedValueBuilder extends EncryptedValueBuilder
Constructor and Description |
---|
JcaEncryptedValueBuilder(KeyWrapper wrapper,
OutputEncryptor encryptor) |
Modifier and Type | Method and Description |
---|---|
org.bouncycastle.asn1.crmf.EncryptedValue |
build(java.security.PrivateKey privateKey)
Build an EncryptedValue structure containing the private key details contained in
the passed PrivateKey.
|
org.bouncycastle.asn1.crmf.EncryptedValue |
build(java.security.cert.X509Certificate certificate)
Build an EncryptedValue structure containing the passed in certificate.
|
build, build, build
public JcaEncryptedValueBuilder(KeyWrapper wrapper, OutputEncryptor encryptor)
public org.bouncycastle.asn1.crmf.EncryptedValue build(java.security.cert.X509Certificate certificate) throws java.security.cert.CertificateEncodingException, CRMFException
certificate
- the certificate to be encrypted.CRMFException
- on a failure to encrypt the data, or wrap the symmetric key for this value.java.security.cert.CertificateEncodingException
public org.bouncycastle.asn1.crmf.EncryptedValue build(java.security.PrivateKey privateKey) throws java.security.cert.CertificateEncodingException, CRMFException
privateKey
- the asymmetric private key.CRMFException
- on a failure to encrypt the data, or wrap the symmetric key for this value.java.security.cert.CertificateEncodingException