Top Description Fields Constructors Methods
org.bouncycastle.cert.ocsp

public Class OCSPReq

extends Object
Class Inheritance
Imports
java.io.IOException, .OutputStream, java.util.List, .Set, org.bouncycastle.asn1.ASN1Encoding, .ASN1Exception, .ASN1InputStream, .ASN1ObjectIdentifier, .ASN1Sequence, org.bouncycastle.asn1.ocsp.OCSPRequest, .Request, org.bouncycastle.asn1.x509.Certificate, .Extension, .Extensions, .GeneralName, org.bouncycastle.cert.CertIOException, .X509CertificateHolder, org.bouncycastle.operator.ContentVerifier, .ContentVerifierProvider

OCSPRequest     ::=     SEQUENCE {
      tbsRequest                  TBSRequest,
      optionalSignature   [0]     EXPLICIT Signature OPTIONAL }

  TBSRequest      ::=     SEQUENCE {
      version             [0]     EXPLICIT Version DEFAULT v1,
      requestorName       [1]     EXPLICIT GeneralName OPTIONAL,
      requestList                 SEQUENCE OF Request,
      requestExtensions   [2]     EXPLICIT Extensions OPTIONAL }

  Signature       ::=     SEQUENCE {
      signatureAlgorithm      AlgorithmIdentifier,
      signature               BIT STRING,
      certs               [0] EXPLICIT SEQUENCE OF Certificate OPTIONAL}

  Version         ::=             INTEGER  {  v1(0) }

  Request         ::=     SEQUENCE {
      reqCert                     CertID,
      singleRequestExtensions     [0] EXPLICIT Extensions OPTIONAL }

  CertID          ::=     SEQUENCE {
      hashAlgorithm       AlgorithmIdentifier,
      issuerNameHash      OCTET STRING, -- Hash of Issuer's DN
      issuerKeyHash       OCTET STRING, -- Hash of Issuers public key
      serialNumber        CertificateSerialNumber }

Field Summary

Modifier and TypeField and Description
private static final X509CertificateHolder[]
private Extensions
private OCSPRequest

Constructor Summary

AccessConstructor and Description
public
public
OCSPReq(byte[] req)

private

Method Summary

Modifier and TypeMethod and Description
public X509CertificateHolder[]
public Set<E>
public byte[]
getEncoded()

return the ASN.1 encoded representation of this object.

public Extension
public List<E>
public Set<E>
public Req[]
public GeneralName
public byte[]
public ASN1ObjectIdentifier
getSignatureAlgOID()

return the object identifier representing the signature algorithm

public int
public boolean
public boolean
isSignatureValid(ContentVerifierProvider verifierProvider)

verify the signature against the TBSRequest object we contain.

public boolean

Returns:

true if signed false otherwise.
isSigned
()

Return whether or not this request is signed.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

EMPTY_CERTSback to summary
private static final X509CertificateHolder[] EMPTY_CERTS
extensionsback to summary
private Extensions extensions
reqback to summary
private OCSPRequest req

Constructor Detail

OCSPReqback to summary
public OCSPReq(OCSPRequest req)
OCSPReqback to summary
public OCSPReq(byte[] req) throws IOException
OCSPReqback to summary
private OCSPReq(ASN1InputStream aIn) throws IOException

Method Detail

getCertsback to summary
public X509CertificateHolder[] getCerts()
getCriticalExtensionOIDsback to summary
public Set<E> getCriticalExtensionOIDs()
getEncodedback to summary
public byte[] getEncoded() throws IOException

return the ASN.1 encoded representation of this object.

getExtensionback to summary
public Extension getExtension(ASN1ObjectIdentifier oid)
getExtensionOIDsback to summary
public List<E> getExtensionOIDs()
getNonCriticalExtensionOIDsback to summary
public Set<E> getNonCriticalExtensionOIDs()
getRequestListback to summary
public Req[] getRequestList()
getRequestorNameback to summary
public GeneralName getRequestorName()
getSignatureback to summary
public byte[] getSignature()
getSignatureAlgOIDback to summary
public ASN1ObjectIdentifier getSignatureAlgOID()

return the object identifier representing the signature algorithm

getVersionNumberback to summary
public int getVersionNumber()
hasExtensionsback to summary
public boolean hasExtensions()
isSignatureValidback to summary
public boolean isSignatureValid(ContentVerifierProvider verifierProvider) throws OCSPException

verify the signature against the TBSRequest object we contain.

isSignedback to summary
public boolean isSigned()

Return whether or not this request is signed.

Returns:boolean

true if signed false otherwise.