Class CertificateRenewalWindowExtension

java.lang.Object
org.mozilla.jss.netscape.security.x509.Extension
org.mozilla.jss.netscape.security.extensions.CertificateRenewalWindowExtension
All Implemented Interfaces:
Serializable, CertAttrSet

public class CertificateRenewalWindowExtension extends Extension implements CertAttrSet
This represents the CertificateRenewalWindow extension as defined in draft-thayes-cert-renewal-00 CertificateRenewalWindow ::= SEQUENCE { beginTime GeneralizedTime, endTime GeneralizedTime OPTIONAL }
Version:
$Revision$, $Date$
See Also:
  • Field Details

  • Constructor Details

    • CertificateRenewalWindowExtension

      public CertificateRenewalWindowExtension(boolean critical, Date beginTime, Date endTime) throws IOException
      Throws:
      IOException
    • CertificateRenewalWindowExtension

      public CertificateRenewalWindowExtension(boolean critical)
    • CertificateRenewalWindowExtension

      public CertificateRenewalWindowExtension(Boolean critical, Object value) throws IOException
      Throws:
      IOException
  • Method Details

    • getName

      public String getName()
      Description copied from interface: CertAttrSet
      Returns the name (identifier) of this CertAttrSet.
      Specified by:
      getName in interface CertAttrSet
      Returns:
      the name of this CertAttrSet.
    • set

      public void set(String name, Object obj) throws CertificateException
      Sets extension attribute.
      Specified by:
      set in interface CertAttrSet
      Parameters:
      name - the name of the attribute (e.g. "x509.info.key")
      obj - the attribute object.
      Throws:
      CertificateException - on attribute handling errors.
    • get

      public Object get(String name) throws CertificateException
      Retrieves extension attribute.
      Specified by:
      get in interface CertAttrSet
      Parameters:
      name - the name of the attribute to return.
      Returns:
      attribute value
      Throws:
      CertificateException - on attribute handling errors.
    • delete

      public void delete(String name) throws CertificateException
      Deletes attribute.
      Specified by:
      delete in interface CertAttrSet
      Parameters:
      name - the name of the attribute to delete.
      Throws:
      CertificateException - on attribute handling errors.
    • decode

      public void decode(InputStream in) throws IOException
      Decodes this extension.
      Specified by:
      decode in interface CertAttrSet
      Parameters:
      in - the InputStream to read the encoded attribute from.
      Throws:
      IOException - on other errors.
    • getAttributeNames

      public Enumeration<String> getAttributeNames()
      Return an enumeration of names of attributes existing within this attribute.
      Specified by:
      getAttributeNames in interface CertAttrSet
      Returns:
      an enumeration of the attribute names.
    • getBeginTime

      public Date getBeginTime()
    • getEndTime

      public Date getEndTime()
    • setBeginTime

      public void setBeginTime(Date d)
    • setEndTime

      public void setEndTime(Date d)
    • decodeThis

      private void decodeThis() throws IOException
      Throws:
      IOException
    • encodeThis

      private void encodeThis() throws IOException
      Throws:
      IOException
    • encode

      public void encode(OutputStream out) throws IOException
      Write the extension to the DerOutputStream.
      Specified by:
      encode in interface CertAttrSet
      Parameters:
      out - the DerOutputStream to write the extension to.
      Throws:
      IOException - on encoding errors.
    • toString

      public String toString()
      Returns a printable representation of the CertificateRenewalWindow.
      Specified by:
      toString in interface CertAttrSet
      Overrides:
      toString in class Extension
      Returns:
      value of this certificate attribute in printable form.