Commit d140d3c4 authored by Paul Querna's avatar Paul Querna
Browse files

This will put some messages in the error log when some people try a lame

DoS by just opening a socket, and never sending any data.

Ivan suggested such a change about a month ago, to match the 1.3 behavoir.

Today I helped OSU's Admins figure out that someone was trying this 'attack'
against their mirror server.  The server status just showed hundreds of
Apache Children stuck in Reading.  This will at least hint to the admins
where the problem is by telling them about it in the error log.

Inspired by: Rici Lake, Ivan Ristic <ivanr webkreator.com>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@105583 13f79535-47bb-0310-9956-ffa450edef68
parent 01a503f9
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -2,6 +2,9 @@ Changes with Apache 2.1.0-dev
  [Remove entries to the current 2.0 section below, when backported]
  *) core: Add a warning message if the request line read fails.
     [Paul Querna]
  *) mod_cache: Add CacheIgnoreHeaders directive.  PR 30399.
     [Rüiger Plü <r.pluem t-online.de>]
+4 −1
Original line number Diff line number Diff line
@@ -603,7 +603,10 @@ static int read_request_line(request_rec *r, apr_bucket_brigade *bb)
                r->proto_num = HTTP_VERSION(1,0);
                r->protocol  = apr_pstrdup(r->pool, "HTTP/1.0");
            }

            else if (r->connection->keepalive != AP_CONN_KEEPALIVE) {
                ap_log_rerror(APLOG_MARK, APLOG_NOTICE, rv, r,
                              "request line read error.");
            }
            return 0;
        }
    } while ((len <= 0) && (++num_blank_lines < max_blank_lines));