Skip to main content

load_platform_root_certificates_inner

Function load_platform_root_certificates_inner 

Source
pub fn load_platform_root_certificates_inner() -> Result<RootCertStore, GenericError>
Expand description

Builds a RootCertStore from the platform’s native certificate store.

Behaves identically to load_platform_root_certificates with respect to which certificates are loaded, but returns the constructed store instead of writing it into the process-wide default.

§Errors

If errors occur during certificate loading and no certificates were ultimately added to the store, an error is returned. Otherwise, even if some certificates failed to parse, the store is returned with whatever certificates were successfully added. Missing files or directories referenced by SSL_CERT_FILE/SSL_CERT_DIR are tolerated and do not produce an error.