I'm having a problem with Request
Entity Too Large when posting large data via AJAX to a Php program.
I don't think mod_security is
installed or enabled as there is no /etc/modsecurity folder and i can't find anything
with the name when searching the server for
files.
The domain is running on a virtual host
in ssl.conf and all works fine except this issue with posting large amounts of
data.
The strange thing is, i also have the same
server setup on a local development virtual machine also running on SSL over a self
signed certificate and the problem doesn't happen on the local machine; it's just the
live dedicated server where the problem is.
It may be
many things, but you have this LimitRequestBody
directive in
Apache which is defined as
such:
This directive specifies the number of bytes from 0 (meaning unlimited) to
2147483647 (2GB) that are allowed in a request body. See the note below for the limited
applicability to proxy requests.
The
LimitRequestBody directive allows the user to set a limit on the allowed size of an HTTP
request message body within the context in which the directive is given (server,
per-directory, per-file or per-location). If the client request exceeds that limit, the
server will return an error response instead of servicing the request. The size of a
normal request message body will vary greatly depending on the nature of the resource
and the methods allowed on that resource. CGI scripts typically use the message body for
retrieving form information. Implementations of the PUT method will require a value at
least as large as any representation that the server wishes to accept for that
resource.
While
the Apache default is 0
(no limit), your own installation may
have a different value.
You have also other
directives that limit things like that (see all starting with
Limit
on href="https://httpd.apache.org/docs/2.4/mod/core.html" rel="nofollow
noreferrer">https://httpd.apache.org/docs/2.4/mod/core.html), including
header lengths and contents.
You will need to
have a closer look at your Apache configuration. You can also increase verbosity and you
should then have more details in your logfiles.
Comments
Post a Comment