HTTP parser: allowing underscore in header field names.

This commit is contained in:
Valentin Bartenev
2018-01-09 16:50:47 +03:00
parent c85c9dc7a8
commit e8aada94de
2 changed files with 2 additions and 2 deletions

View File

@@ -509,7 +509,7 @@ nxt_http_parse_field_name(nxt_http_request_parse_t *rp, u_char **pos,
"\0\0\0\0\0\0\0\0\0\0\0\0\0-\0\0" "0123456789\0\0\0\0\0\0" "\0\0\0\0\0\0\0\0\0\0\0\0\0-\0\0" "0123456789\0\0\0\0\0\0"
/* These 64 bytes should reside in one cache line. */ /* These 64 bytes should reside in one cache line. */
"\0abcdefghijklmnopqrstuvwxyz\0\0\0\0\0" "\0abcdefghijklmnopqrstuvwxyz\0\0\0\0_"
"\0abcdefghijklmnopqrstuvwxyz\0\0\0\0\0" "\0abcdefghijklmnopqrstuvwxyz\0\0\0\0\0"
"\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0" "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"

View File

@@ -242,7 +242,7 @@ static nxt_http_parse_test_case_t nxt_http_test_cases[] = {
{ {
nxt_string("GET / HTTP/1.1\r\n" nxt_string("GET / HTTP/1.1\r\n"
"Ho_st: example.com\r\n\r\n"), "Ho_st: example.com\r\n\r\n"),
NXT_ERROR, NXT_DONE,
NULL, { NULL } NULL, { NULL }
}, },
{ {