maps, via atol, to a negative number.
PR:
Obtained from:
Submitted by:
Reviewed by:
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x@95733
13f79535-47bb-0310-9956-
ffa450edef68
}
r->remaining = atol(lenp);
+ if (r->remaining < 0) {
+ ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, r,
+ "Request content-length of %s maps to negative number %ld",
+ lenp, r->remaining);
+ return HTTP_BAD_REQUEST;
+ }
}
if ((r->read_body == REQUEST_NO_BODY) &&