lwIP 2.2.1
Lightweight IP stack
Loading...
Searching...
No Matches
httpd.c File Reference
#include "lwip/init.h"
#include "lwip/apps/httpd.h"
#include "lwip/debug.h"
#include "lwip/stats.h"
#include "lwip/apps/fs.h"
#include "httpd_structs.h"
#include "lwip/def.h"
#include "lwip/altcp.h"
#include "lwip/altcp_tcp.h"
#include "lwip/altcp_tls.h"
#include "path/to/my/lwip_hooks.h"
#include <string.h>
#include <stdlib.h>
#include <stdio.h>

Macros

#define MIN_REQ_LEN   7
#define HTTP_IS_DATA_VOLATILE(hs)
#define HTTP_IS_HDR_VOLATILE(hs, ptr)

Functions

void httpd_post_data_recved (void *connection, u16_t recved_len)
void httpd_init (void)
void httpd_inits (struct altcp_tls_config *conf)
void http_set_ssi_handler (tSSIHandler ssi_handler, const char **tags, int num_tags)
void http_set_cgi_handlers (const tCGI *cgis, int num_handlers)

Detailed Description

LWIP HTTP server implementation

Macro Definition Documentation

◆ HTTP_IS_DATA_VOLATILE

#define HTTP_IS_DATA_VOLATILE ( hs)
Value:
(HTTP_IS_DYNAMIC_FILE(hs) ? TCP_WRITE_FLAG_COPY : 0)

tcp_write does not have to copy data when sent from rom-file-system directly

◆ HTTP_IS_HDR_VOLATILE

#define HTTP_IS_HDR_VOLATILE ( hs,
ptr )
Value:
0

Default: dynamic headers are sent from ROM (non-dynamic headers are handled like file data)

◆ MIN_REQ_LEN

#define MIN_REQ_LEN   7

Minimum length for a valid HTTP/0.9 request: "GET /\r\n" -> 7 bytes