From 571bdda9070b0cf4a2eea28a7fa64460358036da Mon Sep 17 00:00:00 2001 From: "Evgeny Grin (Karlson2k)" Date: Sun, 1 Aug 2021 15:33:31 +0300 Subject: [PATCH] response headers: disallow space in header name, allow tab in header value --- src/microhttpd/response.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/microhttpd/response.c b/src/microhttpd/response.c index fbe621c4..a7085767 100644 --- a/src/microhttpd/response.c +++ b/src/microhttpd/response.c @@ -167,9 +167,9 @@ add_response_entry (struct MHD_Response *response, (0 == header[0]) || (0 == content[0]) || (NULL != strchr (header, '\t')) || + (NULL != strchr (header, ' ')) || (NULL != strchr (header, '\r')) || (NULL != strchr (header, '\n')) || - (NULL != strchr (content, '\t')) || (NULL != strchr (content, '\r')) || (NULL != strchr (content, '\n')) ) return MHD_NO;