2 <!DOCTYPE modulesynopsis SYSTEM "../style/modulesynopsis.dtd">
3 <?xml-stylesheet type="text/xsl" href="../style/manual.en.xsl"?>
4 <!-- $LastChangedRevision: 1 $ -->
7 Licensed to the Apache Software Foundation (ASF) under one or more
8 contributor license agreements. See the NOTICE file distributed with
9 this work for additional information regarding copyright ownership.
10 The ASF licenses this file to You under the Apache License, Version 2.0
11 (the "License"); you may not use this file except in compliance with
12 the License. You may obtain a copy of the License at
14 http://www.apache.org/licenses/LICENSE-2.0
16 Unless required by applicable law or agreed to in writing, software
17 distributed under the License is distributed on an "AS IS" BASIS,
18 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 See the License for the specific language governing permissions and
20 limitations under the License.
23 <modulesynopsis metafile="mod_reqtimeout.xml.meta">
25 <name>mod_reqtimeout</name>
26 <description>Set timeout and minimum data rate for receiving requests
28 <status>Experimental</status>
29 <sourcefile>mod_reqtimeout.c</sourcefile>
30 <identifier>reqtimeout_module</identifier>
31 <compatibility>Available in Apache 2.3 and later</compatibility>
33 <section id="examples"><title>Examples</title>
37 Allow 10 seconds to receive the request including the headers and
38 30 seconds for receiving the request body:
41 ReqTimeout headerinit=10 bodyinit=30
46 Allow at least 10 seconds to receive the request including the headers.
47 If the client sends data, increase the timeout by 1 second for every
48 500 bytes received. But do not allow more than 30 seconds for the
49 request including the headers:
52 ReqTimeout headerinit=10 headerminrate=500 headermax=30
57 Allow at least 10 seconds to receive the request body.
58 If the client sends data, increase the timeout by 1 second for every
59 1000 bytes received, with no upper limit for the timeout (exept for
60 the limit given indirectly by
61 <directive module="core">LimitRequestBody</directive>):
64 ReqTimeout bodyinit=10 bodyminrate=1000
72 <name>ReqTimeout</name>
73 <description>Set timeout values for receiving request headers and body from client.
76 [headerinit=<var>time</var>
77 [headerminrate=<var>rate</var> [headermax=<var>time</var>]]]
78 [bodyinit=<var>time</var>
79 [bodyminrate=<var>rate</var> [bodymax=<var>time</var>]]]
81 <default>Unset; all values 0</default>
82 <contextlist><context>server config</context><context>virtual host</context>
86 <p>This directive can set various timeouts for receiving the request headers
87 and the request body from the client. If the client fails to send headers or
88 body within the configured time, a <code>408 REQUEST TIME OUT</code> error
91 <p>For SSL virtual hosts, the header timeout values include the time needed
92 to do the initial SSL handshake. The body timeout values include the time
93 needed for SSL renegotiation (if necessary).</p>
95 <p>When an <directive module="core">AcceptFilter</directive> is in use
96 (usually the case on Linux and FreeBSD), the socket is not sent to the
97 server process before at least one byte (or the whole request for
98 <code>httpready</code>) is received. The header timeout configured with
99 <code>ReqTimeout</code> is only effective after the server process has
100 received the socket.</p>
104 <dt><code>headerinit</code></dt>
105 <dd>The initial timeout for receiving the request headers in seconds.
106 Also the timout for receiving the first byte of the request. If
107 <code>headerminrate</code> is not set, the request line and all headers
108 must be received within this time.</dd>
110 <dt><code>headerminrate</code></dt>
111 <dd>The minumum data rate for receiving the request headers in
112 bytes/second. Whenever data is received, the timeout is increased
113 according to this data rate.</dd>
115 <dt><code>headermax</code></dt>
116 <dd>The maximum timeout for receiving the request headers in seconds.
117 The timeout cannot be increased above this value by
118 <code>headerminrate</code>.</dd>
120 <dt><code>bodyinit</code></dt>
121 <dd>The initial timeout for receiving the request body in seconds.
122 Also the timout for receiving the first byte of the request body. If
123 <code>bodyminrate</code> is not set, the complete request body must be
124 received within this time.</dd>
126 <dt><code>bodyminrate</code></dt>
127 <dd>The minumum data rate for receiving the request body in
128 bytes/second. Whenever data is received, the timeout is increased
129 according to this data rate.</dd>
131 <dt><code>bodymax</code></dt>
132 <dd>The maximum timeout for receiving the request body in seconds.
133 The timeout cannot be increased above this value by
134 <code>bodyminrate</code></dd>