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

public Class CertificatePair

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

This class helps to support crossCerfificatePairs in a LDAP directory according RFC 2587
    crossCertificatePairATTRIBUTE::={
      WITH SYNTAX   CertificatePair
      EQUALITY MATCHING RULE certificatePairExactMatch
      ID joint-iso-ccitt(2) ds(5) attributeType(4) crossCertificatePair(40)}
The forward elements of the crossCertificatePair attribute of a CA's directory entry shall be used to store all, except self-issued certificates issued to this CA. Optionally, the reverse elements of the crossCertificatePair attribute, of a CA's directory entry may contain a subset of certificates issued by this CA to other CAs. When both the forward and the reverse elements are present in a single attribute value, issuer name in one certificate shall match the subject name in the other and vice versa, and the subject public key in one certificate shall be capable of verifying the digital signature on the other certificate and vice versa. When a reverse element is present, the forward element value and the reverse element value need not be stored in the same attribute value; in other words, they can be stored in either a single attribute value or two attribute values.
      CertificatePair ::= SEQUENCE {
        forward        [0]    Certificate OPTIONAL,
        reverse        [1]    Certificate OPTIONAL,
        -- at least one of the pair shall be present -- } 

Field Summary

Modifier and TypeField and Description
private Certificate
private Certificate

Constructor Summary

AccessConstructor and Description
private
CertificatePair(ASN1Sequence
The ASN.1 sequence.
seq
)

Constructor from ASN1Sequence.

public
CertificatePair(Certificate
Certificates issued to this CA.
forward
,
Certificate
Certificates issued by this CA to other CAs.
reverse
)

Constructor from a given details.

Method Summary

Modifier and TypeMethod and Description
public Certificate

Returns:

Returns the forward.
getForward
()

public static CertificatePair
public Certificate

Returns:

Returns the reverse.
getReverse
()

public ASN1Primitive

Returns:

a ASN1Primitive
toASN1Primitive
()

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

Implements org.bouncycastle.asn1.ASN1Encodable.toASN1Primitive.

Produce an object suitable for an ASN1OutputStream.
Inherited from org.bouncycastle.asn1.ASN1Object:
encodeToencodeToequalsgetEncodedgetEncodedhasEncodedTagValuehashCode

Field Detail

forwardback to summary
private Certificate forward
reverseback to summary
private Certificate reverse

Constructor Detail

CertificatePairback to summary
private CertificatePair(ASN1Sequence seq)

Constructor from ASN1Sequence.

The sequence is of type CertificatePair:

      CertificatePair ::= SEQUENCE {
        forward        [0]    Certificate OPTIONAL,
        reverse        [1]    Certificate OPTIONAL,
        -- at least one of the pair shall be present -- }

Parameters
seq:ASN1Sequence

The ASN.1 sequence.

CertificatePairback to summary
public CertificatePair(Certificate forward, Certificate reverse)

Constructor from a given details.

Parameters
forward:Certificate

Certificates issued to this CA.

reverse:Certificate

Certificates issued by this CA to other CAs.

Method Detail

getForwardback to summary
public Certificate getForward()
Returns:Certificate

Returns the forward.

getInstanceback to summary
public static CertificatePair getInstance(Object obj)
getReverseback to summary
public Certificate getReverse()
Returns:Certificate

Returns the reverse.

toASN1Primitiveback to summary
public ASN1Primitive toASN1Primitive()

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

Implements org.bouncycastle.asn1.ASN1Encodable.toASN1Primitive.

Produce an object suitable for an ASN1OutputStream.

Returns:

      CertificatePair ::= SEQUENCE {
        forward        [0]    Certificate OPTIONAL,
        reverse        [1]    Certificate OPTIONAL,
        -- at least one of the pair shall be present -- }
Returns:ASN1Primitive

a ASN1Primitive