public class PKCS12SafeBagFactory
extends java.lang.Object
PKCS12SafeBags carried in one ContentInfo of a
PFX's AuthenticatedSafe. Use the single-argument constructor for plain data content
infos and the two-argument constructor with an InputDecryptorProvider for
encryptedData content infos.| Constructor and Description |
|---|
PKCS12SafeBagFactory(org.bouncycastle.asn1.pkcs.ContentInfo info)
Construct a factory over a plain (unencrypted)
data ContentInfo. |
PKCS12SafeBagFactory(org.bouncycastle.asn1.pkcs.ContentInfo info,
InputDecryptorProvider inputDecryptorProvider)
Construct a factory over an
encryptedData ContentInfo, decrypting its contents
with the supplied provider. |
| Modifier and Type | Method and Description |
|---|---|
PKCS12SafeBag[] |
getSafeBags()
Return the
PKCS12SafeBags contained in the ContentInfo this factory was created over. |
public PKCS12SafeBagFactory(org.bouncycastle.asn1.pkcs.ContentInfo info)
data ContentInfo.info - the ContentInfo holding the SafeContents.java.lang.IllegalArgumentException - if info is an encryptedData ContentInfo.public PKCS12SafeBagFactory(org.bouncycastle.asn1.pkcs.ContentInfo info,
InputDecryptorProvider inputDecryptorProvider)
throws PKCSException
encryptedData ContentInfo, decrypting its contents
with the supplied provider.info - the encrypted ContentInfo.inputDecryptorProvider - provider able to produce a decryptor matching the
algorithm identifier carried by info.PKCSException - if decryption fails.java.lang.IllegalArgumentException - if info is not an encryptedData ContentInfo.public PKCS12SafeBag[] getSafeBags()
PKCS12SafeBags contained in the ContentInfo this factory was created over.