Apache: maximum limit of QUERY_STRING?

Apache: maximum limit of QUERY_STRING?

Post by Neil Lauran » Wed, 05 Dec 2001 01:20:18



Hi there. I am seeking clarification of the limit of QUERY_STRING with
Apache. I have a requirement to provide all the information needed to
generate a customer report within a URL. This requires that I use a
GET method of the form:

http://host:port/cgi/some.cgi?<QUERY_STRING>

Now my QUERY_STRING can be quite large. I wish to know the definitive
maximum size of this string. The only limit I found that may relate to
QUERY_STRING in the source code was:

bindist/include/httpd.h:#define DEFAULT_LIMIT_REQUEST_LINE 8190

Which is the compiled default for 'r->server->limit_req_line' in:

src/main/http_protocol.c:static int read_request_line(request_rec *r)

From what I understand, the reuqest line contains the Method, full
URI, and HTTP version. So the QUERY_STRING must be some value less
than 8190. I am surprised there is no exact limit on QUERY_STRING.

Can someone confirm my suspicions, and perhaps tell me if there is any
way to override this limit.

Thanks in advance, Neil

 
 
 

Apache: maximum limit of QUERY_STRING?

Post by Joshua Sliv » Wed, 05 Dec 2001 01:32:03



> Hi there. I am seeking clarification of the limit of QUERY_STRING with
> Apache. I have a requirement to provide all the information needed to
> generate a customer report within a URL. This requires that I use a
> GET method of the form:
> http://host:port/cgi/some.cgi?<QUERY_STRING>
> Now my QUERY_STRING can be quite large. I wish to know the definitive
> maximum size of this string. The only limit I found that may relate to
> QUERY_STRING in the source code was:
> bindist/include/httpd.h:#define DEFAULT_LIMIT_REQUEST_LINE 8190

You can certainly increase this compiled-in constant.  But I think you
will find that the limiting factor is the browser.  Many browsers will
not deal with very long query strings.  For example, the following
document suggests that MSIE is limited to 2k:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;q254786

--
Joshua Slive

Apache HTTP Server Users Mailing List: http://httpd.apache.org/userslist.html

 
 
 

1. Apache-Server and QUERY_STRINGs

Hallo,

i installed the Server Apache/1.3b3 on my Windows95-Machine and it works
well with the most Perl-Scripts always get an "500 Internal Server
Error" when submitting a Get-request to a Perl-Script with a
QUERY_STRING like:

http://127.0.0.1/cgi-bin/apache.pl?showconfig

There is no entry in the Servers error.log responding do this "Internal
Server Error"!

I have *no* trouble with QUERY_STRINGs like:

http://127.0.0.1/cgi-bin/apache.pl?=

or

http://127.0.0.1/cgi-bin/apache.pl?action=showconfig

My question(s):

Does anybody know, why the Apache-Server only accepts QUERY_STRINGs
which at least contain one = character (name=value)

  or

how do i have to configure the servers config-files to change this
behavior when submitting QUERY_STRINGs with only?

Thank you for any information or help

Reiner Bergs

--
--------------------------------------

 http://www.snafu.de/~bergs/index.html
--------------------------------------

2. howto setup dual wan uplink on linux box

3. Apache and $QUERY_STRING

4. New Solaris 8 Install on Sparc 20

5. How to parse a Query_String in Apache

6. Odd behavior from backup.

7. SMP motherboards (760 MPX chipset) and SMP howto

8. mod_negotiation, QUERY_STRING and Apache 1.3.22

9. Apache Truncated QUERY_STRING

10. Limit maximum TCP connections for NAT connection

11. Linux maximum O/S limits????

12. maximum filesystem size limit