home *** CD-ROM | disk | FTP | other *** search
/ Java 1.2 How-To / JavaHowTo.iso / 3rdParty / jbuilder / unsupported / JDK1.2beta3 / SOURCE / SRC.ZIP / java / security / cert / RevokedCertificate.java < prev    next >
Encoding:
Java Source  |  1998-03-20  |  2.4 KB  |  87 lines

  1. /*
  2.  * @(#)RevokedCertificate.java    1.5 98/03/18
  3.  *
  4.  * Copyright 1997 by Sun Microsystems, Inc.,
  5.  * 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
  6.  * All rights reserved.
  7.  *
  8.  * This software is the confidential and proprietary information
  9.  * of Sun Microsystems, Inc. ("Confidential Information").  You
  10.  * shall not disclose such Confidential Information and shall use
  11.  * it only in accordance with the terms of the license agreement
  12.  * you entered into with Sun.
  13.  */
  14.  
  15. package java.security.cert;
  16.  
  17. import java.math.BigInteger;
  18. import java.util.Date;
  19. import java.util.Set;
  20.  
  21. /**
  22.  * <p>Abstract class for a revoked certificate in a CRL (Certificate 
  23.  * Revocation List).
  24.  *
  25.  * The ASN.1 definition for <em>revokedCertificates</em> is:
  26.  * <pre>
  27.  * revokedCertificates    SEQUENCE OF SEQUENCE  {
  28.  *     userCertificate    CertificateSerialNumber,
  29.  *     revocationDate     ChoiceOfTime,
  30.  *     crlEntryExtensions Extensions OPTIONAL
  31.  *                        -- if present, must be v2
  32.  * }  OPTIONAL
  33.  *<p>
  34.  * CertificateSerialNumber  ::=  INTEGER
  35.  *<p>
  36.  * Extensions  ::=  SEQUENCE SIZE (1..MAX) OF Extension
  37.  *<p>
  38.  * Extension  ::=  SEQUENCE  {
  39.  *     extnId        OBJECT IDENTIFIER,
  40.  *     critical      BOOLEAN DEFAULT FALSE,
  41.  *     extnValue     OCTET STRING
  42.  *                   -- contains a DER encoding of a value
  43.  *                   -- of the type registered for use with
  44.  *                   -- the extnId object identifier value
  45.  * }
  46.  * </pre>
  47.  * 
  48.  * @see X509CRL
  49.  *
  50.  * @author Hemma Prafullchandra
  51.  * @version 1.5 98/03/18
  52.  */
  53.  
  54. public abstract class RevokedCertificate implements X509Extension {
  55.  
  56.     /**
  57.      * Gets the serial number for this RevokedCertificate,
  58.      * the <em>userCertificate</em>.
  59.      * 
  60.      * @return the serial number.
  61.      */
  62.     public abstract BigInteger getSerialNumber();
  63.  
  64.     /**
  65.      * Gets the revocation date for this RevokedCertificate,
  66.      * the <em>revocationDate</em>.
  67.      * 
  68.      * @return the revocation date.
  69.      */
  70.     public abstract Date getRevocationDate();
  71.  
  72.     /**
  73.      * Returns true if this revoked certificate entry has
  74.      * extensions.
  75.      *
  76.      * @return true if this entry has extensions, false otherwise.
  77.      */
  78.     public abstract boolean hasExtensions();
  79.  
  80.     /**
  81.      * Returns a string representation of this revoked certificate.
  82.      *
  83.      * @return a string representation of this revoked certificate.
  84.      */
  85.     public abstract String toString();
  86. }
  87.