org.bouncycastle.ocsp

## Class CertificateID

- java.lang.Object
- - org.bouncycastle.ocsp.CertificateID

    public class CertificateID
    extends java.lang.Object

### Field Summary

Fields
`static java.lang.String` `HASH_SHA1`

### Constructor Summary

Constructors
Constructor and Description
`CertificateID(CertID id)`
`CertificateID(java.lang.String hashAlgorithm, java.security.cert.X509Certificate issuerCert, java.math.BigInteger number)` create using the BC provider
`CertificateID(java.lang.String hashAlgorithm, java.security.cert.X509Certificate issuerCert, java.math.BigInteger number, java.lang.String provider)` create from an issuer certificate and the serial number of the certificate it signed.

### Method Summary

Methods
`boolean` `equals(java.lang.Object o)`
`java.lang.String` `getHashAlgOID()`
`byte[]` `getIssuerKeyHash()`
`byte[]` `getIssuerNameHash()`
`java.math.BigInteger` `getSerialNumber()` return the serial number for the certificate associated with this request.
`int` `hashCode()`
`boolean` `matchesIssuer(java.security.cert.X509Certificate issuerCert, java.lang.String provider)`
`CertID` `toASN1Object()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### HASH_SHA1

    public static final java.lang.String HASH_SHA1

See Also:
  Constant Field Values

### Constructor Detail

#### CertificateID

    public CertificateID(CertID id)

#### CertificateID

    public CertificateID(java.lang.String hashAlgorithm,
                 java.security.cert.X509Certificate issuerCert,
                 java.math.BigInteger number,
                 java.lang.String provider)
                  throws OCSPException

create from an issuer certificate and the serial number of the certificate it signed.

Parameters:
  `hashAlgorithm` - hash algorithm to use
  `issuerCert` - issuing certificate
  `number` - serial number
  `provider` - provider to use for hashAlgorithm, null if the default one should be used.
Throws:
  `OCSPException` - if any problems occur creating the id fields.

#### CertificateID

    public CertificateID(java.lang.String hashAlgorithm,
                 java.security.cert.X509Certificate issuerCert,
                 java.math.BigInteger number)
                  throws OCSPException

create using the BC provider

Throws:
  `OCSPException`

### Method Detail

#### getHashAlgOID

    public java.lang.String getHashAlgOID()

#### getIssuerNameHash

    public byte[] getIssuerNameHash()

#### getIssuerKeyHash

    public byte[] getIssuerKeyHash()

#### getSerialNumber

    public java.math.BigInteger getSerialNumber()

return the serial number for the certificate associated with this request.

#### matchesIssuer

    public boolean matchesIssuer(java.security.cert.X509Certificate issuerCert,
                        java.lang.String provider)
                          throws OCSPException

Throws:
  `OCSPException`

#### toASN1Object

    public CertID toASN1Object()

#### equals

    public boolean equals(java.lang.Object o)

Overrides:
  `equals` in class `java.lang.Object`

#### hashCode

    public int hashCode()

Overrides:
  `hashCode` in class `java.lang.Object`