FileDocCategorySizeDatePackage
Pfx.javaAPI DocAzureus 3.0.3.41590Tue Jun 08 05:12:58 BST 2004org.bouncycastle.asn1.pkcs

Pfx

public class Pfx extends Object implements org.bouncycastle.asn1.DEREncodable, PKCSObjectIdentifiers
the infamous Pfx from PKCS12

Fields Summary
private ContentInfo
contentInfo
private MacData
macData
Constructors Summary
public Pfx(org.bouncycastle.asn1.ASN1Sequence seq)


     
           
    
        BigInteger  version = ((DERInteger)seq.getObjectAt(0)).getValue();
        if (version.intValue() != 3)
        {
            throw new IllegalArgumentException("wrong version for PFX PDU");
        }

        contentInfo = ContentInfo.getInstance(seq.getObjectAt(1));

        if (seq.size() == 3)
        {
            macData = MacData.getInstance(seq.getObjectAt(2));
        }
    
public Pfx(ContentInfo contentInfo, MacData macData)

        this.contentInfo = contentInfo;
        this.macData = macData;
    
Methods Summary
public ContentInfogetAuthSafe()

        return contentInfo;
    
public org.bouncycastle.asn1.DERObjectgetDERObject()

        ASN1EncodableVector v = new ASN1EncodableVector();

        v.add(new DERInteger(3));
        v.add(contentInfo);

        if (macData != null)
        {
            v.add(macData);
        }

        return new BERSequence(v);
    
public MacDatagetMacData()

        return macData;