From: Christian Hofstaedtler Date: Tue, 4 Mar 2014 13:23:26 +0000 (+0100) Subject: HTTP server: fix requests that are larger than 1024bytes X-Git-Tag: rec-3.6.0-rc1~151^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F1315%2Fhead;p=thirdparty%2Fpdns.git HTTP server: fix requests that are larger than 1024bytes --- diff --git a/pdns/ext/yahttp/yahttp/reqresp.cpp b/pdns/ext/yahttp/yahttp/reqresp.cpp index 03d59c149b..f9b4d24c6a 100644 --- a/pdns/ext/yahttp/yahttp/reqresp.cpp +++ b/pdns/ext/yahttp/yahttp/reqresp.cpp @@ -222,6 +222,10 @@ namespace YaHTTP { if (chunk_size!=0) return false; // need more data + if (!chunked && bodybuf.str().size() < maxbody) { + return false; // need more data + } + bodybuf.flush(); request->body = bodybuf.str(); bodybuf.str("");