pub unsafe extern "C" fn s2n_config_set_verify_host_callback(
    config: *mut s2n_config,
    arg1: s2n_verify_host_fn,
    data: *mut c_void
) -> c_int
Expand description

Sets the callback to use for verifying that a hostname from an X.509 certificate is trusted.

The default behavior is to require that the hostname match the server name set with s2n_set_server_name(). This will likely lead to all client certificates being rejected, so the callback will need to be overriden when using client authentication.

This change will be inherited by s2n_connections using this config. If a separate callback for different connections using the same config is desired, see s2n_connection_set_verify_host_callback().

@param config The configuration object being updated @param data A user supplied opaque context to pass back to the callback @returns S2N_SUCCESS on success. S2N_FAILURE on failure