Package org.bouncycastle.cert.ocsp
Class BasicOCSPResp
java.lang.Object
org.bouncycastle.cert.ocsp.BasicOCSPResp
- All Implemented Interfaces:
org.bouncycastle.util.Encodable
OCSP RFC 2560, RFC 6960
BasicOCSPResponse ::= SEQUENCE {
tbsResponseData ResponseData,
signatureAlgorithm AlgorithmIdentifier,
signature BIT STRING,
certs [0] EXPLICIT SEQUENCE OF Certificate OPTIONAL }
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleangetCerts()byte[]return the ASN.1 encoded representation of this object.org.bouncycastle.asn1.x509.ExtensiongetExtension(org.bouncycastle.asn1.ASN1ObjectIdentifier oid) byte[]org.bouncycastle.asn1.ASN1ObjectIdentifierorg.bouncycastle.asn1.x509.AlgorithmIdentifierReturn the algorithm identifier describing the signature used in the response.byte[]Return the DER encoding of the tbsResponseData field.intbooleaninthashCode()booleanisSignatureValid(ContentVerifierProvider verifierProvider) verify the signature against the tbsResponseData object we contain.
-
Constructor Details
-
BasicOCSPResp
public BasicOCSPResp(org.bouncycastle.asn1.ocsp.BasicOCSPResponse resp)
-
-
Method Details
-
getTBSResponseData
public byte[] getTBSResponseData()Return the DER encoding of the tbsResponseData field.- Returns:
- DER encoding of tbsResponseData
-
getSignatureAlgorithmID
public org.bouncycastle.asn1.x509.AlgorithmIdentifier getSignatureAlgorithmID()Return the algorithm identifier describing the signature used in the response.- Returns:
- an AlgorithmIdentifier
-
getVersion
public int getVersion() -
getResponderId
-
getProducedAt
-
getResponses
-
hasExtensions
public boolean hasExtensions() -
getExtension
public org.bouncycastle.asn1.x509.Extension getExtension(org.bouncycastle.asn1.ASN1ObjectIdentifier oid) -
getExtensionOIDs
-
getCriticalExtensionOIDs
-
getNonCriticalExtensionOIDs
-
getSignatureAlgOID
public org.bouncycastle.asn1.ASN1ObjectIdentifier getSignatureAlgOID() -
getSignature
public byte[] getSignature() -
getCerts
-
isSignatureValid
verify the signature against the tbsResponseData object we contain.- Throws:
OCSPException
-
getEncoded
return the ASN.1 encoded representation of this object.- Specified by:
getEncodedin interfaceorg.bouncycastle.util.Encodable- Throws:
IOException
-
equals
-
hashCode
public int hashCode()
-