Struct openssl::ocsp::OcspResponse
[−]
pub struct OcspResponse(_);
Methods
impl OcspResponse
[src]
fn create(status: OcspResponseStatus,
body: Option<&OcspBasicResponseRef>)
-> Result<OcspResponse, ErrorStack>
body: Option<&OcspBasicResponseRef>)
-> Result<OcspResponse, ErrorStack>
Creates an OCSP response from the status and optional body.
A body should only be provided if status
is RESPONSE_STATUS_SUCCESSFUL
.
fn from_der(der: &[u8]) -> Result<OcspResponse, ErrorStack>
Deserializes a value from DER-formatted data.
Methods from Deref<Target=OcspResponseRef>
fn to_der(&self) -> Result<Vec<u8>, ErrorStack>
Serializes this value to DER.
fn status(&self) -> OcspResponseStatus
Returns the status of the response.
fn basic(&self) -> Result<OcspBasicResponse, ErrorStack>
Returns the basic response.
This will only succeed if status()
returns RESPONSE_STATUS_SUCCESSFUL
.
Trait Implementations
impl ForeignType for OcspResponse
type CType = OCSP_RESPONSE
The raw C type.
type Ref = OcspResponseRef
The type representing a reference to this type.
unsafe fn from_ptr(ptr: *mut OCSP_RESPONSE) -> OcspResponse
Constructs an instance of this type from its raw type.
fn as_ptr(&self) -> *mut OCSP_RESPONSE
Returns a raw pointer to the wrapped value.
impl Drop for OcspResponse
impl Deref for OcspResponse
type Target = OcspResponseRef
The resulting type after dereferencing
fn deref(&self) -> &OcspResponseRef
The method called to dereference a value
impl DerefMut for OcspResponse
fn deref_mut(&mut self) -> &mut OcspResponseRef
The method called to mutably dereference a value