pub struct rustls_server_config { /* private fields */ }Expand description
A server config that is done being constructed and is now read-only.
Under the hood, this object corresponds to an Arc<ServerConfig>.
https://docs.rs/rustls/latest/rustls/struct.ServerConfig.html
Implementations§
Source§impl rustls_server_config
impl rustls_server_config
Source#[unsafe(no_mangle)]pub extern "C" fn rustls_server_config_fips(
config: *const rustls_server_config,
) -> bool
#[unsafe(no_mangle)]pub extern "C" fn rustls_server_config_fips(
config: *const rustls_server_config,
) -> bool
Returns true if a rustls_connection created from the rustls_server_config will
operate in FIPS mode.
This is different from rustls_crypto_provider_fips which is concerned
only with cryptography, whereas this also covers TLS-level configuration that NIST
recommends, as well as ECH HPKE suites if applicable.
Source#[unsafe(no_mangle)]pub extern "C" fn rustls_server_config_free(
config: *const rustls_server_config,
)
#[unsafe(no_mangle)]pub extern "C" fn rustls_server_config_free(
config: *const rustls_server_config,
)
“Free” a rustls_server_config previously returned from rustls_server_config_builder_build.
Since rustls_server_config is actually an atomically reference-counted pointer, extant server connections 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.
Source#[unsafe(no_mangle)]pub extern "C" fn rustls_server_connection_new(
config: *const rustls_server_config,
conn_out: *mut *mut rustls_connection,
) -> rustls_result
#[unsafe(no_mangle)]pub extern "C" fn rustls_server_connection_new(
config: *const rustls_server_config,
conn_out: *mut *mut rustls_connection,
) -> rustls_result
Create a new rustls_connection containing a server connection, and return it.
It is returned in the output parameter conn_out.
If this returns an error code, the memory pointed to by conn_out remains unchanged.
If this returns a non-error, the memory pointed to by conn_out is modified to point
at a valid rustls_connection
The caller now owns the rustls_connection and must call rustls_connection_free when
done with it.