Function s2n_tls_sys::s2n_recv_early_data
source · pub unsafe extern "C" fn s2n_recv_early_data(
conn: *mut s2n_connection,
data: *mut u8,
max_data_len: isize,
data_received: *mut isize,
blocked: *mut Type
) -> c_int
Expand description
Called by the server to begin negotiation and accept any early data the client sends.
See https://github.com/aws/s2n-tls/blob/main/docs/usage-guide/topics/ch14-early-data.md for usage and examples. DO NOT USE unless you have considered the security issues and implemented mitigation for anti-replay attacks.
@param conn A pointer to the connection
@param data A pointer to a buffer to store the early data received
@param max_data_len The size of the early data buffer
@param data_received A pointer which will be set to the size of the early data received
@param blocked A pointer which will be set to the blocked status, as in s2n_negotiate
.
@returns A POSIX error signal. The error should be handled as in s2n_negotiate
.