Package | Class | Tree | Deprecated | Index | Help
| Oracle Security Developer Tools CMS Java API Reference 10g Release 3 (10.1.3) B25377-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.security.crypto.cms
Class ESSCertID

`java.lang.Object
oracle.security.crypto.cms.ESSCertID`

All Implemented Interfaces:
  oracle.security.crypto.asn1.ASN1Object, oracle.security.crypto.util.Streamable

public class ESSCertID
extends java.lang.Object
implements oracle.security.crypto.asn1.ASN1Object

Represents the ESSCertID of a certificate which is used in the Signing Certificate Attribute.

Constructor Summary
`ESSCertID(java.io.InputStream is)` Creates a new `ESSCertID` by reading from the input stream.
`ESSCertID(oracle.security.crypto.cert.X509 cert)` Creates a new `ESSCertID` for the specified certificate.
`ESSCertID(oracle.security.crypto.cert.X509 cert, oracle.security.crypto.cert.X509 caCert, boolean issuerSerial)` Creates a new `ESSCertID` for the specified certificate.

Method Summary
`boolean` | `compareTo(oracle.security.crypto.cert.X509 cert)` Compare this object with the ESSCertID object created from the given certificate.
`boolean` | `compareTo(oracle.security.crypto.cert.X509 cert, oracle.security.crypto.cert.X509 caCert)` Compare this object with the ESSCertID object created from the two given certificates.
`boolean` | `containsIssuerSerial()` Indicates if the IssuerSerial is present.
`boolean` | `equals(java.lang.Object o)` Compares this ESSCertID object to the given object.
`byte[]` | `getCertHash()` Returns the hash of the certificate represented by this ESSCertID object.
`oracle.security.crypto.cert.GeneralNames` | `getGeneralNames()` Returns the list of the General Names of the issuer of the certificate represented by this ESSCertID object.
`java.math.BigInteger` | `getSerialNo()` Returns the serial number of the of the certificate represented by this ESSCertID object.
`int` | `hashCode()` Returns the hash code of this object.
`void` | `input(java.io.InputStream is)` Initialize this object by reading the ESSCertID encoding from the specified input stream.
`int` | `length()` Returns the length of this object's encoding.
`void` | `output(java.io.OutputStream os)` Output this object's encoding to the specified output stream.
`java.lang.String` | `toString()` Returns information about this object.

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### ESSCertID

    public ESSCertID(oracle.security.crypto.cert.X509 cert)
              throws oracle.security.crypto.core.AlgorithmIdentifierException

  Creates a new `ESSCertID` for the specified certificate.
Parameters:
  `cert` - The X509 certificate.

### ESSCertID

    public ESSCertID(oracle.security.crypto.cert.X509 cert,
                     oracle.security.crypto.cert.X509 caCert,
                     boolean issuerSerial)
              throws oracle.security.crypto.core.AlgorithmIdentifierException

  Creates a new `ESSCertID` for the specified certificate.
Parameters:
  `cert` - The X509 certificate.
  `caCert` - The issuer's X509 certificate.
  `issuerSerial` - If `true`, the issuerSerial of the certificate is added.

### ESSCertID

    public ESSCertID(java.io.InputStream is)
              throws java.io.IOException

  Creates a new `ESSCertID` by reading from the input stream.
Parameters:
  `is` - The input stream.

Method Detail

### getCertHash

    public byte[] getCertHash()

  Returns the hash of the certificate represented by this ESSCertID object.
  Returns:
    A byte[] representing the hash of the certificate.

### getGeneralNames

    public oracle.security.crypto.cert.GeneralNames getGeneralNames()

  Returns the list of the General Names of the issuer of the certificate represented by this ESSCertID object.
  Returns:
    A Vector containing `GeneralName` objects if present or `null` otherwise.

### getSerialNo

    public java.math.BigInteger getSerialNo()

  Returns the serial number of the of the certificate represented by this ESSCertID object.
  Returns:
    The Serial Number if present or `null` otherwise.

### compareTo

    public boolean compareTo(oracle.security.crypto.cert.X509 cert)
                      throws oracle.security.crypto.core.AlgorithmIdentifierException

  Compare this object with the ESSCertID object created from the given certificate. Only the Certificate Hashes are compared even if the IssuerSerial is present.
  Parameters:
    `cert` - A X509 certificate.
  Returns:
    `true` if this object was made from the specified certificate; `false` otherwise.
  Throws:
    `oracle.security.crypto.core.AlgorithmIdentifierException` - An error occurred during certificate hash generation.

### compareTo

    public boolean compareTo(oracle.security.crypto.cert.X509 cert,
                             oracle.security.crypto.cert.X509 caCert)
                      throws oracle.security.crypto.core.AlgorithmIdentifierException,
                             java.io.IOException

  Compare this object with the ESSCertID object created from the two given certificates. Checks if the object is a ESSCertID object, if the certificate hash is the same. If the IssuerSerial is present, it checks the serial number and for any matching GeneralName.
  Parameters:
    `cert` - A X509 certificate.
    `caCert` - The issuer's certificate.
  Returns:
    `true` if this object was made from these two certificates; `false` otherwise.
  Throws:
    `oracle.security.crypto.core.AlgorithmIdentifierException`
    `java.io.IOException`

### containsIssuerSerial

    public boolean containsIssuerSerial()

  Indicates if the IssuerSerial is present.
  Returns:
    `true` if the IssuerSerial is present;`false` otherwise.

### equals

    public boolean equals(java.lang.Object o)

  Compares this ESSCertID object to the given object.
  Returns:
    `true` if the objects are the same, false otherwise.

### hashCode

    public int hashCode()

  Returns the hash code of this object.
  Returns:
    The hash code.

### input

    public void input(java.io.InputStream is)
               throws java.io.IOException

  Initialize this object by reading the ESSCertID encoding from the specified input stream.
  Specified by:
    `input` in interface `oracle.security.crypto.util.Streamable`
  Parameters:
    `is` - The input stream.
  Throws:
    `java.io.IOException`

### output

    public void output(java.io.OutputStream os)
                throws java.io.IOException

  Output this object's encoding to the specified output stream.
  Specified by:
    `output` in interface `oracle.security.crypto.util.Streamable`
  Parameters:
    `os` - The output stream.
  Throws:
    `java.io.IOException`

### length

    public int length()

  Returns the length of this object's encoding.
  Specified by:
    `length` in interface `oracle.security.crypto.util.Streamable`
  Returns:
    The length in bytes.

### toString

    public java.lang.String toString()

  Returns information about this object.
  Returns:
    A string.

Package | Class | Tree | Deprecated | Index | Help
| Oracle Security Developer Tools CMS Java API Reference 10g Release 3 (10.1.3) B25377-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2005, 2006 , Oracle. All rights reserved.