Struct openssl::x509::store::X509Lookup
source · pub struct X509Lookup<T>(/* private fields */);
Expand description
Information used by an X509Store
to look up certificates and CRLs.
Implementations§
source§impl X509Lookup<HashDir>
impl X509Lookup<HashDir>
sourcepub fn hash_dir() -> &'static X509LookupMethodRef<HashDir>
pub fn hash_dir() -> &'static X509LookupMethodRef<HashDir>
Lookup method that loads certificates and CRLs on demand and caches them in memory once they are loaded. It also checks for newer CRLs upon each lookup, so that newer CRLs are used as soon as they appear in the directory.
This corresponds to X509_LOOKUP_hash_dir
.
source§impl X509Lookup<File>
impl X509Lookup<File>
sourcepub fn file() -> &'static X509LookupMethodRef<File>
pub fn file() -> &'static X509LookupMethodRef<File>
Lookup method loads all the certificates or CRLs present in a file into memory at the time the file is added as a lookup source.
This corresponds to X509_LOOKUP_file
.
Methods from Deref<Target = X509LookupRef<T>>§
sourcepub fn add_dir(
&mut self,
name: &str,
file_type: SslFiletype
) -> Result<(), ErrorStack>
pub fn add_dir( &mut self, name: &str, file_type: SslFiletype ) -> Result<(), ErrorStack>
Specifies a directory from which certificates and CRLs will be loaded
on-demand. Must be used with X509Lookup::hash_dir
.
This corresponds to X509_LOOKUP_add_dir
.
sourcepub fn load_cert_file<P: AsRef<Path>>(
&mut self,
file: P,
file_type: SslFiletype
) -> Result<(), ErrorStack>
pub fn load_cert_file<P: AsRef<Path>>( &mut self, file: P, file_type: SslFiletype ) -> Result<(), ErrorStack>
Specifies a file from which certificates will be loaded
This corresponds to X509_load_cert_file
.
sourcepub fn load_crl_file<P: AsRef<Path>>(
&mut self,
file: P,
file_type: SslFiletype
) -> Result<i32, ErrorStack>
pub fn load_crl_file<P: AsRef<Path>>( &mut self, file: P, file_type: SslFiletype ) -> Result<i32, ErrorStack>
Specifies a file from which certificate revocation lists will be loaded
This corresponds to X509_load_crl_file
.