We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent7fff893 commit2e9ea0aCopy full SHA for 2e9ea0a
apache2/msc_reqbody.c
@@ -435,7 +435,7 @@ apr_status_t modsecurity_request_body_to_stream(modsec_rec *msr, const char *buf
435
// Is the request body length known beforehand? (requests that are not Transfer-Encoding: chunked)
436
if (msr->request_content_length>0) {
437
// Use min of Content-Length and SecRequestBodyLimit
438
-allocate_length=min(msr->request_content_length,msr->txcfg->reqbody_limit);
+allocate_length=msr->request_content_length<msr->txcfg->reqbody_limit ?msr->request_content_length :msr->txcfg->reqbody_limit;
439
}
440
else {
441
// We don't know how this request is going to be, so hope for just buflen to begin with (requests that are Transfer-Encoding: chunked)