httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 47178] New: ab segfaults when called with a large -n parameter
Date Sun, 10 May 2009 21:59:01 GMT

           Summary: ab segfaults when called with a large -n parameter
           Product: Apache httpd-2
           Version: 2.3-HEAD
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: support

Created an attachment (id=23637)
 --> (
Patch adding a check of the result of the allocation of stats

Calling ab (the Apache benchmark utility) with the argument -n 1234567890 (or any -n other value smaller than MAXINT, but bigger than
the virtual memory divided by 32) causes ab to segfault. This is a result of
using a dynamically allocated data structure(line ~1260) whose allocation(line
1559) is not checked. The size of this data structure is linearly dependent of
the -n value. This may be a design bug in itself since it prevents ab runs with
a potentially infinite number of requests, e.g. to test how many requests can
be served in 42 seconds. The attached patch makes ab exit properly when the
memory allocation fails.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message