Add Bounded Ordinary HTTPS Idle Cleanup

This commit is contained in:
2026-09-08 18:33:33 +02:00
parent f6263042ff
commit 82f21d6116
18 changed files with 884 additions and 13 deletions
+7 -2
View File
@@ -31,13 +31,18 @@ HEADERS["esp_idf_version.h"] = """
#define ESP_IDF_VERSION ESP_IDF_VERSION_VAL(5,5,0)
"""
HEADERS["esp_httpd_priv.h"] = """#pragma once
#include <stdint.h>
#include "esp_http_server.h"
struct sock_db { bool ws_handshake_done; esp_err_t (*ws_handler)(httpd_req_t *);
static inline void *httpd_os_thread_handle(void) { return (void *)1; }
struct sock_db { int fd; bool for_async_req, ws_close; uint64_t lru_counter;
int (*pending_fn)(httpd_handle_t, int);
bool ws_handshake_done; esp_err_t (*ws_handler)(httpd_req_t *);
bool ws_control_frames; void *ws_user_ctx; char pending_data[128]; size_t pending_len; };
struct httpd_req_aux { struct sock_db *sd; char *scratch; size_t scratch_cur_size, remaining_len;
unsigned req_hdrs_count, resp_hdrs_count; bool ws_handshake_detect;
struct resp_hdr { const char *field, *value; } *resp_hdrs; };
struct httpd_data { struct { unsigned max_resp_headers, max_uri_handlers; void *uri_match_fn; } config;
struct httpd_data { struct { unsigned max_resp_headers, max_uri_handlers, max_open_sockets; void *uri_match_fn; } config;
struct { void *handle; } hd_td; struct httpd_req_aux hd_req_aux; struct sock_db *hd_sd;
httpd_uri_t **hd_calls; };
esp_err_t httpd_ws_respond_server_handshake(httpd_req_t *, const char *);
"""