Class OtherInfo

java.lang.Object
org.mozilla.jss.pkix.cmc.OtherInfo
All Implemented Interfaces:
ASN1Value

public class OtherInfo extends Object implements ASN1Value
CMCStatusInfoV2 OtherInfo:
   OtherInfo ::= CHOICE { 
       failInfo INTEGER, 
       pendInfo PendInfo,
       extendedFailInfo       SEQUENCE {  // ExtendedFailInfo
           failInfoOID            OBJECT IDENTIFIER,
           failInfoValue          AttributeValue
       } OPTIONAL
   }
 
  • Field Details

  • Constructor Details

    • OtherInfo

      public OtherInfo()
    • OtherInfo

      public OtherInfo(OtherInfo.Type type, INTEGER failInfo, PendInfo pendInfo)
      Constructs a OtherInfo from its components.
      Parameters:
      type - The type of the otherInfo.
      failInfo - the CMCFailInfo code.
      pendInfo - the pending information. Note: kept for backward compatibility for now; new code don't use
    • OtherInfo

      public OtherInfo(OtherInfo.Type type, INTEGER failInfo, PendInfo pendInfo, ExtendedFailInfo extendedFailInfo)
      Constructs a OtherInfo from its components.
      Parameters:
      type - The type of the otherInfo.
      failInfo - the CMCFailInfo code.
      pendInfo - the pending information.
      extendedFailInfo - the extendedFailInfo information.
  • Method Details

    • getType

      public OtherInfo.Type getType()
      Returns the type of OtherInfo:
      • FAIL
      • PEND
      • EXTENDED
    • getFailInfo

      public INTEGER getFailInfo()
      If type == FAIL, returns the failInfo field. Otherwise, returns null.
    • getPendInfo

      public PendInfo getPendInfo()
      If type == PEND, returns the pendInfo field. Otherwise, returns null.
    • getExtendedFailInfo

      public ExtendedFailInfo getExtendedFailInfo()
      If type == EXTENDED, returns the extendedFailInfo field. Otherwise, returns null.
    • getTag

      public Tag getTag()
      Description copied from interface: ASN1Value
      Returns the base tag for this type, not counting any tags that may be imposed on it by its context.
      Specified by:
      getTag in interface ASN1Value
      Returns:
      Base tag.
    • encode

      public void encode(OutputStream ostream) throws IOException
      Description copied from interface: ASN1Value
      Write this value's DER encoding to an output stream using its own base tag.
      Specified by:
      encode in interface ASN1Value
      Parameters:
      ostream - Output stream.
      Throws:
      IOException - If an error occurred.
    • encode

      public void encode(Tag implicitTag, OutputStream ostream) throws IOException
      Description copied from interface: ASN1Value
      Write this value's DER encoding to an output stream using an implicit tag.
      Specified by:
      encode in interface ASN1Value
      Parameters:
      implicitTag - Implicit tag.
      ostream - Output stream.
      Throws:
      IOException - If an error occurred.
    • getTemplate

      public static OtherInfo.Template getTemplate()