Registry / crypto / bcmail-jdk15on

bcmail-jdk15on

JSON →
library1.70javamavenunverified

Provides S/MIME APIs for handling secure email protocols, compatible with JDK 1.5 and above.

<dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcmail-jdk15on</artifactId> <version>1.70</version> </dependency>
INSTALL
IMPORT
SIG · BCMAIL-JDK15ON
B
bcmail-jdk15on
cryptojavav1.70
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SMIMEEnvelopedGenerator
org.bouncycastle.mail.smime.SMIMEEnvelopedGenerator

Encrypt an email body part using S/MIME.

import org.bouncycastle.mail.smime.SMIMEEnvelopedGenerator; import javax.mail.internet.MimeBodyPart; import java.security.cert.X509Certificate; SMIMEEnvelopedGenerator gen = new SMIMEEnvelopedGenerator(); gen.addRecipientInfoGenerator(new JceKeyTransRecipientInfoGenerator((X509Certificate) cert).setProvider("BC")); MimeBodyPart encrypted = gen.generate(bodyPart, SMIMEEnvelopedGenerator.AES256_CBC, "BC");
Debug
Known issues
gotchaRequires JavaMail API and Java Activation Framework (JAF) as dependencies.
fix
Add javax.mail:javax.mail-api and javax.activation:activation to your project.
affects: *
Upgrade
Version history
1.70latest on Maven
Audit
Dependencies

No dependency data recorded yet.

Agent activity
21 hits · last 30 days
node
18
Resources
bcmail-jdk15on — mvn dependency:get bcmail-jdk15on · libregistry