Struct openssl::x509::X509 [] [src]

pub struct X509(_);

An owned public key certificate.

Methods

impl X509
[src]

unsafe fn new(x509: *mut X509) -> X509

Returns a new X509, taking ownership of the handle.

fn from_pem(buf: &[u8]) -> Result<X509, ErrorStack>

Reads a certificate from PEM.

Methods from Deref<Target=X509Ref<'static>>

fn as_ptr(&self) -> *mut X509

fn subject_name<'b>(&'b self) -> X509Name<'b>

fn subject_alt_names<'b>(&'b self) -> Option<GeneralNames<'b>>

Returns this certificate's SAN entries, if they exist.

fn public_key(&self) -> Result<PKey, ErrorStack>

fn fingerprint(&self, hash_type: Type) -> Result<Vec<u8>, ErrorStack>

Returns certificate fingerprint calculated using provided hash

fn to_pem(&self) -> Result<Vec<u8>, ErrorStack>

Writes certificate as PEM

fn to_der(&self) -> Result<Vec<u8>, ErrorStack>

Returns a DER serialized form of the certificate

Trait Implementations

impl Deref for X509
[src]

type Target = X509Ref<'static>

The resulting type after dereferencing

fn deref(&self) -> &X509Ref<'static>

The method called to dereference a value

impl Clone for X509
[src]

fn clone(&self) -> X509

Requires the x509_clone feature.

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl Drop for X509
[src]

fn drop(&mut self)

A method called when the value goes out of scope. Read more