Skip to main content

Crate tls_hot_reload

Crate tls_hot_reload 

Source

Modules§

error

Structs§

BundleCert
Used to create a new CertifiedKeysWatched. If you want to resolve a wildcard certificate, you need to specify it for each SNI. It does not resolve SNIs like *.example.com, only absolute ones.
CertifiedKeyWatched
A TLS Key / Certificate combination created from files. The files are automatically watched and the internal TLS data will be rebuilt automatically, if a new matching key + cert has been found. This makes any server using rustls capable of hot-reloading certificates without any other modification.
CertifiedKeysWatched
Holds multiple certificate bundles and resolves them depending on the SNI from the ClientHello. Does not dynamically resolve wildcard certificates. You need to add them for each SNI you want to use it with.

Functions§

install_crypto_provider
Checks if the rustls::CryptoProvider is already installed and installs it, if not.
load_server_config
Creates a simple rustls::ServerConfig with automatic hot-reloading of TLS certificates whenever the given key_path / cert_path are updated.