Struct isahc::config::CaCertificate
source · pub struct CaCertificate { /* private fields */ }
Expand description
A public CA certificate bundle file.
Implementations
sourceimpl CaCertificate
impl CaCertificate
sourcepub fn pem<B>(bytes: B) -> Selfwhere
B: Into<Vec<u8>>,
pub fn pem<B>(bytes: B) -> Selfwhere
B: Into<Vec<u8>>,
Use one or more PEM-encoded certificates in the given byte buffer.
The certificate object takes ownership of the byte buffer. If a borrowed
type is supplied, such as &[u8]
, then the bytes will be copied.
The certificates are not parsed or validated here. If a certificate is malformed or the format is not supported by the underlying SSL/TLS engine, an error will be returned when attempting to send a request using the offending certificate.
sourcepub fn file(ca_bundle_path: impl Into<PathBuf>) -> Self
pub fn file(ca_bundle_path: impl Into<PathBuf>) -> Self
Get a CA certificate from a path to a certificate bundle file.
The certificate file is not loaded or validated here. If the file does not exist or the format is not supported by the underlying SSL/TLS engine, an error will be returned when attempting to send a request using the offending certificate.
Trait Implementations
sourceimpl Clone for CaCertificate
impl Clone for CaCertificate
sourcefn clone(&self) -> CaCertificate
fn clone(&self) -> CaCertificate
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more