Custom session opening callback. Called on a new session socket just after accept(), but before reading any data. This is an opportunity to set up e.g. SSL encryption using global_transport_ctx and the send/recv/pending session overrides. If a context needs to be maintained between these functions, store it in the session using httpd_sess_set_transport_ctx() and retrieve it later with httpd_sess_get_transport_ctx() Returning a value other than ESP_OK will immediately close the new socket.