Skip to main content

esp_tls_server_session_init

Function esp_tls_server_session_init 

Source
pub unsafe extern "C" fn esp_tls_server_session_init(
    cfg: *mut esp_tls_cfg_server_t,
    sockfd: c_int,
    tls: *mut esp_tls_t,
) -> esp_err_t
Expand description

@brief Initialize server side TLS/SSL connection

This function should be used to initialize the server side TLS/SSL connection when the application wants to handle the TLS/SSL connection asynchronously with the help of esp_tls_server_session_continue_async() function.

@param[in] cfg Pointer to esp_tls_cfg_server_t @param[in] sockfd FD of accepted connection @param[out] tls Pointer to allocated esp_tls_t

@return - ESP_OK if successful - ESP_ERR_INVALID_ARG if invalid arguments - ESP_FAIL if server session setup failed