Top Description Fields Constructors Methods
org.bouncycastle.asn1.x509

public Class Holder

extends ASN1Object
Class Inheritance
Imports
org.bouncycastle.asn1.ASN1EncodableVector, .ASN1Object, .ASN1Primitive, .ASN1Sequence, .ASN1TaggedObject, .DERSequence, .DERTaggedObject

The Holder object.

For an v2 attribute certificate this is:

           Holder ::= SEQUENCE {
                 baseCertificateID   [0] IssuerSerial OPTIONAL,
                          -- the issuer and serial number of
                          -- the holder's Public Key Certificate
                 entityName          [1] GeneralNames OPTIONAL,
                          -- the name of the claimant or role
                 objectDigestInfo    [2] ObjectDigestInfo OPTIONAL
                          -- used to directly authenticate the holder,
                          -- for example, an executable
           }

For an v1 attribute certificate this is:

        subject CHOICE {
         baseCertificateID [0] EXPLICIT IssuerSerial,
         -- associated with a Public Key Certificate
         subjectName [1] EXPLICIT GeneralNames },
         -- associated with a name

Field Summary

Modifier and TypeField and Description
pack-priv IssuerSerial
pack-priv GeneralNames
pack-priv ObjectDigestInfo
public static final int
public static final int
private int

Constructor Summary

AccessConstructor and Description
private
Holder(ASN1TaggedObject
The ASN.1 tagged holder object.
tagObj
)

Constructor for a holder for an V1 attribute certificate.

private
Holder(ASN1Sequence
The ASN.1 sequence.
seq
)

Constructor for a holder for an V2 attribute certificate.

public
Holder(IssuerSerial baseCertificateID)

public
Holder(IssuerSerial
The IssuerSerial.
baseCertificateID
,
int
The version of the attribute certificate.
version
)

Constructs a holder from a IssuerSerial for a V1 or V2 certificate.

public
Holder(GeneralNames
The entity or subject name.
entityName
)

Constructs a holder with an entityName for V2 attribute certificates.

public
Holder(GeneralNames
The entity or subject name.
entityName
,
int
The version of the attribute certificate.
version
)

Constructs a holder with an entityName for V2 attribute certificates or with a subjectName for V1 attribute certificates.

public
Holder(ObjectDigestInfo
The object digest info object.
objectDigestInfo
)

Constructs a holder from an object digest info.

Method Summary

Modifier and TypeMethod and Description
public IssuerSerial
public GeneralNames

Returns:

The entityname or subjectname.
getEntityName
()

Returns the entityName for an V2 attribute certificate or the subjectName for an V1 attribute certificate.

public static Holder
public ObjectDigestInfo
public int

Returns:

The version of the attribute certificate.
getVersion
()

Returns 1 for V2 attribute certificates or 0 for V1 attribute certificates.

public ASN1Primitive
toASN1Primitive()

Implements abstract org.bouncycastle.asn1.ASN1Object.toASN1Primitive.

Implements org.bouncycastle.asn1.ASN1Encodable.toASN1Primitive.

Method providing a primitive representation of this object suitable for encoding.
Inherited from org.bouncycastle.asn1.ASN1Object:
encodeToencodeToequalsgetEncodedgetEncodedhasEncodedTagValuehashCode

Field Detail

baseCertificateIDback to summary
pack-priv IssuerSerial baseCertificateID
entityNameback to summary
pack-priv GeneralNames entityName
objectDigestInfoback to summary
pack-priv ObjectDigestInfo objectDigestInfo
V1_CERTIFICATE_HOLDERback to summary
public static final int V1_CERTIFICATE_HOLDER
V2_CERTIFICATE_HOLDERback to summary
public static final int V2_CERTIFICATE_HOLDER
versionback to summary
private int version

Constructor Detail

Holderback to summary
private Holder(ASN1TaggedObject tagObj)

Constructor for a holder for an V1 attribute certificate.

Parameters
tagObj:ASN1TaggedObject

The ASN.1 tagged holder object.

Holderback to summary
private Holder(ASN1Sequence seq)

Constructor for a holder for an V2 attribute certificate.

Parameters
seq:ASN1Sequence

The ASN.1 sequence.

Holderback to summary
public Holder(IssuerSerial baseCertificateID)
Holderback to summary
public Holder(IssuerSerial baseCertificateID, int version)

Constructs a holder from a IssuerSerial for a V1 or V2 certificate. .

Parameters
baseCertificateID:IssuerSerial

The IssuerSerial.

version:int

The version of the attribute certificate.

Holderback to summary
public Holder(GeneralNames entityName)

Constructs a holder with an entityName for V2 attribute certificates.

Parameters
entityName:GeneralNames

The entity or subject name.

Holderback to summary
public Holder(GeneralNames entityName, int version)

Constructs a holder with an entityName for V2 attribute certificates or with a subjectName for V1 attribute certificates.

Parameters
entityName:GeneralNames

The entity or subject name.

version:int

The version of the attribute certificate.

Holderback to summary
public Holder(ObjectDigestInfo objectDigestInfo)

Constructs a holder from an object digest info.

Parameters
objectDigestInfo:ObjectDigestInfo

The object digest info object.

Method Detail

getBaseCertificateIDback to summary
public IssuerSerial getBaseCertificateID()
getEntityNameback to summary
public GeneralNames getEntityName()

Returns the entityName for an V2 attribute certificate or the subjectName for an V1 attribute certificate.

Returns:GeneralNames

The entityname or subjectname.

getInstanceback to summary
public static Holder getInstance(Object obj)
getObjectDigestInfoback to summary
public ObjectDigestInfo getObjectDigestInfo()
getVersionback to summary
public int getVersion()

Returns 1 for V2 attribute certificates or 0 for V1 attribute certificates.

Returns:int

The version of the attribute certificate.

toASN1Primitiveback to summary
public ASN1Primitive toASN1Primitive()

Implements abstract org.bouncycastle.asn1.ASN1Object.toASN1Primitive.

Implements org.bouncycastle.asn1.ASN1Encodable.toASN1Primitive.

Doc from org.bouncycastle.asn1.ASN1Object.toASN1Primitive.

Method providing a primitive representation of this object suitable for encoding.

Returns:ASN1Primitive

a primitive representation of this object.