Module rustls_ffi::cipher
source · Structs
- A builder for a
rustls_allow_any_anonymous_or_authenticated_client_verifier
. This builder object can be used to configure certificate revocation lists, and then turned into arustls_allow_any_anonymous_or_authenticated_client_verifier
once ready. - Alternative to
rustls_allow_any_authenticated_client_verifier
that allows connections with or without a client certificate. If the client offers a certificate, it will be verified (and rejected if it is not valid). If the client does not offer a certificate, the connection will succeed. - A builder for a
rustls_allow_any_authenticated_client_verifier
. This builder object can be used to configure certificate revocation lists, and then turned into arustls_allow_any_authenticated_client_verifier
once ready. - 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. - An X.509 certificate, as used in rustls. Corresponds to
Certificate
in the Rust API. https://docs.rs/rustls/latest/rustls/struct.Certificate.html - The complete chain of certificates to send during a TLS handshake, plus a private key that matches the end-entity (leaf) certificate. Corresponds to
CertifiedKey
in the Rust API. https://docs.rs/rustls/latest/rustls/sign/struct.CertifiedKey.html - A root certificate store. https://docs.rs/rustls/latest/rustls/struct.RootCertStore.html
- A cipher suite supported by rustls.
Statics
- Rustls’ list of supported cipher suites. This is an array of pointers, and its length is given by
RUSTLS_ALL_CIPHER_SUITES_LEN
. The pointers will always be valid. The contents and order of this array may change between releases. - The length of the array
RUSTLS_ALL_CIPHER_SUITES
. - Rustls’ list of default cipher suites. This is an array of pointers, and its length is given by
RUSTLS_DEFAULT_CIPHER_SUITES_LEN
. The pointers will always be valid. The contents and order of this array may change between releases. - The length of the array
RUSTLS_DEFAULT_CIPHER_SUITES
.
Functions
- Get a pointer to a member of rustls’ list of supported cipher suites. This will return non-NULL for i < rustls_all_ciphersuites_len(). The returned pointer is valid for the lifetime of the program and may be used directly when building a ClientConfig or ServerConfig.
- Return the length of rustls’ list of supported cipher suites.
- Get a pointer to a member of rustls’ list of supported cipher suites. This will return non-NULL for i < rustls_default_ciphersuites_len(). The returned pointer is valid for the lifetime of the program and may be used directly when building a ClientConfig or ServerConfig.
- Return the length of rustls’ list of default cipher suites.
- Returns the name of the ciphersuite as a
rustls_str
. If the provided ciphersuite is invalid, the rustls_str will contain the empty string. The lifetime of therustls_str
is the lifetime of the program, it does not need to be freed.