Rework extraction of HTTP headers (#2183)
Extract only the headers that we really need/use. Avoid too many `strcmp`; the algorithm might be a little bit overwhelming right now but it might be useful if we have further headers in the future.
This commit is contained in:
@@ -94,17 +94,11 @@ struct ndpi_packet_struct {
|
||||
struct ndpi_int_one_line_struct authorization_line;
|
||||
struct ndpi_int_one_line_struct user_agent_line;
|
||||
struct ndpi_int_one_line_struct http_url_name;
|
||||
struct ndpi_int_one_line_struct http_encoding;
|
||||
struct ndpi_int_one_line_struct http_transfer_encoding;
|
||||
struct ndpi_int_one_line_struct http_contentlen;
|
||||
struct ndpi_int_one_line_struct http_cookie;
|
||||
struct ndpi_int_one_line_struct http_origin;
|
||||
struct ndpi_int_one_line_struct http_x_session_type;
|
||||
struct ndpi_int_one_line_struct server_line;
|
||||
struct ndpi_int_one_line_struct http_method;
|
||||
struct ndpi_int_one_line_struct http_response; /* the first "word" in this pointer is the
|
||||
response code in the packet (200, etc) */
|
||||
u_int8_t http_num_headers; /* number of found (valid) header lines in HTTP request or response */
|
||||
|
||||
u_int16_t l3_packet_len;
|
||||
u_int16_t payload_packet_len;
|
||||
|
||||
Reference in New Issue
Block a user