Struct rustls_ffi::cipher::rustls_client_cert_verifier
source · pub struct rustls_client_cert_verifier { /* private fields */ }
Expand description
A verifier of client certificates that requires all certificates to be
trusted based on a given rustls_root_cert_store
. Usable in building server
configurations. Connections without such a client certificate will not
be accepted.
Implementations§
source§impl rustls_client_cert_verifier
impl rustls_client_cert_verifier
source#[no_mangle]pub extern "C" fn rustls_client_cert_verifier_new(
store: *const rustls_root_cert_store
) -> *const rustls_client_cert_verifier
#[no_mangle]pub extern "C" fn rustls_client_cert_verifier_new(
store: *const rustls_root_cert_store
) -> *const rustls_client_cert_verifier
Create a new client certificate verifier for the root store. The verifier can be used in several rustls_server_config instances. Must be freed by the application when no longer needed. See the documentation of rustls_client_cert_verifier_free for details about lifetime. This copies the contents of the rustls_root_cert_store. It does not take ownership of the pointed-to memory.
source#[no_mangle]pub extern "C" fn rustls_client_cert_verifier_free(
verifier: *const rustls_client_cert_verifier
)
#[no_mangle]pub extern "C" fn rustls_client_cert_verifier_free(
verifier: *const rustls_client_cert_verifier
)
“Free” a verifier previously returned from rustls_client_cert_verifier_new. Since rustls_client_cert_verifier is actually an atomically reference-counted pointer, extant server_configs may still hold an internal reference to the Rust object. However, C code must consider this pointer unusable after “free“ing it. Calling with NULL is fine. Must not be called twice with the same value.