Class Certificate

java.lang.Object
javax.security.cert.Certificate
Direct Known Subclasses:
X509Certificate

public abstract class Certificate
extends Object
Abstract class to represent identity certificates. It represents a way to verify the binding of a Principal and its public key. Examples are X.509, PGP, and SDSI.

Note: This package is provided only for compatibility reasons. It contains a simplified version of the java.security.cert package that was previously used by JSSE (Java SSL package). All applications that do not have to be compatible with older versions of JSSE (that is before Java SDK 1.5) should only use java.security.cert.

  • Constructor Summary

    Constructors
    Constructor Description
    Certificate()
    Creates a new Certificate.
  • Method Summary

    Modifier and Type Method Description
    boolean equals​(Object obj)
    Compares the argument to this Certificate.
    abstract byte[] getEncoded()
    Returns the encoded representation for this certificate.
    abstract PublicKey getPublicKey()
    Returns the public key corresponding to this certificate.
    int hashCode()
    Returns an integer hash code for the receiver.
    abstract String toString()
    Returns a string containing a concise, human-readable description of the receiver.
    abstract void verify​(PublicKey key)
    Verifies that this certificate was signed with the given public key.
    abstract void verify​(PublicKey key, String sigProvider)
    Verifies that this certificate was signed with the given public key.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait