summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn Strauss <gstrauss@gluelogic.com>2019-02-10 18:19:34 -0500
committerGlenn Strauss <gstrauss@gluelogic.com>2019-02-10 20:47:19 -0500
commit9948537721a5d50bd3ab6b1fd072522173d9f530 (patch)
tree2d2e063abd89f74b7950eb2b8c1bf6704a56e1fc
parentb2c18f480d1d69192991cc334298ec1f7e1039b7 (diff)
downloadlighttpd1.4-9948537721a5d50bd3ab6b1fd072522173d9f530.tar.gz
lighttpd1.4-9948537721a5d50bd3ab6b1fd072522173d9f530.zip
[core] discard oversized trailers
x-ref: "PVS-Studio Analysis Results" https://redmine.lighttpd.net/boards/3/topics/8459 http://www.fly-server.ru/pvs-studio/lighttpd/
-rw-r--r--src/connections-glue.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/connections-glue.c b/src/connections-glue.c
index 7d8a9e04..e1657966 100644
--- a/src/connections-glue.c
+++ b/src/connections-glue.c
@@ -190,6 +190,7 @@ static handler_t connection_handle_read_post_chunked(server *srv, connection *co
/* ignore excessively long trailers;
* disable keep-alive on connection */
con->keep_alive = 0;
+ p = c->mem->ptr + buffer_string_length(c->mem) - 4;
}
}
hsz = p + 4 - (c->mem->ptr+c->offset);