Skip to main content

install_default_crypto_provider_if_none_installed

Function install_default_crypto_provider_if_none_installed 

Source
pub fn install_default_crypto_provider_if_none_installed()
Available on crate feature rustls-tls only.
Expand description

The rustls-tls flag enables the rustls implementation of TLS for reqwest, but without a CryptoProvider. This means that no default provider is installed, which will cause reqwest::Client::new() to panic.

This functions installs the preferred default provider given by default_crypto_provider, if no default has previously been installed.