]> granicus.if.org Git - apache/blob - docs/manual/mod/core.html.en
0b0e88263733bce2c98a7532590f6f18c4b9c582
[apache] / docs / manual / mod / core.html.en
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
4         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
5               This file is generated from xml source: DO NOT EDIT
6         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
7       -->
8 <title>core - Apache HTTP Server</title>
9 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
10 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
11 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
12 <link href="../images/favicon.ico" rel="shortcut icon" /></head>
13 <body>
14 <div id="page-header">
15 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
16 <p class="apache">Apache HTTP Server Version 2.3</p>
17 <img alt="" src="../images/feather.gif" /></div>
18 <div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
19 <div id="path">
20 <a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP Server</a> &gt; <a href="http://httpd.apache.org/docs/">Documentation</a> &gt; <a href="../">Version 2.3</a> &gt; <a href="./">Modules</a></div>
21 <div id="page-content">
22 <div id="preamble"><h1>Apache Core Features</h1>
23 <div class="toplang">
24 <p><span>Available Languages: </span><a href="../de/mod/core.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
25 <a href="../en/mod/core.html" title="English">&nbsp;en&nbsp;</a> |
26 <a href="../ja/mod/core.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
27 <a href="../tr/mod/core.html" hreflang="tr" rel="alternate" title="Türkçe">&nbsp;tr&nbsp;</a></p>
28 </div>
29 <table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Core Apache HTTP Server features that are always
30 available</td></tr>
31 <tr><th><a href="module-dict.html#Status">Status:</a></th><td>Core</td></tr></table>
32 </div>
33 <div id="quickview"><h3 class="directives">Directives</h3>
34 <ul id="toc">
35 <li><img alt="" src="../images/down.gif" /> <a href="#acceptfilter">AcceptFilter</a></li>
36 <li><img alt="" src="../images/down.gif" /> <a href="#acceptpathinfo">AcceptPathInfo</a></li>
37 <li><img alt="" src="../images/down.gif" /> <a href="#accessfilename">AccessFileName</a></li>
38 <li><img alt="" src="../images/down.gif" /> <a href="#adddefaultcharset">AddDefaultCharset</a></li>
39 <li><img alt="" src="../images/down.gif" /> <a href="#addoutputfilterbytype">AddOutputFilterByType</a></li>
40 <li><img alt="" src="../images/down.gif" /> <a href="#allowencodedslashes">AllowEncodedSlashes</a></li>
41 <li><img alt="" src="../images/down.gif" /> <a href="#allowoverride">AllowOverride</a></li>
42 <li><img alt="" src="../images/down.gif" /> <a href="#cgimapextension">CGIMapExtension</a></li>
43 <li><img alt="" src="../images/down.gif" /> <a href="#contentdigest">ContentDigest</a></li>
44 <li><img alt="" src="../images/down.gif" /> <a href="#defaulttype">DefaultType</a></li>
45 <li><img alt="" src="../images/down.gif" /> <a href="#define">Define</a></li>
46 <li><img alt="" src="../images/down.gif" /> <a href="#directory">&lt;Directory&gt;</a></li>
47 <li><img alt="" src="../images/down.gif" /> <a href="#directorymatch">&lt;DirectoryMatch&gt;</a></li>
48 <li><img alt="" src="../images/down.gif" /> <a href="#documentroot">DocumentRoot</a></li>
49 <li><img alt="" src="../images/down.gif" /> <a href="#enablemmap">EnableMMAP</a></li>
50 <li><img alt="" src="../images/down.gif" /> <a href="#enablesendfile">EnableSendfile</a></li>
51 <li><img alt="" src="../images/down.gif" /> <a href="#errordocument">ErrorDocument</a></li>
52 <li><img alt="" src="../images/down.gif" /> <a href="#errorlog">ErrorLog</a></li>
53 <li><img alt="" src="../images/down.gif" /> <a href="#fileetag">FileETag</a></li>
54 <li><img alt="" src="../images/down.gif" /> <a href="#files">&lt;Files&gt;</a></li>
55 <li><img alt="" src="../images/down.gif" /> <a href="#filesmatch">&lt;FilesMatch&gt;</a></li>
56 <li><img alt="" src="../images/down.gif" /> <a href="#forcetype">ForceType</a></li>
57 <li><img alt="" src="../images/down.gif" /> <a href="#hostnamelookups">HostnameLookups</a></li>
58 <li><img alt="" src="../images/down.gif" /> <a href="#if">&lt;If&gt;</a></li>
59 <li><img alt="" src="../images/down.gif" /> <a href="#ifdefine">&lt;IfDefine&gt;</a></li>
60 <li><img alt="" src="../images/down.gif" /> <a href="#ifmodule">&lt;IfModule&gt;</a></li>
61 <li><img alt="" src="../images/down.gif" /> <a href="#include">Include</a></li>
62 <li><img alt="" src="../images/down.gif" /> <a href="#keepalive">KeepAlive</a></li>
63 <li><img alt="" src="../images/down.gif" /> <a href="#keepalivetimeout">KeepAliveTimeout</a></li>
64 <li><img alt="" src="../images/down.gif" /> <a href="#limit">&lt;Limit&gt;</a></li>
65 <li><img alt="" src="../images/down.gif" /> <a href="#limitexcept">&lt;LimitExcept&gt;</a></li>
66 <li><img alt="" src="../images/down.gif" /> <a href="#limitinternalrecursion">LimitInternalRecursion</a></li>
67 <li><img alt="" src="../images/down.gif" /> <a href="#limitrequestbody">LimitRequestBody</a></li>
68 <li><img alt="" src="../images/down.gif" /> <a href="#limitrequestfields">LimitRequestFields</a></li>
69 <li><img alt="" src="../images/down.gif" /> <a href="#limitrequestfieldsize">LimitRequestFieldSize</a></li>
70 <li><img alt="" src="../images/down.gif" /> <a href="#limitrequestline">LimitRequestLine</a></li>
71 <li><img alt="" src="../images/down.gif" /> <a href="#limitxmlrequestbody">LimitXMLRequestBody</a></li>
72 <li><img alt="" src="../images/down.gif" /> <a href="#location">&lt;Location&gt;</a></li>
73 <li><img alt="" src="../images/down.gif" /> <a href="#locationmatch">&lt;LocationMatch&gt;</a></li>
74 <li><img alt="" src="../images/down.gif" /> <a href="#loglevel">LogLevel</a></li>
75 <li><img alt="" src="../images/down.gif" /> <a href="#maxkeepaliverequests">MaxKeepAliveRequests</a></li>
76 <li><img alt="" src="../images/down.gif" /> <a href="#namevirtualhost">NameVirtualHost</a></li>
77 <li><img alt="" src="../images/down.gif" /> <a href="#options">Options</a></li>
78 <li><img alt="" src="../images/down.gif" /> <a href="#rlimitcpu">RLimitCPU</a></li>
79 <li><img alt="" src="../images/down.gif" /> <a href="#rlimitmem">RLimitMEM</a></li>
80 <li><img alt="" src="../images/down.gif" /> <a href="#rlimitnproc">RLimitNPROC</a></li>
81 <li><img alt="" src="../images/down.gif" /> <a href="#scriptinterpretersource">ScriptInterpreterSource</a></li>
82 <li><img alt="" src="../images/down.gif" /> <a href="#serveradmin">ServerAdmin</a></li>
83 <li><img alt="" src="../images/down.gif" /> <a href="#serveralias">ServerAlias</a></li>
84 <li><img alt="" src="../images/down.gif" /> <a href="#servername">ServerName</a></li>
85 <li><img alt="" src="../images/down.gif" /> <a href="#serverpath">ServerPath</a></li>
86 <li><img alt="" src="../images/down.gif" /> <a href="#serverroot">ServerRoot</a></li>
87 <li><img alt="" src="../images/down.gif" /> <a href="#serversignature">ServerSignature</a></li>
88 <li><img alt="" src="../images/down.gif" /> <a href="#servertokens">ServerTokens</a></li>
89 <li><img alt="" src="../images/down.gif" /> <a href="#sethandler">SetHandler</a></li>
90 <li><img alt="" src="../images/down.gif" /> <a href="#setinputfilter">SetInputFilter</a></li>
91 <li><img alt="" src="../images/down.gif" /> <a href="#setoutputfilter">SetOutputFilter</a></li>
92 <li><img alt="" src="../images/down.gif" /> <a href="#timeout">TimeOut</a></li>
93 <li><img alt="" src="../images/down.gif" /> <a href="#traceenable">TraceEnable</a></li>
94 <li><img alt="" src="../images/down.gif" /> <a href="#usecanonicalname">UseCanonicalName</a></li>
95 <li><img alt="" src="../images/down.gif" /> <a href="#usecanonicalphysicalport">UseCanonicalPhysicalPort</a></li>
96 <li><img alt="" src="../images/down.gif" /> <a href="#virtualhost">&lt;VirtualHost&gt;</a></li>
97 </ul>
98 </div>
99
100 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
101 <div class="directive-section"><h2><a name="AcceptFilter" id="AcceptFilter">AcceptFilter</a> <a name="acceptfilter" id="acceptfilter">Directive</a></h2>
102 <table class="directive">
103 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures optimizations for a Protocol's Listener Sockets</td></tr>
104 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AcceptFilter <var>protocol</var> <var>accept_filter</var></code></td></tr>
105 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
106 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
107 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
108 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.1.5 and later.
109 On Windows from Apache 2.3.3 and later.</td></tr>
110 </table>
111     <p>This directive enables operating system specific optimizations for a 
112        listening socket by the Protocol type. The basic premise is for the 
113        kernel to not send a socket to the server process until either data 
114        is received or an entire HTTP Request is buffered. Only
115        <a href="http://www.freebsd.org/cgi/man.cgi?query=accept_filter&amp;sektion=9">
116        FreeBSD's Accept Filters</a>, Linux's more primitive 
117        <code>TCP_DEFER_ACCEPT</code>, and Windows' optimized AcceptEx()
118        are currently supported.</p>
119
120     <p>Using <code>none</code> for an argument will disable any accept filters 
121        for that protocol.  This is useful for protocols that require a server
122        send data first, such as <code>ftp:</code> or <code>nntp</code>:</p>
123     <div class="example"><p><code>AcceptFilter nntp none</code></p></div>
124
125     <p>The default values on FreeBSD are:</p>
126     <div class="example"><p><code>
127         AcceptFilter http httpready <br />
128         AcceptFilter https dataready
129     </code></p></div>
130     
131     <p>The <code>httpready</code> accept filter buffers entire HTTP requests at
132        the kernel level.  Once an entire request is received, the kernel then 
133        sends it to the server. See the 
134        <a href="http://www.freebsd.org/cgi/man.cgi?query=accf_http&amp;sektion=9">
135        accf_http(9)</a> man page for more details.  Since HTTPS requests are 
136        encrypted only the <a href="http://www.freebsd.org/cgi/man.cgi?query=accf_data&amp;sektion=9">
137        accf_data(9)</a> filter is used.</p>
138
139     <p>The default values on Linux are:</p>
140     <div class="example"><p><code>
141         AcceptFilter http data <br />
142         AcceptFilter https data
143     </code></p></div>
144
145     <p>Linux's <code>TCP_DEFER_ACCEPT</code> does not support buffering http
146        requests.  Any value besides <code>none</code> will enable 
147        <code>TCP_DEFER_ACCEPT</code> on that listener. For more details
148        see the Linux 
149        <a href="http://homepages.cwi.nl/~aeb/linux/man2html/man7/tcp.7.html">
150        tcp(7)</a> man page.</p>
151
152     <p>The default values on Windows are:</p>
153     <div class="example"><p><code>
154         AcceptFilter http data <br />
155         AcceptFilter https data
156     </code></p></div>
157
158     <p>Window's mpm_winnt interprets the AcceptFilter to toggle the AcceptEx()
159        API, and does not support http protocol buffering.  There are two values
160        which utilize the Windows AcceptEx() API and will recycle network
161        sockets between connections.  <code>data</code> waits until data has
162        been transmitted as documented above, and the initial data buffer and
163        network endpoint addresses are all retrieved from the single AcceptEx()
164        invocation.  <code>connect</code> will use the AcceptEx() API, also
165        retrieve the network endpoint addresses, but like <code>none</code>
166        the <code>connect</code> option does not wait for the initial data
167        transmission.</p>
168
169     <p>On Windows, <code>none</code> uses accept() rather than than AcceptEx()
170        and will not recycle sockets between connections.  This is useful for
171        network adapters with broken driver support, as well as some virtual
172        network providers such as vpn drivers, or spam, virus or spyware
173        filters.</p>  
174
175
176 </div>
177 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
178 <div class="directive-section"><h2><a name="AcceptPathInfo" id="AcceptPathInfo">AcceptPathInfo</a> <a name="acceptpathinfo" id="acceptpathinfo">Directive</a></h2>
179 <table class="directive">
180 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Resources accept trailing pathname information</td></tr>
181 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AcceptPathInfo On|Off|Default</code></td></tr>
182 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AcceptPathInfo Default</code></td></tr>
183 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
184 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
185 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
186 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
187 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.30 and later</td></tr>
188 </table>
189
190     <p>This directive controls whether requests that contain trailing
191     pathname information that follows an actual filename (or
192     non-existent file in an existing directory) will be accepted or
193     rejected.  The trailing pathname information can be made
194     available to scripts in the <code>PATH_INFO</code> environment
195     variable.</p>
196
197     <p>For example, assume the location <code>/test/</code> points to
198     a directory that contains only the single file
199     <code>here.html</code>.  Then requests for
200     <code>/test/here.html/more</code> and
201     <code>/test/nothere.html/more</code> both collect
202     <code>/more</code> as <code>PATH_INFO</code>.</p>
203
204     <p>The three possible arguments for the
205     <code class="directive">AcceptPathInfo</code> directive are:</p>
206     <dl>
207     <dt><code>Off</code></dt><dd>A request will only be accepted if it
208     maps to a literal path that exists.  Therefore a request with
209     trailing pathname information after the true filename such as
210     <code>/test/here.html/more</code> in the above example will return
211     a 404 NOT FOUND error.</dd>
212
213     <dt><code>On</code></dt><dd>A request will be accepted if a
214     leading path component maps to a file that exists.  The above
215     example <code>/test/here.html/more</code> will be accepted if
216     <code>/test/here.html</code> maps to a valid file.</dd>
217
218     <dt><code>Default</code></dt><dd>The treatment of requests with
219     trailing pathname information is determined by the <a href="../handler.html">handler</a> responsible for the request.
220     The core handler for normal files defaults to rejecting
221     <code>PATH_INFO</code> requests. Handlers that serve scripts, such as <a href="mod_cgi.html">cgi-script</a> and <a href="mod_isapi.html">isapi-handler</a>, generally accept
222     <code>PATH_INFO</code> by default.</dd>
223     </dl>
224
225     <p>The primary purpose of the <code>AcceptPathInfo</code>
226     directive is to allow you to override the handler's choice of
227     accepting or rejecting <code>PATH_INFO</code>. This override is required,
228     for example, when you use a <a href="../filter.html">filter</a>, such
229     as <a href="mod_include.html">INCLUDES</a>, to generate content
230     based on <code>PATH_INFO</code>.  The core handler would usually reject
231     the request, so you can use the following configuration to enable
232     such a script:</p>
233
234     <div class="example"><p><code>
235       &lt;Files "mypaths.shtml"&gt;<br />
236       <span class="indent">
237         Options +Includes<br />
238         SetOutputFilter INCLUDES<br />
239         AcceptPathInfo On<br />
240       </span>
241       &lt;/Files&gt;
242     </code></p></div>
243
244
245 </div>
246 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
247 <div class="directive-section"><h2><a name="AccessFileName" id="AccessFileName">AccessFileName</a> <a name="accessfilename" id="accessfilename">Directive</a></h2>
248 <table class="directive">
249 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Name of the distributed configuration file</td></tr>
250 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AccessFileName <var>filename</var> [<var>filename</var>] ...</code></td></tr>
251 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AccessFileName .htaccess</code></td></tr>
252 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
253 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
254 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
255 </table>
256     <p>While processing a request the server looks for
257     the first existing configuration file from this list of names in
258     every directory of the path to the document, if distributed
259     configuration files are <a href="#allowoverride">enabled for that
260     directory</a>. For example:</p>
261
262     <div class="example"><p><code>
263       AccessFileName .acl
264     </code></p></div>
265
266     <p>before returning the document
267     <code>/usr/local/web/index.html</code>, the server will read
268     <code>/.acl</code>, <code>/usr/.acl</code>,
269     <code>/usr/local/.acl</code> and <code>/usr/local/web/.acl</code>
270     for directives, unless they have been disabled with</p>
271
272     <div class="example"><p><code>
273       &lt;Directory /&gt;<br />
274       <span class="indent">
275         AllowOverride None<br />
276       </span>
277       &lt;/Directory&gt;
278     </code></p></div>
279
280 <h3>See also</h3>
281 <ul>
282 <li><code class="directive"><a href="#allowoverride">AllowOverride</a></code></li>
283 <li><a href="../configuring.html">Configuration Files</a></li>
284 <li><a href="../howto/htaccess.html">.htaccess Files</a></li>
285 </ul>
286 </div>
287 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
288 <div class="directive-section"><h2><a name="AddDefaultCharset" id="AddDefaultCharset">AddDefaultCharset</a> <a name="adddefaultcharset" id="adddefaultcharset">Directive</a></h2>
289 <table class="directive">
290 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Default charset parameter to be added when a response
291 content-type is <code>text/plain</code> or <code>text/html</code></td></tr>
292 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AddDefaultCharset On|Off|<var>charset</var></code></td></tr>
293 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AddDefaultCharset Off</code></td></tr>
294 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
295 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
296 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
297 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
298 </table>
299     <p>This directive specifies a default value for the media type
300     charset parameter (the name of a character encoding) to be added
301     to a response if and only if the response's content-type is either
302     <code>text/plain</code> or <code>text/html</code>.  This should override
303     any charset specified in the body of the response via a <code>META</code>
304     element, though the exact behavior is often dependent on the user's client
305     configuration. A setting of <code>AddDefaultCharset Off</code>
306     disables this functionality. <code>AddDefaultCharset On</code> enables
307     a default charset of <code>iso-8859-1</code>. Any other value is assumed
308     to be the <var>charset</var> to be used, which should be one of the
309     <a href="http://www.iana.org/assignments/character-sets">IANA registered
310     charset values</a> for use in Internet media types (MIME types).
311     For example:</p>
312
313     <div class="example"><p><code>
314       AddDefaultCharset utf-8
315     </code></p></div>
316
317     <p><code class="directive">AddDefaultCharset</code> should only be used when all
318     of the text resources to which it applies are known to be in that
319     character encoding and it is too inconvenient to label their charset
320     individually. One such example is to add the charset parameter
321     to resources containing generated content, such as legacy CGI
322     scripts, that might be vulnerable to cross-site scripting attacks
323     due to user-provided data being included in the output.  Note, however,
324     that a better solution is to just fix (or delete) those scripts, since
325     setting a default charset does not protect users that have enabled
326     the "auto-detect character encoding" feature on their browser.</p>
327
328 <h3>See also</h3>
329 <ul>
330 <li><code class="directive"><a href="../mod/mod_mime.html#addcharset">AddCharset</a></code></li>
331 </ul>
332 </div>
333 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
334 <div class="directive-section"><h2><a name="AddOutputFilterByType" id="AddOutputFilterByType">AddOutputFilterByType</a> <a name="addoutputfilterbytype" id="addoutputfilterbytype">Directive</a></h2>
335 <table class="directive">
336 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>assigns an output filter to a particular media-type</td></tr>
337 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AddOutputFilterByType <var>filter</var>[;<var>filter</var>...]
338 <var>media-type</var> [<var>media-type</var>] ...</code></td></tr>
339 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
340 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
341 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
342 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
343 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.33 and later; deprecated in Apache 2.1 and later</td></tr>
344 </table>
345     <p>This directive activates a particular output <a href="../filter.html">filter</a> for a request depending on the
346     response <a class="glossarylink" href="../glossary.html#media-type" title="see glossary">media-type</a>.  Because of certain
347     problems discussed below, this directive is deprecated.  The same
348     functionality is available using <code class="module"><a href="../mod/mod_filter.html">mod_filter</a></code>.</p>
349
350     <p>The following example uses the <code>DEFLATE</code> filter, which
351     is provided by <code class="module"><a href="../mod/mod_deflate.html">mod_deflate</a></code>. It will compress all
352     output (either static or dynamic) which is labeled as
353     <code>text/html</code> or <code>text/plain</code> before it is sent
354     to the client.</p>
355
356     <div class="example"><p><code>
357       AddOutputFilterByType DEFLATE text/html text/plain
358     </code></p></div>
359
360     <p>If you want the content to be processed by more than one filter, their
361     names have to be separated by semicolons. It's also possible to use one
362     <code class="directive">AddOutputFilterByType</code> directive for each of
363     these filters.</p>
364
365     <p>The configuration below causes all script output labeled as
366     <code>text/html</code> to be processed at first by the
367     <code>INCLUDES</code> filter and then by the <code>DEFLATE</code>
368     filter.</p>
369
370     <div class="example"><p><code>
371     &lt;Location /cgi-bin/&gt;<br />
372     <span class="indent">
373       Options Includes<br />
374       AddOutputFilterByType INCLUDES;DEFLATE text/html<br />
375     </span>
376     &lt;/Location&gt;
377     </code></p></div>
378
379     <div class="warning"><h3>Note</h3>
380       <p>Enabling filters with <code class="directive">AddOutputFilterByType</code>
381       may fail partially or completely in some cases. For example, no
382       filters are applied if the <a class="glossarylink" href="../glossary.html#media-type" title="see glossary">media-type</a> could not
383       be determined.  If you want to make sure that the filters will be
384       applied, assign the content type to a resource explicitly; for
385       example, with <code class="directive"><a href="../mod/mod_mime.html#addtype">AddType</a></code> or
386       <code class="directive"><a href="#forcetype">ForceType</a></code>. Setting the
387       content type within a (non-nph) CGI script is also safe.</p>
388
389     </div>
390
391 <h3>See also</h3>
392 <ul>
393 <li><code class="directive"><a href="../mod/mod_mime.html#addoutputfilter">AddOutputFilter</a></code></li>
394 <li><code class="directive"><a href="#setoutputfilter">SetOutputFilter</a></code></li>
395 <li><a href="../filter.html">filters</a></li>
396 </ul>
397 </div>
398 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
399 <div class="directive-section"><h2><a name="AllowEncodedSlashes" id="AllowEncodedSlashes">AllowEncodedSlashes</a> <a name="allowencodedslashes" id="allowencodedslashes">Directive</a></h2>
400 <table class="directive">
401 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Determines whether encoded path separators in URLs are allowed to
402 be passed through</td></tr>
403 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AllowEncodedSlashes On|Off</code></td></tr>
404 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AllowEncodedSlashes Off</code></td></tr>
405 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
406 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
407 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
408 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.46 and later</td></tr>
409 </table>
410     <p>The <code class="directive">AllowEncodedSlashes</code> directive allows URLs
411     which contain encoded path separators (<code>%2F</code> for <code>/</code>
412     and additionally <code>%5C</code> for <code>\</code> on according systems)
413     to be used. Normally such URLs are refused with a 404 (Not found) error.</p>
414
415     <p>Turning <code class="directive">AllowEncodedSlashes</code> <code>On</code> is
416     mostly useful when used in conjunction with <code>PATH_INFO</code>.</p>
417
418     <div class="note"><h3>Note</h3>
419       <p>Allowing encoded slashes does <em>not</em> imply <em>decoding</em>.
420       Occurrences of <code>%2F</code> or <code>%5C</code> (<em>only</em> on
421       according systems) will be left as such in the otherwise decoded URL
422       string.</p>
423     </div>
424
425 <h3>See also</h3>
426 <ul>
427 <li><code class="directive"><a href="#acceptpathinfo">AcceptPathInfo</a></code></li>
428 </ul>
429 </div>
430 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
431 <div class="directive-section"><h2><a name="AllowOverride" id="AllowOverride">AllowOverride</a> <a name="allowoverride" id="allowoverride">Directive</a></h2>
432 <table class="directive">
433 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Types of directives that are allowed in
434 <code>.htaccess</code> files</td></tr>
435 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AllowOverride All|None|<var>directive-type</var>
436 [<var>directive-type</var>] ...</code></td></tr>
437 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AllowOverride All</code></td></tr>
438 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory</td></tr>
439 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
440 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
441 </table>
442     <p>When the server finds an <code>.htaccess</code> file (as
443     specified by <code class="directive"><a href="#accessfilename">AccessFileName</a></code>)
444     it needs to know which directives declared in that file can override
445     earlier configuration directives.</p>
446
447     <div class="note"><h3>Only available in &lt;Directory&gt; sections</h3>
448     <code class="directive">AllowOverride</code> is valid only in
449     <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
450     sections specified without regular expressions, not in <code class="directive"><a href="#location">&lt;Location&gt;</a></code>, <code class="directive"><a href="#directorymatch">&lt;DirectoryMatch&gt;</a></code> or
451     <code class="directive"><a href="#files">&lt;Files&gt;</a></code> sections.
452     </div>
453
454     <p>When this directive is set to <code>None</code>, then
455     <a href="#accessfilename">.htaccess</a> files are completely ignored.
456     In this case, the server will not even attempt to read
457     <code>.htaccess</code> files in the filesystem.</p>
458
459     <p>When this directive is set to <code>All</code>, then any
460     directive which has the .htaccess <a href="directive-dict.html#Context">Context</a> is allowed in
461     <code>.htaccess</code> files.</p>
462
463     <p>The <var>directive-type</var> can be one of the following
464     groupings of directives.</p>
465
466     <dl>
467       <dt>AuthConfig</dt>
468
469       <dd>
470
471       Allow use of the authorization directives (<code class="directive"><a href="../mod/mod_authn_dbm.html#authdbmgroupfile">AuthDBMGroupFile</a></code>,
472       <code class="directive"><a href="../mod/mod_authn_dbm.html#authdbmuserfile">AuthDBMUserFile</a></code>,
473       <code class="directive"><a href="../mod/mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></code>,
474       <code class="directive"><a href="../mod/mod_authn_core.html#authname">AuthName</a></code>,
475       <code class="directive"><a href="../mod/mod_authn_core.html#authtype">AuthType</a></code>, <code class="directive"><a href="../mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code>, <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>, <em>etc.</em>).</dd>
476
477       <dt>FileInfo</dt>
478
479       <dd>
480       Allow use of the directives controlling document types
481      (<code class="directive"><a href="#errordocument">ErrorDocument</a></code>,
482       <code class="directive"><a href="#forcetype">ForceType</a></code>,
483       <code class="directive"><a href="../mod/mod_negotiation.html#languagepriority">LanguagePriority</a></code>,
484       <code class="directive"><a href="#sethandler">SetHandler</a></code>,
485       <code class="directive"><a href="#setinputfilter">SetInputFilter</a></code>,
486       <code class="directive"><a href="#setoutputfilter">SetOutputFilter</a></code>, and
487       <code class="module"><a href="../mod/mod_mime.html">mod_mime</a></code> Add* and Remove* directives),
488       document meta data (<code class="directive"><a href="../mod/mod_headers.html#header">Header</a></code>, <code class="directive"><a href="../mod/mod_headers.html#requestheader">RequestHeader</a></code>, <code class="directive"><a href="../mod/mod_setenvif.html#setenvif">SetEnvIf</a></code>, <code class="directive"><a href="../mod/mod_setenvif.html#setenvifnocase">SetEnvIfNoCase</a></code>, <code class="directive"><a href="../mod/mod_setenvif.html#browsermatch">BrowserMatch</a></code>, <code class="directive"><a href="../mod/mod_usertrack.html#cookieexpires">CookieExpires</a></code>, <code class="directive"><a href="../mod/mod_usertrack.html#cookiedomain">CookieDomain</a></code>, <code class="directive"><a href="../mod/mod_usertrack.html#cookiestyle">CookieStyle</a></code>, <code class="directive"><a href="../mod/mod_usertrack.html#cookietracking">CookieTracking</a></code>, <code class="directive"><a href="../mod/mod_usertrack.html#cookiename">CookieName</a></code>),
489       <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code> directives <code class="directive"><a href="../mod/mod_rewrite.html#rewriteengine">RewriteEngine</a></code>, <code class="directive"><a href="../mod/mod_rewrite.html#rewriteoptions">RewriteOptions</a></code>, <code class="directive"><a href="../mod/mod_rewrite.html#rewritebase">RewriteBase</a></code>, <code class="directive"><a href="../mod/mod_rewrite.html#rewritecond">RewriteCond</a></code>, <code class="directive"><a href="../mod/mod_rewrite.html#rewriterule">RewriteRule</a></code>) and
490       <code class="directive"><a href="../mod/mod_actions.html#action">Action</a></code> from
491       <code class="module"><a href="../mod/mod_actions.html">mod_actions</a></code>.
492       </dd>
493
494       <dt>Indexes</dt>
495
496       <dd>
497       Allow use of the directives controlling directory indexing
498       (<code class="directive"><a href="../mod/mod_autoindex.html#adddescription">AddDescription</a></code>,
499       <code class="directive"><a href="../mod/mod_autoindex.html#addicon">AddIcon</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#addiconbyencoding">AddIconByEncoding</a></code>,
500       <code class="directive"><a href="../mod/mod_autoindex.html#addiconbytype">AddIconByType</a></code>,
501       <code class="directive"><a href="../mod/mod_autoindex.html#defaulticon">DefaultIcon</a></code>, <code class="directive"><a href="../mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#fancyindexing">FancyIndexing</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#headername">HeaderName</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#indexignore">IndexIgnore</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#indexoptions">IndexOptions</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#readmename">ReadmeName</a></code>,
502       <em>etc.</em>).</dd>
503
504       <dt>Limit</dt>
505
506       <dd>
507       Allow use of the directives controlling host access (<code class="directive"><a href="../mod/mod_authz_host.html#allow">Allow</a></code>, <code class="directive"><a href="../mod/mod_authz_host.html#deny">Deny</a></code> and <code class="directive"><a href="../mod/mod_authz_host.html#order">Order</a></code>).</dd>
508
509       <dt>Options[=<var>Option</var>,...]</dt>
510
511       <dd>
512       Allow use of the directives controlling specific directory
513       features (<code class="directive"><a href="#options">Options</a></code> and
514       <code class="directive"><a href="../mod/mod_include.html#xbithack">XBitHack</a></code>).
515       An equal sign may be given followed by a comma (but no spaces)
516       separated lists of options that may be set using the <code class="directive"><a href="#options">Options</a></code> command.</dd>
517     </dl>
518
519     <p>Example:</p>
520
521     <div class="example"><p><code>
522       AllowOverride AuthConfig Indexes
523     </code></p></div>
524
525     <p>In the example above all directives that are neither in the group
526     <code>AuthConfig</code> nor <code>Indexes</code> cause an internal
527     server error.</p>
528
529     <div class="note"><p>For security and performance reasons, do not set
530     <code>AllowOverride</code> to anything other than <code>None</code> 
531     in your <code>&lt;Directory /&gt;</code> block. Instead, find (or
532     create) the <code>&lt;Directory&gt;</code> block that refers to the
533     directory where you're actually planning to place a
534     <code>.htaccess</code> file.</p>
535     </div>
536
537 <h3>See also</h3>
538 <ul>
539 <li><code class="directive"><a href="#accessfilename">AccessFileName</a></code></li>
540 <li><a href="../configuring.html">Configuration Files</a></li>
541 <li><a href="../howto/htaccess.html">.htaccess Files</a></li>
542 </ul>
543 </div>
544 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
545 <div class="directive-section"><h2><a name="CGIMapExtension" id="CGIMapExtension">CGIMapExtension</a> <a name="cgimapextension" id="cgimapextension">Directive</a></h2>
546 <table class="directive">
547 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Technique for locating the interpreter for CGI
548 scripts</td></tr>
549 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>CGIMapExtension <var>cgi-path</var> <var>.extension</var></code></td></tr>
550 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
551 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
552 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
553 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
554 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>NetWare only</td></tr>
555 </table>
556     <p>This directive is used to control how Apache finds the
557     interpreter used to run CGI scripts. For example, setting
558     <code>CGIMapExtension sys:\foo.nlm .foo</code> will
559     cause all CGI script files with a <code>.foo</code> extension to
560     be passed to the FOO interpreter.</p>
561
562 </div>
563 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
564 <div class="directive-section"><h2><a name="ContentDigest" id="ContentDigest">ContentDigest</a> <a name="contentdigest" id="contentdigest">Directive</a></h2>
565 <table class="directive">
566 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables the generation of <code>Content-MD5</code> HTTP Response
567 headers</td></tr>
568 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ContentDigest On|Off</code></td></tr>
569 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ContentDigest Off</code></td></tr>
570 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
571 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Options</td></tr>
572 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
573 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
574 </table>
575     <p>This directive enables the generation of
576     <code>Content-MD5</code> headers as defined in RFC1864
577     respectively RFC2616.</p>
578
579     <p>MD5 is an algorithm for computing a "message digest"
580     (sometimes called "fingerprint") of arbitrary-length data, with
581     a high degree of confidence that any alterations in the data
582     will be reflected in alterations in the message digest.</p>
583
584     <p>The <code>Content-MD5</code> header provides an end-to-end
585     message integrity check (MIC) of the entity-body. A proxy or
586     client may check this header for detecting accidental
587     modification of the entity-body in transit. Example header:</p>
588
589     <div class="example"><p><code>
590       Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==
591     </code></p></div>
592
593     <p>Note that this can cause performance problems on your server
594     since the message digest is computed on every request (the
595     values are not cached).</p>
596
597     <p><code>Content-MD5</code> is only sent for documents served
598     by the <code class="module"><a href="../mod/core.html">core</a></code>, and not by any module. For example,
599     SSI documents, output from CGI scripts, and byte range responses
600     do not have this header.</p>
601
602 </div>
603 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
604 <div class="directive-section"><h2><a name="DefaultType" id="DefaultType">DefaultType</a> <a name="defaulttype" id="defaulttype">Directive</a></h2>
605 <table class="directive">
606 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>This directive has no effect other than to emit warnings
607 if the value is not <code>none</code>. In prior versions, DefaultType
608 would specify a default media type to assign to response content for
609 which no other media type configuration could be found.
610 </td></tr>
611 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>DefaultType <var>media-type|none</var></code></td></tr>
612 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>DefaultType none</code></td></tr>
613 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
614 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
615 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
616 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
617 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>The argument <code>none</code> is available in Apache 2.2.7 and later.  All other choices are DISABLED for 2.3.x and later.</td></tr>
618 </table>
619     <p>This directive has been disabled.  For backwards compatibility
620     of configuration files, it may be specified with the value
621     <code>none</code>, meaning no default media type. For example:</p>
622
623     <div class="example"><p><code>
624       DefaultType None
625     </code></p></div>
626
627     <p><code>DefaultType None</code> is only available in
628     httpd-2.2.7 and later.</p>
629
630     <p>Use the mime.types configuration file and the
631     <code class="directive"><a href="../mod/mod_mime.html#addtype">AddType</a></code> to configure media
632     type assignments via file extensions, or the
633     <code class="directive"><a href="#forcetype">ForceType</a></code> directive to configure
634     the media type for specific resources. Otherwise, the server will
635     send the response without a Content-Type header field and the
636     recipient may attempt to guess the media type.</p>
637
638 </div>
639 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
640 <div class="directive-section"><h2><a name="Define" id="Define">Define</a> <a name="define" id="define">Directive</a></h2>
641 <table class="directive">
642 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Define the existence of a variable</td></tr>
643 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Define <var>parameter-name</var></code></td></tr>
644 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
645 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
646 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
647 </table>
648     <p>Equivalent to passing the <code>-D</code> argument to <code class="program"><a href="../programs/httpd.html">httpd</a></code>.</p>
649     <p>This directive can be used to toggle the use of <code class="directive"><a href="#ifdefine">&lt;IfDefine&gt;</a></code> sections without needing to alter
650     <code>-D</code> arguments in any startup scripts.</p>
651
652 </div>
653 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
654 <div class="directive-section"><h2><a name="Directory" id="Directory">&lt;Directory&gt;</a> <a name="directory" id="directory">Directive</a></h2>
655 <table class="directive">
656 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enclose a group of directives that apply only to the
657 named file-system directory and sub-directories</td></tr>
658 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Directory <var>directory-path</var>&gt;
659 ... &lt;/Directory&gt;</code></td></tr>
660 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
661 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
662 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
663 </table>
664     <p><code class="directive">&lt;Directory&gt;</code> and
665     <code>&lt;/Directory&gt;</code> are used to enclose a group of
666     directives that will apply only to the named directory and
667     sub-directories of that directory. Any directive that is allowed
668     in a directory context may be used. <var>Directory-path</var> is
669     either the full path to a directory, or a wild-card string using
670     Unix shell-style matching. In a wild-card string, <code>?</code> matches
671     any single character, and <code>*</code> matches any sequences of
672     characters. You may also use <code>[]</code> character ranges. None
673     of the wildcards match a `/' character, so <code>&lt;Directory
674     /*/public_html&gt;</code> will not match
675     <code>/home/user/public_html</code>, but <code>&lt;Directory
676     /home/*/public_html&gt;</code> will match. Example:</p>
677
678     <div class="example"><p><code>
679       &lt;Directory /usr/local/httpd/htdocs&gt;<br />
680       <span class="indent">
681         Options Indexes FollowSymLinks<br />
682       </span>
683       &lt;/Directory&gt;
684     </code></p></div>
685
686     <div class="note">
687       <p>Be careful with the <var>directory-path</var> arguments:
688       They have to literally match the filesystem path which Apache uses
689       to access the files. Directives applied to a particular
690       <code>&lt;Directory&gt;</code> will not apply to files accessed from
691       that same directory via a different path, such as via different symbolic
692       links.</p>
693     </div>
694
695     <p><a class="glossarylink" href="../glossary.html#regex" title="see glossary">Regular
696     expressions</a> can also be used, with the addition of the
697     <code>~</code> character. For example:</p>
698
699     <div class="example"><p><code>
700       &lt;Directory ~ "^/www/.*/[0-9]{3}"&gt;
701     </code></p></div>
702
703     <p>would match directories in <code>/www/</code> that consisted of
704     three numbers.</p>
705
706     <p>If multiple (non-regular expression) <code class="directive">&lt;Directory&gt;</code> sections
707     match the directory (or one of its parents) containing a document,
708     then the directives are applied in the order of shortest match
709     first, interspersed with the directives from the <a href="#accessfilename">.htaccess</a> files. For example,
710     with</p>
711
712     <div class="example"><p><code>
713       &lt;Directory /&gt;<br />
714       <span class="indent">
715         AllowOverride None<br />
716       </span>
717       &lt;/Directory&gt;<br />
718       <br />
719       &lt;Directory /home/&gt;<br />
720       <span class="indent">
721         AllowOverride FileInfo<br />
722       </span>
723       &lt;/Directory&gt;
724     </code></p></div>
725
726     <p>for access to the document <code>/home/web/dir/doc.html</code>
727     the steps are:</p>
728
729     <ul>
730       <li>Apply directive <code>AllowOverride None</code>
731       (disabling <code>.htaccess</code> files).</li>
732
733       <li>Apply directive <code>AllowOverride FileInfo</code> (for
734       directory <code>/home</code>).</li>
735
736       <li>Apply any <code>FileInfo</code> directives in
737       <code>/home/.htaccess</code>, <code>/home/web/.htaccess</code> and
738       <code>/home/web/dir/.htaccess</code> in that order.</li>
739     </ul>
740
741     <p>Regular expressions are not considered until after all of the
742     normal sections have been applied. Then all of the regular
743     expressions are tested in the order they appeared in the
744     configuration file. For example, with</p>
745
746     <div class="example"><p><code>
747       &lt;Directory ~ abc$&gt;<br />
748       <span class="indent">
749         # ... directives here ...<br />
750       </span>
751       &lt;/Directory&gt;
752     </code></p></div>
753
754     <p>the regular expression section won't be considered until after
755     all normal <code class="directive">&lt;Directory&gt;</code>s and
756     <code>.htaccess</code> files have been applied. Then the regular
757     expression will match on <code>/home/abc/public_html/abc</code> and
758     the corresponding <code class="directive">&lt;Directory&gt;</code> will
759     be applied.</p>
760
761    <p><strong>Note that the default Apache access for
762     <code>&lt;Directory /&gt;</code> is <code>Allow from All</code>.
763     This means that Apache will serve any file mapped from an URL. It is
764     recommended that you change this with a block such
765     as</strong></p>
766
767     <div class="example"><p><code>
768       &lt;Directory /&gt;<br />
769       <span class="indent">
770         Order Deny,Allow<br />
771         Deny from All<br />
772       </span>
773       &lt;/Directory&gt;
774     </code></p></div>
775
776     <p><strong>and then override this for directories you
777     <em>want</em> accessible. See the <a href="../misc/security_tips.html">Security Tips</a> page for more
778     details.</strong></p>
779
780     <p>The directory sections occur in the <code>httpd.conf</code> file.
781     <code class="directive">&lt;Directory&gt;</code> directives
782     cannot nest, and cannot appear in a <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code> or <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> section.</p>
783
784 <h3>See also</h3>
785 <ul>
786 <li><a href="../sections.html">How &lt;Directory&gt;,
787     &lt;Location&gt; and &lt;Files&gt; sections work</a> for an
788     explanation of how these different sections are combined when a
789     request is received</li>
790 </ul>
791 </div>
792 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
793 <div class="directive-section"><h2><a name="DirectoryMatch" id="DirectoryMatch">&lt;DirectoryMatch&gt;</a> <a name="directorymatch" id="directorymatch">Directive</a></h2>
794 <table class="directive">
795 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enclose directives that apply to
796 file-system directories matching a regular expression and their
797 subdirectories</td></tr>
798 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;DirectoryMatch <var>regex</var>&gt;
799 ... &lt;/DirectoryMatch&gt;</code></td></tr>
800 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
801 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
802 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
803 </table>
804     <p><code class="directive">&lt;DirectoryMatch&gt;</code> and
805     <code>&lt;/DirectoryMatch&gt;</code> are used to enclose a group
806     of directives which will apply only to the named directory and
807     sub-directories of that directory, the same as <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>. However, it
808     takes as an argument a <a class="glossarylink" href="../glossary.html#regex" title="see glossary">regular 
809     expression</a>. For example:</p>
810
811     <div class="example"><p><code>
812       &lt;DirectoryMatch "^/www/(.+/)?[0-9]{3}"&gt;
813     </code></p></div>
814
815     <p>would match directories in <code>/www/</code> that consisted of three
816     numbers.</p>
817
818 <h3>See also</h3>
819 <ul>
820 <li><code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> for
821 a description of how regular expressions are mixed in with normal
822 <code class="directive">&lt;Directory&gt;</code>s</li>
823 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt; and
824 &lt;Files&gt; sections work</a> for an explanation of how these different
825 sections are combined when a request is received</li>
826 </ul>
827 </div>
828 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
829 <div class="directive-section"><h2><a name="DocumentRoot" id="DocumentRoot">DocumentRoot</a> <a name="documentroot" id="documentroot">Directive</a></h2>
830 <table class="directive">
831 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Directory that forms the main document tree visible
832 from the web</td></tr>
833 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>DocumentRoot <var>directory-path</var></code></td></tr>
834 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>DocumentRoot /usr/local/apache/htdocs</code></td></tr>
835 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
836 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
837 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
838 </table>
839     <p>This directive sets the directory from which <code class="program"><a href="../programs/httpd.html">httpd</a></code>
840     will serve files. Unless matched by a directive like <code class="directive"><a href="../mod/mod_alias.html#alias">Alias</a></code>, the server appends the
841     path from the requested URL to the document root to make the
842     path to the document. Example:</p>
843
844     <div class="example"><p><code>
845       DocumentRoot /usr/web
846     </code></p></div>
847
848     <p>then an access to
849     <code>http://www.my.host.com/index.html</code> refers to
850     <code>/usr/web/index.html</code>. If the <var>directory-path</var> is 
851     not absolute then it is assumed to be relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
852
853     <p>The <code class="directive">DocumentRoot</code> should be specified without
854     a trailing slash.</p>
855
856 <h3>See also</h3>
857 <ul>
858 <li><a href="../urlmapping.html#documentroot">Mapping URLs to Filesystem
859 Locations</a></li>
860 </ul>
861 </div>
862 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
863 <div class="directive-section"><h2><a name="EnableMMAP" id="EnableMMAP">EnableMMAP</a> <a name="enablemmap" id="enablemmap">Directive</a></h2>
864 <table class="directive">
865 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Use memory-mapping to read files during delivery</td></tr>
866 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnableMMAP On|Off</code></td></tr>
867 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnableMMAP On</code></td></tr>
868 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
869 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
870 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
871 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
872 </table>
873     <p>This directive controls whether the <code class="program"><a href="../programs/httpd.html">httpd</a></code> may use
874     memory-mapping if it needs to read the contents of a file during
875     delivery.  By default, when the handling of a request requires
876     access to the data within a file -- for example, when delivering a
877     server-parsed file using <code class="module"><a href="../mod/mod_include.html">mod_include</a></code> -- Apache
878     memory-maps the file if the OS supports it.</p>
879
880     <p>This memory-mapping sometimes yields a performance improvement.
881     But in some environments, it is better to disable the memory-mapping
882     to prevent operational problems:</p>
883
884     <ul>
885     <li>On some multiprocessor systems, memory-mapping can reduce the
886     performance of the <code class="program"><a href="../programs/httpd.html">httpd</a></code>.</li>
887     <li>With an NFS-mounted <code class="directive"><a href="#documentroot">DocumentRoot</a></code>,
888     the <code class="program"><a href="../programs/httpd.html">httpd</a></code> may crash due to a segmentation fault if a file
889     is deleted or truncated while the <code class="program"><a href="../programs/httpd.html">httpd</a></code> has it
890     memory-mapped.</li>
891     </ul>
892
893     <p>For server configurations that are vulnerable to these problems,
894     you should disable memory-mapping of delivered files by specifying:</p>
895
896     <div class="example"><p><code>
897       EnableMMAP Off
898     </code></p></div>
899
900     <p>For NFS mounted files, this feature may be disabled explicitly for
901     the offending files by specifying:</p>
902
903     <div class="example"><p><code>
904       &lt;Directory "/path-to-nfs-files"&gt;
905       <span class="indent">
906         EnableMMAP Off
907       </span>
908       &lt;/Directory&gt;
909     </code></p></div>
910
911 </div>
912 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
913 <div class="directive-section"><h2><a name="EnableSendfile" id="EnableSendfile">EnableSendfile</a> <a name="enablesendfile" id="enablesendfile">Directive</a></h2>
914 <table class="directive">
915 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Use the kernel sendfile support to deliver files to the client</td></tr>
916 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnableSendfile On|Off</code></td></tr>
917 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnableSendfile On</code></td></tr>
918 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
919 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
920 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
921 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
922 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.44 and later</td></tr>
923 </table>
924     <p>This directive controls whether <code class="program"><a href="../programs/httpd.html">httpd</a></code> may use the
925     sendfile support from the kernel to transmit file contents to the client.
926     By default, when the handling of a request requires no access
927     to the data within a file -- for example, when delivering a
928     static file -- Apache uses sendfile to deliver the file contents
929     without ever reading the file if the OS supports it.</p>
930
931     <p>This sendfile mechanism avoids separate read and send operations,
932     and buffer allocations. But on some platforms or within some
933     filesystems, it is better to disable this feature to avoid
934     operational problems:</p>
935
936     <ul>
937     <li>Some platforms may have broken sendfile support that the build
938     system did not detect, especially if the binaries were built on
939     another box and moved to such a machine with broken sendfile
940     support.</li>
941     <li>On Linux the use of sendfile triggers TCP-checksum
942     offloading bugs on certain networking cards when using IPv6.</li>
943     <li>On Linux on Itanium, sendfile may be unable to handle files
944     over 2GB in size.</li>
945     <li>With a network-mounted <code class="directive"><a href="#documentroot">DocumentRoot</a></code> (e.g., NFS or SMB),
946     the kernel may be unable to serve the network file through
947     its own cache.</li>
948     </ul>
949
950     <p>For server configurations that are vulnerable to these problems,
951     you should disable this feature by specifying:</p>
952
953     <div class="example"><p><code>
954       EnableSendfile Off
955     </code></p></div>
956
957     <p>For NFS or SMB mounted files, this feature may be disabled explicitly
958     for the offending files by specifying:</p>
959
960     <div class="example"><p><code>
961       &lt;Directory "/path-to-nfs-files"&gt;
962       <span class="indent">
963         EnableSendfile Off
964       </span>
965       &lt;/Directory&gt;
966     </code></p></div>
967     <p>Please note that the per-directory and .htaccess configuration
968        of <code class="directive">EnableSendfile</code> is not supported by
969        <code class="module"><a href="../mod/mod_disk_cache.html">mod_disk_cache</a></code>.
970        Only global definition of <code class="directive">EnableSendfile</code>
971        is taken into account by the module.
972     </p>
973
974 </div>
975 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
976 <div class="directive-section"><h2><a name="ErrorDocument" id="ErrorDocument">ErrorDocument</a> <a name="errordocument" id="errordocument">Directive</a></h2>
977 <table class="directive">
978 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>What the server will return to the client
979 in case of an error</td></tr>
980 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ErrorDocument <var>error-code</var> <var>document</var></code></td></tr>
981 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
982 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
983 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
984 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
985 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Quoting syntax for text messages is different in Apache
986 2.0</td></tr>
987 </table>
988     <p>In the event of a problem or error, Apache can be configured
989     to do one of four things,</p>
990
991     <ol>
992       <li>output a simple hardcoded error message</li>
993
994       <li>output a customized message</li>
995
996       <li>redirect to a local <var>URL-path</var> to handle the
997       problem/error</li>
998
999       <li>redirect to an external <var>URL</var> to handle the
1000       problem/error</li>
1001     </ol>
1002
1003     <p>The first option is the default, while options 2-4 are
1004     configured using the <code class="directive">ErrorDocument</code>
1005     directive, which is followed by the HTTP response code and a URL
1006     or a message. Apache will sometimes offer additional information
1007     regarding the problem/error.</p>
1008
1009     <p>URLs can begin with a slash (/) for local web-paths (relative
1010     to the <code class="directive"><a href="#documentroot">DocumentRoot</a></code>), or be a
1011     full URL which the client can resolve. Alternatively, a message
1012     can be provided to be displayed by the browser. Examples:</p>
1013
1014     <div class="example"><p><code>
1015       ErrorDocument 500 http://foo.example.com/cgi-bin/tester<br />
1016       ErrorDocument 404 /cgi-bin/bad_urls.pl<br />
1017       ErrorDocument 401 /subscription_info.html<br />
1018       ErrorDocument 403 "Sorry can't allow you access today"
1019     </code></p></div>
1020
1021     <p>Additionally, the special value <code>default</code> can be used
1022     to specify Apache's simple hardcoded message.  While not required
1023     under normal circumstances, <code>default</code> will restore
1024     Apache's simple hardcoded message for configurations that would
1025     otherwise inherit an existing <code class="directive">ErrorDocument</code>.</p>
1026
1027     <div class="example"><p><code>
1028       ErrorDocument 404 /cgi-bin/bad_urls.pl<br /><br />
1029       &lt;Directory /web/docs&gt;<br />
1030       <span class="indent">
1031         ErrorDocument 404 default<br />
1032       </span>
1033       &lt;/Directory&gt;
1034     </code></p></div>
1035
1036     <p>Note that when you specify an <code class="directive">ErrorDocument</code>
1037     that points to a remote URL (ie. anything with a method such as
1038     <code>http</code> in front of it), Apache will send a redirect to the
1039     client to tell it where to find the document, even if the
1040     document ends up being on the same server. This has several
1041     implications, the most important being that the client will not
1042     receive the original error status code, but instead will
1043     receive a redirect status code. This in turn can confuse web
1044     robots and other clients which try to determine if a URL is
1045     valid using the status code. In addition, if you use a remote
1046     URL in an <code>ErrorDocument 401</code>, the client will not
1047     know to prompt the user for a password since it will not
1048     receive the 401 status code. Therefore, <strong>if you use an
1049     <code>ErrorDocument 401</code> directive then it must refer to a local
1050     document.</strong></p>
1051
1052     <p>Microsoft Internet Explorer (MSIE) will by default ignore
1053     server-generated error messages when they are "too small" and substitute
1054     its own "friendly" error messages. The size threshold varies depending on
1055     the type of error, but in general, if you make your error document
1056     greater than 512 bytes, then MSIE will show the server-generated
1057     error rather than masking it.  More information is available in
1058     Microsoft Knowledge Base article <a href="http://support.microsoft.com/default.aspx?scid=kb;en-us;Q294807">Q294807</a>.</p>
1059
1060     <p>Although most error messages can be overriden, there are certain
1061     circumstances where the internal messages are used regardless of the
1062     setting of <code class="directive"><a href="#errordocument">ErrorDocument</a></code>.  In
1063     particular, if a malformed request is detected, normal request processing
1064     will be immediately halted and the internal error message returned.
1065     This is necessary to guard against security problems caused by
1066     bad requests.</p>
1067
1068     <p>Prior to version 2.0, messages were indicated by prefixing
1069     them with a single unmatched double quote character.</p>
1070
1071 <h3>See also</h3>
1072 <ul>
1073 <li><a href="../custom-error.html">documentation of
1074     customizable responses</a></li>
1075 </ul>
1076 </div>
1077 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1078 <div class="directive-section"><h2><a name="ErrorLog" id="ErrorLog">ErrorLog</a> <a name="errorlog" id="errorlog">Directive</a></h2>
1079 <table class="directive">
1080 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Location where the server will log errors</td></tr>
1081 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code> ErrorLog <var>file-path</var>|syslog[:<var>facility</var>]</code></td></tr>
1082 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ErrorLog logs/error_log (Unix) ErrorLog logs/error.log (Windows)</code></td></tr>
1083 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
1084 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1085 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1086 </table>
1087     <p>The <code class="directive">ErrorLog</code> directive sets the name of
1088     the file to which the server will log any errors it encounters. If
1089     the <var>file-path</var> is not absolute then it is assumed to be 
1090     relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
1091
1092     <div class="example"><h3>Example</h3><p><code>
1093     ErrorLog /var/log/httpd/error_log
1094     </code></p></div>
1095
1096     <p>If the <var>file-path</var>
1097     begins with a pipe (|) then it is assumed to be a command to spawn
1098     to handle the error log.</p>
1099
1100     <div class="example"><h3>Example</h3><p><code>
1101     ErrorLog "|/usr/local/bin/httpd_errors"
1102     </code></p></div>
1103
1104     <p>Using <code>syslog</code> instead of a filename enables logging
1105     via syslogd(8) if the system supports it. The default is to use
1106     syslog facility <code>local7</code>, but you can override this by
1107     using the <code>syslog:<var>facility</var></code> syntax where
1108     <var>facility</var> can be one of the names usually documented in
1109     syslog(1).</p>
1110
1111     <div class="example"><h3>Example</h3><p><code>
1112     ErrorLog syslog:user
1113     </code></p></div>
1114
1115     <p>SECURITY: See the <a href="../misc/security_tips.html#serverroot">security tips</a>
1116     document for details on why your security could be compromised
1117     if the directory where log files are stored is writable by
1118     anyone other than the user that starts the server.</p>
1119     <div class="warning"><h3>Note</h3>
1120       <p>When entering a file path on non-Unix platforms, care should be taken
1121       to make sure that only forward slashed are used even though the platform
1122       may allow the use of back slashes. In general it is a good idea to always 
1123       use forward slashes throughout the configuration files.</p>
1124     </div>
1125
1126 <h3>See also</h3>
1127 <ul>
1128 <li><code class="directive"><a href="#loglevel">LogLevel</a></code></li>
1129 <li><a href="../logs.html">Apache Log Files</a></li>
1130 </ul>
1131 </div>
1132 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1133 <div class="directive-section"><h2><a name="FileETag" id="FileETag">FileETag</a> <a name="fileetag" id="fileetag">Directive</a></h2>
1134 <table class="directive">
1135 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>File attributes used to create the ETag
1136 HTTP response header</td></tr>
1137 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>FileETag <var>component</var> ...</code></td></tr>
1138 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>FileETag INode MTime Size</code></td></tr>
1139 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1140 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
1141 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1142 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1143 </table>
1144     <p>
1145     The <code class="directive">FileETag</code> directive configures the file
1146     attributes that are used to create the <code>ETag</code> (entity
1147     tag) response header field when the document is based on a file.
1148     (The <code>ETag</code> value is used in cache management to save
1149     network bandwidth.) In Apache 1.3.22 and earlier, the
1150     <code>ETag</code> value was <em>always</em> formed
1151     from the file's inode, size, and last-modified time (mtime). The
1152     <code class="directive">FileETag</code> directive allows you to choose
1153     which of these -- if any -- should be used. The recognized keywords are:
1154     </p>
1155
1156     <dl>
1157      <dt><strong>INode</strong></dt>
1158      <dd>The file's i-node number will be included in the calculation</dd>
1159      <dt><strong>MTime</strong></dt>
1160      <dd>The date and time the file was last modified will be included</dd>
1161      <dt><strong>Size</strong></dt>
1162      <dd>The number of bytes in the file will be included</dd>
1163      <dt><strong>All</strong></dt>
1164      <dd>All available fields will be used. This is equivalent to:
1165          <div class="example"><p><code>FileETag INode MTime Size</code></p></div></dd>
1166      <dt><strong>None</strong></dt>
1167      <dd>If a document is file-based, no <code>ETag</code> field will be
1168        included in the response</dd>
1169     </dl>
1170
1171     <p>The <code>INode</code>, <code>MTime</code>, and <code>Size</code>
1172     keywords may be prefixed with either <code>+</code> or <code>-</code>,
1173     which allow changes to be made to the default setting inherited
1174     from a broader scope. Any keyword appearing without such a prefix
1175     immediately and completely cancels the inherited setting.</p>
1176
1177     <p>If a directory's configuration includes
1178     <code>FileETag&nbsp;INode&nbsp;MTime&nbsp;Size</code>, and a
1179     subdirectory's includes <code>FileETag&nbsp;-INode</code>,
1180     the setting for that subdirectory (which will be inherited by
1181     any sub-subdirectories that don't override it) will be equivalent to
1182     <code>FileETag&nbsp;MTime&nbsp;Size</code>.</p>
1183     <div class="warning"><h3>Warning</h3>
1184     Do not change the default for directories or locations that have WebDAV
1185     enabled and use <code class="module"><a href="../mod/mod_dav_fs.html">mod_dav_fs</a></code> as a storage provider.
1186     <code class="module"><a href="../mod/mod_dav_fs.html">mod_dav_fs</a></code> uses <code>INode&nbsp;MTime&nbsp;Size</code>
1187     as a fixed format for <code>ETag</code> comparisons on conditional requests.
1188     These conditional requests will break if the <code>ETag</code> format is
1189     changed via <code class="directive">FileETag</code>.
1190     </div>
1191
1192 </div>
1193 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1194 <div class="directive-section"><h2><a name="Files" id="Files">&lt;Files&gt;</a> <a name="files" id="files">Directive</a></h2>
1195 <table class="directive">
1196 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply to matched
1197 filenames</td></tr>
1198 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Files <var>filename</var>&gt; ... &lt;/Files&gt;</code></td></tr>
1199 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1200 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1201 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1202 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1203 </table>
1204     <p>The <code class="directive">&lt;Files&gt;</code> directive
1205     limits the scope of the enclosed directives by filename. It is comparable
1206     to the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
1207     and <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
1208     directives. It should be matched with a <code>&lt;/Files&gt;</code>
1209     directive. The directives given within this section will be applied to
1210     any object with a basename (last component of filename) matching the
1211     specified filename. <code class="directive">&lt;Files&gt;</code>
1212     sections are processed in the order they appear in the
1213     configuration file, after the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections and
1214     <code>.htaccess</code> files are read, but before <code class="directive"><a href="#location">&lt;Location&gt;</a></code> sections. Note
1215     that <code class="directive">&lt;Files&gt;</code> can be nested
1216     inside <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections to restrict the
1217     portion of the filesystem they apply to.</p>
1218
1219     <p>The <var>filename</var> argument should include a filename, or
1220     a wild-card string, where <code>?</code> matches any single character,
1221     and <code>*</code> matches any sequences of characters.
1222     <a class="glossarylink" href="../glossary.html#regex" title="see glossary">Regular expressions</a> 
1223     can also be used, with the addition of the
1224     <code>~</code> character. For example:</p>
1225
1226     <div class="example"><p><code>
1227       &lt;Files ~ "\.(gif|jpe?g|png)$"&gt;
1228     </code></p></div>
1229
1230     <p>would match most common Internet graphics formats. <code class="directive"><a href="#filesmatch">&lt;FilesMatch&gt;</a></code> is preferred,
1231     however.</p>
1232
1233     <p>Note that unlike <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> and <code class="directive"><a href="#location">&lt;Location&gt;</a></code> sections, <code class="directive">&lt;Files&gt;</code> sections can be used inside
1234     <code>.htaccess</code> files. This allows users to control access to
1235     their own files, at a file-by-file level.</p>
1236
1237
1238 <h3>See also</h3>
1239 <ul>
1240 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;
1241     and &lt;Files&gt; sections work</a> for an explanation of how these
1242     different sections are combined when a request is received</li>
1243 </ul>
1244 </div>
1245 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1246 <div class="directive-section"><h2><a name="FilesMatch" id="FilesMatch">&lt;FilesMatch&gt;</a> <a name="filesmatch" id="filesmatch">Directive</a></h2>
1247 <table class="directive">
1248 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply to regular-expression matched
1249 filenames</td></tr>
1250 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;FilesMatch <var>regex</var>&gt; ... &lt;/FilesMatch&gt;</code></td></tr>
1251 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1252 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1253 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1254 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1255 </table>
1256     <p>The <code class="directive">&lt;FilesMatch&gt;</code> directive
1257     limits the scope of the enclosed directives by filename, just as the
1258     <code class="directive"><a href="#files">&lt;Files&gt;</a></code> directive
1259     does. However, it accepts a <a class="glossarylink" href="../glossary.html#regex" title="see glossary">regular 
1260     expression</a>. For example:</p>
1261
1262     <div class="example"><p><code>
1263       &lt;FilesMatch "\.(gif|jpe?g|png)$"&gt;
1264     </code></p></div>
1265
1266     <p>would match most common Internet graphics formats.</p>
1267
1268 <h3>See also</h3>
1269 <ul>
1270 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;
1271     and &lt;Files&gt; sections work</a> for an explanation of how these
1272     different sections are combined when a request is received</li>
1273 </ul>
1274 </div>
1275 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1276 <div class="directive-section"><h2><a name="ForceType" id="ForceType">ForceType</a> <a name="forcetype" id="forcetype">Directive</a></h2>
1277 <table class="directive">
1278 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Forces all matching files to be served with the specified
1279 media type in the HTTP Content-Type header field</td></tr>
1280 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ForceType <var>media-type</var>|None</code></td></tr>
1281 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
1282 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
1283 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1284 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1285 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Moved to the core in Apache 2.0</td></tr>
1286 </table>
1287     <p>When placed into an <code>.htaccess</code> file or a
1288     <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>, or
1289     <code class="directive"><a href="#location">&lt;Location&gt;</a></code> or
1290     <code class="directive"><a href="#files">&lt;Files&gt;</a></code>
1291     section, this directive forces all matching files to be served
1292     with the content type identification given by
1293     <var>media-type</var>. For example, if you had a directory full of
1294     GIF files, but did not want to label them all with <code>.gif</code>,
1295     you might want to use:</p>
1296
1297     <div class="example"><p><code>
1298       ForceType image/gif
1299     </code></p></div>
1300
1301     <p>Note that this directive overrides other indirect media type
1302     associations defined in mime.types or via the
1303     <code class="directive"><a href="../mod/mod_mime.html#addtype">AddType</a></code>.</p>
1304
1305     <p>You can also override more general
1306     <code class="directive">ForceType</code> settings
1307     by using the value of <code>None</code>:</p>
1308
1309     <div class="example"><p><code>
1310       # force all files to be image/gif:<br />
1311       &lt;Location /images&gt;<br />
1312         <span class="indent">
1313           ForceType image/gif<br />
1314         </span>
1315       &lt;/Location&gt;<br />
1316       <br />
1317       # but normal mime-type associations here:<br />
1318       &lt;Location /images/mixed&gt;<br />
1319       <span class="indent">
1320         ForceType None<br />
1321       </span>
1322       &lt;/Location&gt;
1323     </code></p></div>
1324
1325 </div>
1326 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1327 <div class="directive-section"><h2><a name="HostnameLookups" id="HostnameLookups">HostnameLookups</a> <a name="hostnamelookups" id="hostnamelookups">Directive</a></h2>
1328 <table class="directive">
1329 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables DNS lookups on client IP addresses</td></tr>
1330 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>HostnameLookups On|Off|Double</code></td></tr>
1331 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>HostnameLookups Off</code></td></tr>
1332 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
1333 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1334 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1335 </table>
1336     <p>This directive enables DNS lookups so that host names can be
1337     logged (and passed to CGIs/SSIs in <code>REMOTE_HOST</code>).
1338     The value <code>Double</code> refers to doing double-reverse
1339     DNS lookup. That is, after a reverse lookup is performed, a forward
1340     lookup is then performed on that result. At least one of the IP
1341     addresses in the forward lookup must match the original
1342     address. (In "tcpwrappers" terminology this is called
1343     <code>PARANOID</code>.)</p>
1344
1345     <p>Regardless of the setting, when <code class="module"><a href="../mod/mod_authz_host.html">mod_authz_host</a></code> is
1346     used for controlling access by hostname, a double reverse lookup
1347     will be performed.  This is necessary for security. Note that the
1348     result of this double-reverse isn't generally available unless you
1349     set <code>HostnameLookups Double</code>. For example, if only
1350     <code>HostnameLookups On</code> and a request is made to an object
1351     that is protected by hostname restrictions, regardless of whether
1352     the double-reverse fails or not, CGIs will still be passed the
1353     single-reverse result in <code>REMOTE_HOST</code>.</p>
1354
1355     <p>The default is <code>Off</code> in order to save the network
1356     traffic for those sites that don't truly need the reverse
1357     lookups done. It is also better for the end users because they
1358     don't have to suffer the extra latency that a lookup entails.
1359     Heavily loaded sites should leave this directive
1360     <code>Off</code>, since DNS lookups can take considerable
1361     amounts of time. The utility <code class="program"><a href="../programs/logresolve.html">logresolve</a></code>, compiled by
1362     default to the <code>bin</code> subdirectory of your installation
1363     directory, can be used to look up host names from logged IP addresses
1364     offline.</p>
1365
1366 </div>
1367 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1368 <div class="directive-section"><h2><a name="If" id="If">&lt;If&gt;</a> <a name="if" id="if">Directive</a></h2>
1369 <table class="directive">
1370 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply only if a condition is
1371 satisfied by a request at runtime</td></tr>
1372 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;If <var>expression</var>&gt; ... &lt;/If&gt;</code></td></tr>
1373 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1374 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1375 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1376 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1377 </table>
1378     <p>The <code class="directive">&lt;If&gt;</code> directive
1379     evaluates an expression at runtime, and applies the enclosed
1380     directives if and only if the expression evaluates to true.
1381     For example:</p>
1382
1383     <div class="example"><p><code>
1384         &lt;If "$req{Host} = ''"&gt;
1385     </code></p></div>
1386
1387     <p>would match HTTP/1.0 requests without a <var>Host:</var> header.</p>
1388
1389 <h3>See also</h3>
1390 <ul>
1391 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;,
1392     &lt;Files&gt; sections work</a> for an explanation of how these
1393     different sections are combined when a request is received.
1394     <code class="directive">&lt;If&gt;</code> has the same precedence
1395     and usage as <code class="directive">&lt;Files&gt;</code></li>
1396 </ul>
1397 </div>
1398 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1399 <div class="directive-section"><h2><a name="IfDefine" id="IfDefine">&lt;IfDefine&gt;</a> <a name="ifdefine" id="ifdefine">Directive</a></h2>
1400 <table class="directive">
1401 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Encloses directives that will be processed only
1402 if a test is true at startup</td></tr>
1403 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;IfDefine [!]<var>parameter-name</var>&gt; ...
1404     &lt;/IfDefine&gt;</code></td></tr>
1405 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1406 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1407 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1408 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1409 </table>
1410     <p>The <code>&lt;IfDefine <var>test</var>&gt;...&lt;/IfDefine&gt;
1411     </code> section is used to mark directives that are conditional. The
1412     directives within an <code class="directive">&lt;IfDefine&gt;</code>
1413     section are only processed if the <var>test</var> is true. If <var>
1414     test</var> is false, everything between the start and end markers is
1415     ignored.</p>
1416
1417     <p>The <var>test</var> in the <code class="directive">&lt;IfDefine&gt;</code> section directive can be one of two forms:</p>
1418
1419     <ul>
1420       <li><var>parameter-name</var></li>
1421
1422       <li><code>!</code><var>parameter-name</var></li>
1423     </ul>
1424
1425     <p>In the former case, the directives between the start and end
1426     markers are only processed if the parameter named
1427     <var>parameter-name</var> is defined. The second format reverses
1428     the test, and only processes the directives if
1429     <var>parameter-name</var> is <strong>not</strong> defined.</p>
1430
1431     <p>The <var>parameter-name</var> argument is a define as given on the
1432     <code class="program"><a href="../programs/httpd.html">httpd</a></code> command line via <code>-D<var>parameter</var>
1433     </code> at the time the server was started or by the <code class="directive"><a href="#define">Define</a></code> directive.</p>
1434
1435     <p><code class="directive">&lt;IfDefine&gt;</code> sections are
1436     nest-able, which can be used to implement simple
1437     multiple-parameter tests. Example:</p>
1438
1439     <div class="example"><p><code>
1440       httpd -DReverseProxy -DUseCache -DMemCache ...<br />
1441       <br />
1442       # httpd.conf<br />
1443       &lt;IfDefine ReverseProxy&gt;<br />
1444       <span class="indent">
1445         LoadModule proxy_module   modules/mod_proxy.so<br />
1446         LoadModule proxy_http_module   modules/mod_proxy_http.so<br />
1447         &lt;IfDefine UseCache&gt;<br />
1448         <span class="indent">
1449           LoadModule cache_module   modules/mod_cache.so<br />
1450           &lt;IfDefine MemCache&gt;<br />
1451           <span class="indent">
1452             LoadModule mem_cache_module   modules/mod_mem_cache.so<br />
1453           </span>
1454           &lt;/IfDefine&gt;<br />
1455           &lt;IfDefine !MemCache&gt;<br />
1456           <span class="indent">
1457             LoadModule disk_cache_module   modules/mod_disk_cache.so<br />
1458           </span>
1459           &lt;/IfDefine&gt;
1460         </span>
1461         &lt;/IfDefine&gt;
1462       </span>
1463       &lt;/IfDefine&gt;
1464     </code></p></div>
1465
1466 </div>
1467 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1468 <div class="directive-section"><h2><a name="IfModule" id="IfModule">&lt;IfModule&gt;</a> <a name="ifmodule" id="ifmodule">Directive</a></h2>
1469 <table class="directive">
1470 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Encloses directives that are processed conditional on the
1471 presence or absence of a specific module</td></tr>
1472 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;IfModule [!]<var>module-file</var>|<var>module-identifier</var>&gt; ...
1473     &lt;/IfModule&gt;</code></td></tr>
1474 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1475 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1476 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1477 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1478 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Module identifiers are available in version 2.1 and
1479 later.</td></tr>
1480 </table>
1481     <p>The <code>&lt;IfModule <var>test</var>&gt;...&lt;/IfModule&gt;</code>
1482     section is used to mark directives that are conditional on the presence of
1483     a specific module. The directives within an <code class="directive">&lt;IfModule&gt;</code> section are only processed if the <var>test</var>
1484     is true. If <var>test</var> is false, everything between the start and
1485     end markers is ignored.</p>
1486
1487     <p>The <var>test</var> in the <code class="directive">&lt;IfModule&gt;</code> section directive can be one of two forms:</p>
1488
1489     <ul>
1490       <li><var>module</var></li>
1491
1492       <li>!<var>module</var></li>
1493     </ul>
1494
1495     <p>In the former case, the directives between the start and end
1496     markers are only processed if the module named <var>module</var>
1497     is included in Apache -- either compiled in or
1498     dynamically loaded using <code class="directive"><a href="../mod/mod_so.html#loadmodule">LoadModule</a></code>. The second format reverses the test,
1499     and only processes the directives if <var>module</var> is
1500     <strong>not</strong> included.</p>
1501
1502     <p>The <var>module</var> argument can be either the module identifier or
1503     the file name of the module, at the time it was compiled.  For example,
1504     <code>rewrite_module</code> is the identifier and
1505     <code>mod_rewrite.c</code> is the file name. If a module consists of
1506     several source files, use the name of the file containing the string
1507     <code>STANDARD20_MODULE_STUFF</code>.</p>
1508
1509     <p><code class="directive">&lt;IfModule&gt;</code> sections are
1510     nest-able, which can be used to implement simple multiple-module
1511     tests.</p>
1512
1513     <div class="note">This section should only be used if you need to have one
1514     configuration file that works whether or not a specific module
1515     is available. In normal operation, directives need not be
1516     placed in <code class="directive">&lt;IfModule&gt;</code>
1517     sections.</div>
1518
1519 </div>
1520 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1521 <div class="directive-section"><h2><a name="Include" id="Include">Include</a> <a name="include" id="include">Directive</a></h2>
1522 <table class="directive">
1523 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Includes other configuration files from within
1524 the server configuration files</td></tr>
1525 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Include <var>file-path</var>|<var>directory-path</var></code></td></tr>
1526 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
1527 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1528 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1529 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Wildcard matching available in 2.0.41 and later</td></tr>
1530 </table>
1531     <p>This directive allows inclusion of other configuration files
1532     from within the server configuration files.</p>
1533
1534     <p>Shell-style (<code>fnmatch()</code>) wildcard characters can be used to
1535     include several files at once, in alphabetical order. In
1536     addition, if <code class="directive">Include</code> points to a directory,
1537     rather than a file, Apache will read all files in that directory
1538     and any subdirectory.  However, including entire directories is not
1539     recommended, because it is easy to accidentally leave temporary
1540     files in a directory that can cause <code class="program"><a href="../programs/httpd.html">httpd</a></code> to
1541     fail. Instead, we encourage you to use the wildcard syntax shown
1542     below, to include files that match a particular pattern, such as
1543     *.conf, for example.</p>
1544
1545     <p>The file path specified may be an absolute path, or may be relative 
1546     to the <code class="directive"><a href="#serverroot">ServerRoot</a></code> directory.</p>
1547
1548     <p>Examples:</p>
1549
1550     <div class="example"><p><code>
1551       Include /usr/local/apache2/conf/ssl.conf<br />
1552       Include /usr/local/apache2/conf/vhosts/*.conf
1553     </code></p></div>
1554
1555     <p>Or, providing paths relative to your <code class="directive"><a href="#serverroot">ServerRoot</a></code> directory:</p>
1556
1557     <div class="example"><p><code>
1558       Include conf/ssl.conf<br />
1559       Include conf/vhosts/*.conf
1560     </code></p></div>
1561
1562 <h3>See also</h3>
1563 <ul>
1564 <li><code class="program"><a href="../programs/apachectl.html">apachectl</a></code></li>
1565 </ul>
1566 </div>
1567 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1568 <div class="directive-section"><h2><a name="KeepAlive" id="KeepAlive">KeepAlive</a> <a name="keepalive" id="keepalive">Directive</a></h2>
1569 <table class="directive">
1570 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables HTTP persistent connections</td></tr>
1571 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>KeepAlive On|Off</code></td></tr>
1572 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>KeepAlive On</code></td></tr>
1573 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
1574 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1575 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1576 </table>
1577     <p>The Keep-Alive extension to HTTP/1.0 and the persistent
1578     connection feature of HTTP/1.1 provide long-lived HTTP sessions
1579     which allow multiple requests to be sent over the same TCP
1580     connection. In some cases this has been shown to result in an
1581     almost 50% speedup in latency times for HTML documents with
1582     many images. To enable Keep-Alive connections, set
1583     <code>KeepAlive On</code>.</p>
1584
1585     <p>For HTTP/1.0 clients, Keep-Alive connections will only be
1586     used if they are specifically requested by a client. In
1587     addition, a Keep-Alive connection with an HTTP/1.0 client can
1588     only be used when the length of the content is known in
1589     advance. This implies that dynamic content such as CGI output,
1590     SSI pages, and server-generated directory listings will
1591     generally not use Keep-Alive connections to HTTP/1.0 clients.
1592     For HTTP/1.1 clients, persistent connections are the default
1593     unless otherwise specified. If the client requests it, chunked
1594     encoding will be used in order to send content of unknown
1595     length over persistent connections.</p>
1596
1597     <p>When a client uses a Keep-Alive connection it will be counted
1598     as a single "request" for the <code class="directive"><a href="../mod/mpm_common.html#maxrequestsperchild">MaxRequestsPerChild</a></code> directive, regardless
1599     of how many requests are sent using the connection.</p>
1600
1601 <h3>See also</h3>
1602 <ul>
1603 <li><code class="directive"><a href="#maxkeepaliverequests">MaxKeepAliveRequests</a></code></li>
1604 </ul>
1605 </div>
1606 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1607 <div class="directive-section"><h2><a name="KeepAliveTimeout" id="KeepAliveTimeout">KeepAliveTimeout</a> <a name="keepalivetimeout" id="keepalivetimeout">Directive</a></h2>
1608 <table class="directive">
1609 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Amount of time the server will wait for subsequent
1610 requests on a persistent connection</td></tr>
1611 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>KeepAliveTimeout <var>num</var>[ms]</code></td></tr>
1612 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>KeepAliveTimeout 5</code></td></tr>
1613 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
1614 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1615 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1616 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Specifying a value in milliseconds is available in 
1617 Apache 2.3.2 and later</td></tr>
1618 </table>
1619     <p>The number of seconds Apache will wait for a subsequent
1620     request before closing the connection. By adding a postfix of ms the
1621     timeout can be also set in milliseconds. Once a request has been
1622     received, the timeout value specified by the
1623     <code class="directive"><a href="#timeout">Timeout</a></code> directive applies.</p>
1624
1625     <p>Setting <code class="directive">KeepAliveTimeout</code> to a high value
1626     may cause performance problems in heavily loaded servers. The
1627     higher the timeout, the more server processes will be kept
1628     occupied waiting on connections with idle clients.</p>
1629     
1630     <p>In a name-based virtual host context, the value of the first
1631     defined virtual host (the default host) in a set of <code class="directive"><a href="#namevirtualhost">NameVirtualHost</a></code> will be used.
1632     The other values will be ignored.</p>
1633
1634 </div>
1635 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1636 <div class="directive-section"><h2><a name="Limit" id="Limit">&lt;Limit&gt;</a> <a name="limit" id="limit">Directive</a></h2>
1637 <table class="directive">
1638 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restrict enclosed access controls to only certain HTTP
1639 methods</td></tr>
1640 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Limit <var>method</var> [<var>method</var>] ... &gt; ...
1641     &lt;/Limit&gt;</code></td></tr>
1642 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
1643 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig, Limit</td></tr>
1644 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1645 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1646 </table>
1647     <p>Access controls are normally effective for
1648     <strong>all</strong> access methods, and this is the usual
1649     desired behavior. <strong>In the general case, access control
1650     directives should not be placed within a
1651     <code class="directive">&lt;Limit&gt;</code> section.</strong></p>
1652
1653     <p>The purpose of the <code class="directive">&lt;Limit&gt;</code>
1654     directive is to restrict the effect of the access controls to the
1655     nominated HTTP methods. For all other methods, the access
1656     restrictions that are enclosed in the <code class="directive">&lt;Limit&gt;</code> bracket <strong>will have no
1657     effect</strong>. The following example applies the access control
1658     only to the methods <code>POST</code>, <code>PUT</code>, and
1659     <code>DELETE</code>, leaving all other methods unprotected:</p>
1660
1661     <div class="example"><p><code>
1662       &lt;Limit POST PUT DELETE&gt;<br />
1663       <span class="indent">
1664         Require valid-user<br />
1665       </span>
1666       &lt;/Limit&gt;
1667     </code></p></div>
1668
1669     <p>The method names listed can be one or more of: <code>GET</code>,
1670     <code>POST</code>, <code>PUT</code>, <code>DELETE</code>,
1671     <code>CONNECT</code>, <code>OPTIONS</code>,
1672     <code>PATCH</code>, <code>PROPFIND</code>, <code>PROPPATCH</code>,
1673     <code>MKCOL</code>, <code>COPY</code>, <code>MOVE</code>,
1674     <code>LOCK</code>, and <code>UNLOCK</code>. <strong>The method name is
1675     case-sensitive.</strong> If <code>GET</code> is used it will also
1676     restrict <code>HEAD</code> requests. The <code>TRACE</code> method
1677     cannot be limited (see <code class="directive"><a href="#traceenable">TraceEnable</a></code>).</p>
1678
1679     <div class="warning">A <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> section should always be
1680     used in preference to a <code class="directive">&lt;Limit&gt;</code>
1681     section when restricting access, since a <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> section provides protection
1682     against arbitrary methods.</div>
1683
1684     <p>The <code class="directive">&lt;Limit&gt;</code> and
1685     <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code>
1686     directives may be nested.  In this case, each successive level of
1687     <code class="directive">&lt;Limit&gt;</code> or <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> directives must
1688     further restrict the set of methods to which access controls apply.</p>
1689
1690     <div class="warning">When using
1691     <code class="directive">&lt;Limit&gt;</code> or
1692     <code class="directive">&lt;LimitExcept&gt;</code> directives with
1693     the <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code> directive,
1694     note that the first <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>
1695     to succeed authorizes the request, regardless of the presence of other
1696     <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code> directives.</div>
1697
1698     <p>For example, given the following configuration, all users will
1699     be authorized for <code>POST</code> requests, and the
1700     <code>Require group editors</code> directive will be ignored
1701     in all cases:</p>
1702
1703     <div class="example"><p><code>
1704       &lt;LimitExcept GET&gt;
1705       <span class="indent">
1706         Require valid-user
1707       </span> 
1708       &lt;/LimitExcept&gt;<br />
1709       &lt;Limit POST&gt;
1710       <span class="indent">
1711         Require group editors
1712       </span> 
1713       &lt;/Limit&gt;
1714     </code></p></div>
1715
1716 </div>
1717 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1718 <div class="directive-section"><h2><a name="LimitExcept" id="LimitExcept">&lt;LimitExcept&gt;</a> <a name="limitexcept" id="limitexcept">Directive</a></h2>
1719 <table class="directive">
1720 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restrict access controls to all HTTP methods
1721 except the named ones</td></tr>
1722 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;LimitExcept <var>method</var> [<var>method</var>] ... &gt; ...
1723     &lt;/LimitExcept&gt;</code></td></tr>
1724 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
1725 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig, Limit</td></tr>
1726 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1727 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1728 </table>
1729     <p><code class="directive">&lt;LimitExcept&gt;</code> and
1730     <code>&lt;/LimitExcept&gt;</code> are used to enclose
1731     a group of access control directives which will then apply to any
1732     HTTP access method <strong>not</strong> listed in the arguments;
1733     i.e., it is the opposite of a <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code> section and can be used to control
1734     both standard and nonstandard/unrecognized methods. See the
1735     documentation for <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code> for more details.</p>
1736
1737     <p>For example:</p>
1738
1739     <div class="example"><p><code>
1740       &lt;LimitExcept POST GET&gt;<br />
1741       <span class="indent">
1742         Require valid-user<br />
1743       </span>
1744       &lt;/LimitExcept&gt;
1745     </code></p></div>
1746
1747
1748 </div>
1749 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1750 <div class="directive-section"><h2><a name="LimitInternalRecursion" id="LimitInternalRecursion">LimitInternalRecursion</a> <a name="limitinternalrecursion" id="limitinternalrecursion">Directive</a></h2>
1751 <table class="directive">
1752 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Determine maximum number of internal redirects and nested
1753 subrequests</td></tr>
1754 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitInternalRecursion <var>number</var> [<var>number</var>]</code></td></tr>
1755 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitInternalRecursion 10</code></td></tr>
1756 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
1757 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1758 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1759 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.47 and later</td></tr>
1760 </table>
1761     <p>An internal redirect happens, for example, when using the <code class="directive"><a href="../mod/mod_actions.html#action">Action</a></code> directive, which internally
1762     redirects the original request to a CGI script. A subrequest is Apache's
1763     mechanism to find out what would happen for some URI if it were requested.
1764     For example, <code class="module"><a href="../mod/mod_dir.html">mod_dir</a></code> uses subrequests to look for the
1765     files listed in the <code class="directive"><a href="../mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>
1766     directive.</p>
1767
1768     <p><code class="directive">LimitInternalRecursion</code> prevents the server
1769     from crashing when entering an infinite loop of internal redirects or
1770     subrequests. Such loops are usually caused by misconfigurations.</p>
1771
1772     <p>The directive stores two different limits, which are evaluated on
1773     per-request basis. The first <var>number</var> is the maximum number of
1774     internal redirects, that may follow each other. The second <var>number</var>
1775     determines, how deep subrequests may be nested. If you specify only one
1776     <var>number</var>, it will be assigned to both limits.</p>
1777
1778     <div class="example"><h3>Example</h3><p><code>
1779       LimitInternalRecursion 5
1780     </code></p></div>
1781
1782 </div>
1783 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1784 <div class="directive-section"><h2><a name="LimitRequestBody" id="LimitRequestBody">LimitRequestBody</a> <a name="limitrequestbody" id="limitrequestbody">Directive</a></h2>
1785 <table class="directive">
1786 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restricts the total size of the HTTP request body sent
1787 from the client</td></tr>
1788 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestBody <var>bytes</var></code></td></tr>
1789 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestBody 0</code></td></tr>
1790 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1791 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1792 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1793 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1794 </table>
1795     <p>This directive specifies the number of <var>bytes</var> from 0
1796     (meaning unlimited) to 2147483647 (2GB) that are allowed in a
1797     request body.</p>
1798
1799     <p>The <code class="directive">LimitRequestBody</code> directive allows
1800     the user to set a limit on the allowed size of an HTTP request
1801     message body within the context in which the directive is given
1802     (server, per-directory, per-file or per-location). If the client
1803     request exceeds that limit, the server will return an error
1804     response instead of servicing the request. The size of a normal
1805     request message body will vary greatly depending on the nature of
1806     the resource and the methods allowed on that resource. CGI scripts
1807     typically use the message body for retrieving form information.
1808     Implementations of the <code>PUT</code> method will require
1809     a value at least as large as any representation that the server
1810     wishes to accept for that resource.</p>
1811
1812     <p>This directive gives the server administrator greater
1813     control over abnormal client request behavior, which may be
1814     useful for avoiding some forms of denial-of-service
1815     attacks.</p>
1816
1817     <p>If, for example, you are permitting file upload to a particular
1818     location, and wish to limit the size of the uploaded file to 100K,
1819     you might use the following directive:</p>
1820
1821     <div class="example"><p><code>
1822       LimitRequestBody 102400
1823     </code></p></div>
1824
1825
1826 </div>
1827 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1828 <div class="directive-section"><h2><a name="LimitRequestFields" id="LimitRequestFields">LimitRequestFields</a> <a name="limitrequestfields" id="limitrequestfields">Directive</a></h2>
1829 <table class="directive">
1830 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the number of HTTP request header fields that
1831 will be accepted from the client</td></tr>
1832 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestFields <var>number</var></code></td></tr>
1833 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestFields 100</code></td></tr>
1834 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
1835 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1836 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1837 </table>
1838     <p><var>Number</var> is an integer from 0 (meaning unlimited) to
1839     32767. The default value is defined by the compile-time
1840     constant <code>DEFAULT_LIMIT_REQUEST_FIELDS</code> (100 as
1841     distributed).</p>
1842
1843     <p>The <code class="directive">LimitRequestFields</code> directive allows
1844     the server administrator to modify the limit on the number of
1845     request header fields allowed in an HTTP request. A server needs
1846     this value to be larger than the number of fields that a normal
1847     client request might include. The number of request header fields
1848     used by a client rarely exceeds 20, but this may vary among
1849     different client implementations, often depending upon the extent
1850     to which a user has configured their browser to support detailed
1851     content negotiation. Optional HTTP extensions are often expressed
1852     using request header fields.</p>
1853
1854     <p>This directive gives the server administrator greater
1855     control over abnormal client request behavior, which may be
1856     useful for avoiding some forms of denial-of-service attacks.
1857     The value should be increased if normal clients see an error
1858     response from the server that indicates too many fields were
1859     sent in the request.</p>
1860
1861     <p>For example:</p>
1862
1863     <div class="example"><p><code>
1864       LimitRequestFields 50
1865     </code></p></div>
1866
1867
1868 </div>
1869 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1870 <div class="directive-section"><h2><a name="LimitRequestFieldSize" id="LimitRequestFieldSize">LimitRequestFieldSize</a> <a name="limitrequestfieldsize" id="limitrequestfieldsize">Directive</a></h2>
1871 <table class="directive">
1872 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the size of the HTTP request header allowed from the
1873 client</td></tr>
1874 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestFieldSize <var>bytes</var></code></td></tr>
1875 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestFieldSize 8190</code></td></tr>
1876 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
1877 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1878 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1879 </table>
1880     <p>This directive specifies the number of <var>bytes</var>
1881     that will be allowed in an HTTP request header.</p>
1882
1883     <p>The <code class="directive">LimitRequestFieldSize</code> directive
1884     allows the server administrator to reduce or increase the limit 
1885     on the allowed size of an HTTP request header field. A server
1886     needs this value to be large enough to hold any one header field 
1887     from a normal client request. The size of a normal request header 
1888     field will vary greatly among different client implementations, 
1889     often depending upon the extent to which a user has configured
1890     their browser to support detailed content negotiation. SPNEGO
1891     authentication headers can be up to 12392 bytes.</p>
1892
1893     <p>This directive gives the server administrator greater
1894     control over abnormal client request behavior, which may be
1895     useful for avoiding some forms of denial-of-service attacks.</p>
1896
1897     <p>For example:</p>
1898
1899     <div class="example"><p><code>
1900       LimitRequestFieldSize 4094
1901     </code></p></div>
1902
1903     <div class="note">Under normal conditions, the value should not be changed from
1904     the default.</div>
1905
1906
1907 </div>
1908 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1909 <div class="directive-section"><h2><a name="LimitRequestLine" id="LimitRequestLine">LimitRequestLine</a> <a name="limitrequestline" id="limitrequestline">Directive</a></h2>
1910 <table class="directive">
1911 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limit the size of the HTTP request line that will be accepted
1912 from the client</td></tr>
1913 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestLine <var>bytes</var></code></td></tr>
1914 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestLine 8190</code></td></tr>
1915 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
1916 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1917 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1918 </table>
1919     <p>This directive sets the number of <var>bytes</var> that will be 
1920     allowed on the HTTP request-line.</p>
1921
1922     <p>The <code class="directive">LimitRequestLine</code> directive allows
1923     the server administrator to reduce or increase the limit on the allowed size
1924     of a client's HTTP request-line. Since the request-line consists of the
1925     HTTP method, URI, and protocol version, the
1926     <code class="directive">LimitRequestLine</code> directive places a
1927     restriction on the length of a request-URI allowed for a request
1928     on the server. A server needs this value to be large enough to
1929     hold any of its resource names, including any information that
1930     might be passed in the query part of a <code>GET</code> request.</p>
1931
1932     <p>This directive gives the server administrator greater
1933     control over abnormal client request behavior, which may be
1934     useful for avoiding some forms of denial-of-service attacks.</p>
1935
1936     <p>For example:</p>
1937
1938     <div class="example"><p><code>
1939       LimitRequestLine 4094
1940     </code></p></div>
1941
1942     <div class="note">Under normal conditions, the value should not be changed from
1943     the default.</div>
1944
1945 </div>
1946 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1947 <div class="directive-section"><h2><a name="LimitXMLRequestBody" id="LimitXMLRequestBody">LimitXMLRequestBody</a> <a name="limitxmlrequestbody" id="limitxmlrequestbody">Directive</a></h2>
1948 <table class="directive">
1949 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the size of an XML-based request body</td></tr>
1950 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitXMLRequestBody <var>bytes</var></code></td></tr>
1951 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitXMLRequestBody 1000000</code></td></tr>
1952 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1953 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1954 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1955 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1956 </table>
1957     <p>Limit (in bytes) on maximum size of an XML-based request
1958     body. A value of <code>0</code> will disable any checking.</p>
1959
1960     <p>Example:</p>
1961
1962     <div class="example"><p><code>
1963       LimitXMLRequestBody 0
1964     </code></p></div>
1965
1966
1967 </div>
1968 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
1969 <div class="directive-section"><h2><a name="Location" id="Location">&lt;Location&gt;</a> <a name="location" id="location">Directive</a></h2>
1970 <table class="directive">
1971 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Applies the enclosed directives only to matching
1972 URLs</td></tr>
1973 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Location
1974     <var>URL-path</var>|<var>URL</var>&gt; ... &lt;/Location&gt;</code></td></tr>
1975 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
1976 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1977 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1978 </table>
1979     <p>The <code class="directive">&lt;Location&gt;</code> directive
1980     limits the scope of the enclosed directives by URL. It is similar to the
1981     <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
1982     directive, and starts a subsection which is terminated with a
1983     <code>&lt;/Location&gt;</code> directive. <code class="directive">&lt;Location&gt;</code> sections are processed in the
1984     order they appear in the configuration file, after the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections and
1985     <code>.htaccess</code> files are read, and after the <code class="directive"><a href="#files">&lt;Files&gt;</a></code> sections.</p>
1986
1987     <p><code class="directive">&lt;Location&gt;</code> sections operate
1988     completely outside the filesystem.  This has several consequences.
1989     Most importantly, <code class="directive">&lt;Location&gt;</code>
1990     directives should not be used to control access to filesystem
1991     locations.  Since several different URLs may map to the same
1992     filesystem location, such access controls may by circumvented.</p>
1993
1994     <div class="note"><h3>When to use <code class="directive">&lt;Location&gt;</code></h3>
1995
1996     <p>Use <code class="directive">&lt;Location&gt;</code> to apply
1997     directives to content that lives outside the filesystem.  For
1998     content that lives in the filesystem, use <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> and <code class="directive"><a href="#files">&lt;Files&gt;</a></code>.  An exception is
1999     <code>&lt;Location /&gt;</code>, which is an easy way to 
2000     apply a configuration to the entire server.</p>
2001     </div>
2002
2003     <p>For all origin (non-proxy) requests, the URL to be matched is a
2004     URL-path of the form <code>/path/</code>.  <em>No scheme, hostname,
2005     port, or query string may be included.</em>  For proxy requests, the
2006     URL to be matched is of the form
2007     <code>scheme://servername/path</code>, and you must include the
2008     prefix.</p>
2009
2010     <p>The URL may use wildcards. In a wild-card string, <code>?</code> matches
2011     any single character, and <code>*</code> matches any sequences of
2012     characters. Neither wildcard character matches a / in the URL-path.</p>
2013
2014     <p><a class="glossarylink" href="../glossary.html#regex" title="see glossary">Regular expressions</a>
2015     can also be used, with the addition of the <code>~</code> 
2016     character. For example:</p>
2017
2018     <div class="example"><p><code>
2019       &lt;Location ~ "/(extra|special)/data"&gt;
2020     </code></p></div>
2021
2022     <p>would match URLs that contained the substring <code>/extra/data</code>
2023     or <code>/special/data</code>. The directive <code class="directive"><a href="#locationmatch">&lt;LocationMatch&gt;</a></code> behaves
2024     identical to the regex version of <code class="directive">&lt;Location&gt;</code>, and is preferred, for the
2025     simple reason that <code>~</code> is hard to distinguish from
2026     <code>-</code> in many fonts.</p>
2027
2028     <p>The <code class="directive">&lt;Location&gt;</code>
2029     functionality is especially useful when combined with the
2030     <code class="directive"><a href="#sethandler">SetHandler</a></code>
2031     directive. For example, to enable status requests, but allow them
2032     only from browsers at <code>example.com</code>, you might use:</p>
2033
2034     <div class="example"><p><code>
2035       &lt;Location /status&gt;<br />
2036       <span class="indent">
2037         SetHandler server-status<br />
2038         Order Deny,Allow<br />
2039         Deny from all<br />
2040         Allow from .example.com<br />
2041       </span>
2042       &lt;/Location&gt;
2043     </code></p></div>
2044
2045     <div class="note"><h3>Note about / (slash)</h3>
2046       <p>The slash character has special meaning depending on where in a
2047       URL it appears. People may be used to its behavior in the filesystem
2048       where multiple adjacent slashes are frequently collapsed to a single
2049       slash (<em>i.e.</em>, <code>/home///foo</code> is the same as
2050       <code>/home/foo</code>). In URL-space this is not necessarily true.
2051       The <code class="directive"><a href="#locationmatch">&lt;LocationMatch&gt;</a></code>
2052       directive and the regex version of <code class="directive">&lt;Location&gt;</code> require you to explicitly specify multiple
2053       slashes if that is your intention.</p>
2054
2055       <p>For example, <code>&lt;LocationMatch ^/abc&gt;</code> would match
2056       the request URL <code>/abc</code> but not the request URL <code>
2057       //abc</code>. The (non-regex) <code class="directive">&lt;Location&gt;</code> directive behaves similarly when used for
2058       proxy requests. But when (non-regex) <code class="directive">&lt;Location&gt;</code> is used for non-proxy requests it will
2059       implicitly match multiple slashes with a single slash. For example,
2060       if you specify <code>&lt;Location /abc/def&gt;</code> and the
2061       request is to <code>/abc//def</code> then it will match.</p>
2062     </div>
2063
2064 <h3>See also</h3>
2065 <ul>
2066 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;
2067     and &lt;Files&gt; sections work</a> for an explanation of how these
2068     different sections are combined when a request is received.</li>
2069 <li><code class="directive"><a href="#locationmatch">LocationMatch</a></code></li>
2070 </ul>
2071 </div>
2072 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2073 <div class="directive-section"><h2><a name="LocationMatch" id="LocationMatch">&lt;LocationMatch&gt;</a> <a name="locationmatch" id="locationmatch">Directive</a></h2>
2074 <table class="directive">
2075 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Applies the enclosed directives only to regular-expression
2076 matching URLs</td></tr>
2077 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;LocationMatch
2078     <var>regex</var>&gt; ... &lt;/LocationMatch&gt;</code></td></tr>
2079 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
2080 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2081 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2082 </table>
2083     <p>The <code class="directive">&lt;LocationMatch&gt;</code> directive
2084     limits the scope of the enclosed directives by URL, in an identical manner
2085     to <code class="directive"><a href="#location">&lt;Location&gt;</a></code>. However,
2086     it takes a <a class="glossarylink" href="../glossary.html#regex" title="see glossary">regular expression</a>
2087     as an argument instead of a simple string. For example:</p>
2088
2089     <div class="example"><p><code>
2090       &lt;LocationMatch "/(extra|special)/data"&gt;
2091     </code></p></div>
2092
2093     <p>would match URLs that contained the substring <code>/extra/data</code>
2094     or <code>/special/data</code>.</p>
2095
2096 <h3>See also</h3>
2097 <ul>
2098 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;
2099     and &lt;Files&gt; sections work</a> for an explanation of how these
2100     different sections are combined when a request is received</li>
2101 </ul>
2102 </div>
2103 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2104 <div class="directive-section"><h2><a name="LogLevel" id="LogLevel">LogLevel</a> <a name="loglevel" id="loglevel">Directive</a></h2>
2105 <table class="directive">
2106 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Controls the verbosity of the ErrorLog</td></tr>
2107 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LogLevel <var>level</var></code></td></tr>
2108 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LogLevel warn</code></td></tr>
2109 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
2110 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2111 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2112 </table>
2113     <p><code class="directive">LogLevel</code> adjusts the verbosity of the
2114     messages recorded in the error logs (see <code class="directive"><a href="#errorlog">ErrorLog</a></code> directive). The following
2115     <var>level</var>s are available, in order of decreasing
2116     significance:</p>
2117
2118     <table class="bordered">
2119     
2120       <tr>
2121         <th><strong>Level</strong> </th>
2122
2123         <th><strong>Description</strong> </th>
2124
2125         <th><strong>Example</strong> </th>
2126       </tr>
2127
2128       <tr>
2129         <td><code>emerg</code> </td>
2130
2131         <td>Emergencies - system is unusable.</td>
2132
2133         <td>"Child cannot open lock file. Exiting"</td>
2134       </tr>
2135
2136       <tr>
2137         <td><code>alert</code> </td>
2138
2139         <td>Action must be taken immediately.</td>
2140
2141         <td>"getpwuid: couldn't determine user name from uid"</td>
2142       </tr>
2143
2144       <tr>
2145         <td><code>crit</code> </td>
2146
2147         <td>Critical Conditions.</td>
2148
2149         <td>"socket: Failed to get a socket, exiting child"</td>
2150       </tr>
2151
2152       <tr>
2153         <td><code>error</code> </td>
2154
2155         <td>Error conditions.</td>
2156
2157         <td>"Premature end of script headers"</td>
2158       </tr>
2159
2160       <tr>
2161         <td><code>warn</code> </td>
2162
2163         <td>Warning conditions.</td>
2164
2165         <td>"child process 1234 did not exit, sending another
2166         SIGHUP"</td>
2167       </tr>
2168
2169       <tr>
2170         <td><code>notice</code> </td>
2171
2172         <td>Normal but significant condition.</td>
2173
2174         <td>"httpd: caught SIGBUS, attempting to dump core in
2175         ..."</td>
2176       </tr>
2177
2178       <tr>
2179         <td><code>info</code> </td>
2180
2181         <td>Informational.</td>
2182
2183         <td>"Server seems busy, (you may need to increase
2184         StartServers, or Min/MaxSpareServers)..."</td>
2185       </tr>
2186
2187       <tr>
2188         <td><code>debug</code> </td>
2189
2190         <td>Debug-level messages</td>
2191
2192         <td>"Opening config file ..."</td>
2193       </tr>
2194     </table>
2195
2196     <p>When a particular level is specified, messages from all
2197     other levels of higher significance will be reported as well.
2198     <em>E.g.</em>, when <code>LogLevel info</code> is specified,
2199     then messages with log levels of <code>notice</code> and
2200     <code>warn</code> will also be posted.</p>
2201
2202     <p>Using a level of at least <code>crit</code> is
2203     recommended.</p>
2204
2205     <p>For example:</p>
2206
2207     <div class="example"><p><code>
2208       LogLevel notice
2209     </code></p></div>
2210
2211     <div class="note"><h3>Note</h3>
2212       <p>When logging to a regular file messages of the level
2213       <code>notice</code> cannot be suppressed and thus are always
2214       logged. However, this doesn't apply when logging is done
2215       using <code>syslog</code>.</p>
2216     </div>
2217
2218 </div>
2219 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2220 <div class="directive-section"><h2><a name="MaxKeepAliveRequests" id="MaxKeepAliveRequests">MaxKeepAliveRequests</a> <a name="maxkeepaliverequests" id="maxkeepaliverequests">Directive</a></h2>
2221 <table class="directive">
2222 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Number of requests allowed on a persistent
2223 connection</td></tr>
2224 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxKeepAliveRequests <var>number</var></code></td></tr>
2225 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>MaxKeepAliveRequests 100</code></td></tr>
2226 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
2227 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2228 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2229 </table>
2230     <p>The <code class="directive">MaxKeepAliveRequests</code> directive
2231     limits the number of requests allowed per connection when
2232     <code class="directive"><a href="#keepalive">KeepAlive</a></code> is on. If it is
2233     set to <code>0</code>, unlimited requests will be allowed. We
2234     recommend that this setting be kept to a high value for maximum
2235     server performance.</p>
2236
2237     <p>For example:</p>
2238
2239     <div class="example"><p><code>
2240       MaxKeepAliveRequests 500
2241     </code></p></div>
2242
2243 </div>
2244 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2245 <div class="directive-section"><h2><a name="NameVirtualHost" id="NameVirtualHost">NameVirtualHost</a> <a name="namevirtualhost" id="namevirtualhost">Directive</a></h2>
2246 <table class="directive">
2247 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Designates an IP address for name-virtual
2248 hosting</td></tr>
2249 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>NameVirtualHost <var>addr</var>[:<var>port</var>]</code></td></tr>
2250 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2251 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2252 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2253 </table>
2254
2255 <p>A single <code class="directive">NameVirtualHost</code> directive 
2256 identifies a set of identical virtual hosts on which the server will  
2257 further select from on the basis of the <em>hostname</em> 
2258 requested by the client.  The <code class="directive">NameVirtualHost</code>
2259 directive is a required directive if you want to configure 
2260 <a href="../vhosts/">name-based virtual hosts</a>.</p>
2261
2262 <p>This directive, and the corresponding <code class="directive">VirtualHost</code>,
2263 <em>must</em> be qualified with a port number if the server supports both HTTP 
2264 and HTTPS connections.</p>
2265
2266 <p>Although <var>addr</var> can be a hostname, it is recommended
2267 that you always use an IP address or a wildcard.  A wildcard
2268 NameVirtualHost matches only virtualhosts that also have a literal wildcard
2269 as their argument.</p>
2270
2271 <p>In cases where a firewall or other proxy receives the requests and 
2272 forwards them on a different IP address to the server, you must specify the
2273 IP address of the physical interface on the machine which will be
2274 servicing the requests. </p>
2275
2276 <p> In the example below, requests received on interface 192.0.2.1 and port 80 
2277 will only select among the first two virtual hosts. Requests received on
2278 port 80 on any other interface will only select among the third and fourth
2279 virtual hosts. In the common case where the interface isn't important 
2280 to the mapping, only the "*:80" NameVirtualHost and VirtualHost directives 
2281 are necessary.</p>
2282
2283    <div class="example"><p><code>
2284       NameVirtualHost 192.0.2.1:80<br />
2285       NameVirtualHost *:80<br /><br />
2286
2287       &lt;VirtualHost 192.0.2.1:80&gt;<br />
2288       &nbsp; ServerName namebased-a.example.com<br />
2289       &lt;/VirtualHost&gt;<br />
2290       <br />
2291       &lt;VirtualHost 192.0.2.1:80&gt;<br />
2292       &nbsp; Servername namebased-b.example.com<br />
2293       &lt;/VirtualHost&gt;<br />
2294       <br />
2295       &lt;VirtualHost *:80&gt;<br />
2296       &nbsp; ServerName namebased-c.example.com <br />
2297       &lt;/VirtualHost&gt;<br />
2298       <br />
2299       &lt;VirtualHost *:80&gt;<br />
2300       &nbsp; ServerName namebased-d.example.com <br />
2301       &lt;/VirtualHost&gt;<br />
2302       <br />
2303
2304     </code></p></div>
2305
2306     <p>IPv6 addresses must be enclosed in square brackets, as shown
2307     in the following example:</p>
2308
2309     <div class="example"><p><code>
2310       NameVirtualHost [2001:db8::a00:20ff:fea7:ccea]:8080
2311     </code></p></div>
2312
2313     <div class="note"><h3>Argument to <code class="directive">&lt;VirtualHost&gt;</code>
2314       directive</h3>
2315       <p>Note that the argument to the <code class="directive">&lt;VirtualHost&gt;</code> directive must
2316       exactly match the argument to the <code class="directive">NameVirtualHost</code> directive.</p>
2317
2318       <div class="example"><p><code>
2319         NameVirtualHost 192.0.2.2:80<br />
2320         &lt;VirtualHost 192.0.2.2:80&gt;<br />
2321         # ...<br />
2322         &lt;/VirtualHost&gt;<br />
2323       </code></p></div>
2324     </div>
2325
2326 <h3>See also</h3>
2327 <ul>
2328 <li><a href="../vhosts/">Virtual Hosts
2329 documentation</a></li>
2330 </ul>
2331 </div>
2332 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2333 <div class="directive-section"><h2><a name="Options" id="Options">Options</a> <a name="options" id="options">Directive</a></h2>
2334 <table class="directive">
2335 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures what features are available in a particular
2336 directory</td></tr>
2337 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Options
2338     [+|-]<var>option</var> [[+|-]<var>option</var>] ...</code></td></tr>
2339 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Options All</code></td></tr>
2340 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2341 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Options</td></tr>
2342 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2343 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2344 </table>
2345     <p>The <code class="directive">Options</code> directive controls which
2346     server features are available in a particular directory.</p>
2347
2348     <p><var>option</var> can be set to <code>None</code>, in which
2349     case none of the extra features are enabled, or one or more of
2350     the following:</p>
2351
2352     <dl>
2353       <dt><code>All</code></dt>
2354
2355       <dd>All options except for <code>MultiViews</code>. This is the default
2356       setting.</dd>
2357
2358       <dt><code>ExecCGI</code></dt>
2359
2360       <dd>
2361       Execution of CGI scripts using <code class="module"><a href="../mod/mod_cgi.html">mod_cgi</a></code>
2362       is permitted.</dd>
2363
2364       <dt><code>FollowSymLinks</code></dt>
2365
2366       <dd>
2367
2368       The server will follow symbolic links in this directory.
2369       <div class="note">
2370       <p>Even though the server follows the symlink it does <em>not</em>
2371       change the pathname used to match against <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections.</p>
2372       <p>Note also, that this option <strong>gets ignored</strong> if set
2373       inside a <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
2374       section.</p>
2375       <p>Omitting this option should not be considered a security restriction,
2376       since symlink testing is subject to race conditions that make it
2377       circumventable.</p>
2378       </div></dd>
2379
2380       <dt><code>Includes</code></dt>
2381
2382       <dd>
2383       Server-side includes provided by <code class="module"><a href="../mod/mod_include.html">mod_include</a></code>
2384       are permitted.</dd>
2385
2386       <dt><code>IncludesNOEXEC</code></dt>
2387
2388       <dd>
2389
2390       Server-side includes are permitted, but the <code>#exec
2391       cmd</code> and <code>#exec cgi</code> are disabled. It is still
2392       possible to <code>#include virtual</code> CGI scripts from
2393       <code class="directive"><a href="../mod/mod_alias.html#scriptalias">ScriptAlias</a></code>ed
2394       directories.</dd>
2395
2396       <dt><code>Indexes</code></dt>
2397
2398       <dd>
2399       If a URL which maps to a directory is requested, and there
2400       is no <code class="directive"><a href="../mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>
2401       (<em>e.g.</em>, <code>index.html</code>) in that directory, then
2402       <code class="module"><a href="../mod/mod_autoindex.html">mod_autoindex</a></code> will return a formatted listing
2403       of the directory.</dd>
2404
2405       <dt><code>MultiViews</code></dt>
2406
2407       <dd>
2408       <a href="../content-negotiation.html">Content negotiated</a>
2409       "MultiViews" are allowed using
2410       <code class="module"><a href="../mod/mod_negotiation.html">mod_negotiation</a></code>.</dd>
2411
2412       <dt><code>SymLinksIfOwnerMatch</code></dt>
2413
2414       <dd>The server will only follow symbolic links for which the
2415       target file or directory is owned by the same user id as the
2416       link.
2417
2418       <div class="note"><h3>Note</h3> <p>This option gets ignored if
2419       set inside a <code class="directive"><a href="#location">&lt;Location&gt;</a></code> section.</p>
2420       <p>This option should not be considered a security restriction,
2421       since symlink testing is subject to race conditions that make it
2422       circumventable.</p></div>
2423       </dd>
2424     </dl>
2425
2426     <p>Normally, if multiple <code class="directive">Options</code> could
2427     apply to a directory, then the most specific one is used and
2428     others are ignored; the options are not merged. (See <a href="../sections.html#mergin">how sections are merged</a>.)
2429     However if <em>all</em> the options on the
2430     <code class="directive">Options</code> directive are preceded by a
2431     <code>+</code> or <code>-</code> symbol, the options are
2432     merged. Any options preceded by a <code>+</code> are added to the
2433     options currently in force, and any options preceded by a
2434     <code>-</code> are removed from the options currently in
2435     force. </p>
2436
2437     <div class="warning"><h3>Warning</h3>
2438     <p>Mixing <code class="directive">Options</code> with a <code>+</code> or
2439     <code>-</code> with those without is not valid syntax, and is likely
2440     to cause unexpected results.</p>
2441     </div>
2442
2443     <p>For example, without any <code>+</code> and <code>-</code> symbols:</p>
2444
2445     <div class="example"><p><code>
2446       &lt;Directory /web/docs&gt;<br />
2447       <span class="indent">
2448         Options Indexes FollowSymLinks<br />
2449       </span>
2450       &lt;/Directory&gt;<br />
2451       <br />
2452       &lt;Directory /web/docs/spec&gt;<br />
2453       <span class="indent">
2454         Options Includes<br />
2455       </span>
2456       &lt;/Directory&gt;
2457     </code></p></div>
2458
2459     <p>then only <code>Includes</code> will be set for the
2460     <code>/web/docs/spec</code> directory. However if the second
2461     <code class="directive">Options</code> directive uses the <code>+</code> and
2462     <code>-</code> symbols:</p>
2463
2464     <div class="example"><p><code>
2465       &lt;Directory /web/docs&gt;<br />
2466       <span class="indent">
2467         Options Indexes FollowSymLinks<br />
2468       </span>
2469       &lt;/Directory&gt;<br />
2470       <br />
2471       &lt;Directory /web/docs/spec&gt;<br />
2472       <span class="indent">
2473         Options +Includes -Indexes<br />
2474       </span>
2475       &lt;/Directory&gt;
2476     </code></p></div>
2477
2478     <p>then the options <code>FollowSymLinks</code> and
2479     <code>Includes</code> are set for the <code>/web/docs/spec</code>
2480     directory.</p>
2481
2482     <div class="note"><h3>Note</h3>
2483       <p>Using <code>-IncludesNOEXEC</code> or
2484       <code>-Includes</code> disables server-side includes completely
2485       regardless of the previous setting.</p>
2486     </div>
2487
2488     <p>The default in the absence of any other settings is
2489     <code>All</code>.</p>
2490
2491 </div>
2492 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2493 <div class="directive-section"><h2><a name="RLimitCPU" id="RLimitCPU">RLimitCPU</a> <a name="rlimitcpu" id="rlimitcpu">Directive</a></h2>
2494 <table class="directive">
2495 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the CPU consumption of processes launched
2496 by Apache children</td></tr>
2497 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>RLimitCPU <var>seconds</var>|max [<var>seconds</var>|max]</code></td></tr>
2498 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
2499 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2500 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
2501 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2502 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2503 </table>
2504     <p>Takes 1 or 2 parameters. The first parameter sets the soft
2505     resource limit for all processes and the second parameter sets
2506     the maximum resource limit. Either parameter can be a number,
2507     or <code>max</code> to indicate to the server that the limit should
2508     be set to the maximum allowed by the operating system
2509     configuration. Raising the maximum resource limit requires that
2510     the server is running as <code>root</code>, or in the initial startup
2511     phase.</p>
2512
2513     <p>This applies to processes forked off from Apache children
2514     servicing requests, not the Apache children themselves. This
2515     includes CGI scripts and SSI exec commands, but not any
2516     processes forked off from the Apache parent such as piped
2517     logs.</p>
2518
2519     <p>CPU resource limits are expressed in seconds per
2520     process.</p>
2521
2522 <h3>See also</h3>
2523 <ul>
2524 <li><code class="directive"><a href="#rlimitmem">RLimitMEM</a></code></li>
2525 <li><code class="directive"><a href="#rlimitnproc">RLimitNPROC</a></code></li>
2526 </ul>
2527 </div>
2528 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2529 <div class="directive-section"><h2><a name="RLimitMEM" id="RLimitMEM">RLimitMEM</a> <a name="rlimitmem" id="rlimitmem">Directive</a></h2>
2530 <table class="directive">
2531 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the memory consumption of processes launched
2532 by Apache children</td></tr>
2533 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>RLimitMEM <var>bytes</var>|max [<var>bytes</var>|max]</code></td></tr>
2534 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
2535 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2536 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
2537 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2538 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2539 </table>
2540     <p>Takes 1 or 2 parameters. The first parameter sets the soft
2541     resource limit for all processes and the second parameter sets
2542     the maximum resource limit. Either parameter can be a number,
2543     or <code>max</code> to indicate to the server that the limit should
2544     be set to the maximum allowed by the operating system
2545     configuration. Raising the maximum resource limit requires that
2546     the server is running as <code>root</code>, or in the initial startup
2547     phase.</p>
2548
2549     <p>This applies to processes forked off from Apache children
2550     servicing requests, not the Apache children themselves. This
2551     includes CGI scripts and SSI exec commands, but not any
2552     processes forked off from the Apache parent such as piped
2553     logs.</p>
2554
2555     <p>Memory resource limits are expressed in bytes per
2556     process.</p>
2557
2558 <h3>See also</h3>
2559 <ul>
2560 <li><code class="directive"><a href="#rlimitcpu">RLimitCPU</a></code></li>
2561 <li><code class="directive"><a href="#rlimitnproc">RLimitNPROC</a></code></li>
2562 </ul>
2563 </div>
2564 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2565 <div class="directive-section"><h2><a name="RLimitNPROC" id="RLimitNPROC">RLimitNPROC</a> <a name="rlimitnproc" id="rlimitnproc">Directive</a></h2>
2566 <table class="directive">
2567 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the number of processes that can be launched by
2568 processes launched by Apache children</td></tr>
2569 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>RLimitNPROC <var>number</var>|max [<var>number</var>|max]</code></td></tr>
2570 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
2571 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2572 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
2573 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2574 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2575 </table>
2576     <p>Takes 1 or 2 parameters. The first parameter sets the soft
2577     resource limit for all processes and the second parameter sets
2578     the maximum resource limit. Either parameter can be a number,
2579     or <code>max</code> to indicate to the server that the limit
2580     should be set to the maximum allowed by the operating system
2581     configuration. Raising the maximum resource limit requires that
2582     the server is running as <code>root</code>, or in the initial startup
2583     phase.</p>
2584
2585     <p>This applies to processes forked off from Apache children
2586     servicing requests, not the Apache children themselves. This
2587     includes CGI scripts and SSI exec commands, but not any
2588     processes forked off from the Apache parent such as piped
2589     logs.</p>
2590
2591     <p>Process limits control the number of processes per user.</p>
2592
2593     <div class="note"><h3>Note</h3>
2594       <p>If CGI processes are <strong>not</strong> running
2595       under user ids other than the web server user id, this directive
2596       will limit the number of processes that the server itself can
2597       create. Evidence of this situation will be indicated by
2598       <strong><code>cannot fork</code></strong> messages in the
2599       <code>error_log</code>.</p>
2600     </div>
2601
2602 <h3>See also</h3>
2603 <ul>
2604 <li><code class="directive"><a href="#rlimitmem">RLimitMEM</a></code></li>
2605 <li><code class="directive"><a href="#rlimitcpu">RLimitCPU</a></code></li>
2606 </ul>
2607 </div>
2608 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2609 <div class="directive-section"><h2><a name="ScriptInterpreterSource" id="ScriptInterpreterSource">ScriptInterpreterSource</a> <a name="scriptinterpretersource" id="scriptinterpretersource">Directive</a></h2>
2610 <table class="directive">
2611 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Technique for locating the interpreter for CGI
2612 scripts</td></tr>
2613 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ScriptInterpreterSource Registry|Registry-Strict|Script</code></td></tr>
2614 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ScriptInterpreterSource Script</code></td></tr>
2615 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2616 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
2617 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2618 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2619 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Win32 only;
2620 option <code>Registry-Strict</code> is available in Apache 2.0 and
2621 later</td></tr>
2622 </table>
2623     <p>This directive is used to control how Apache finds the
2624     interpreter used to run CGI scripts. The default setting is
2625     <code>Script</code>. This causes Apache to use the interpreter pointed to
2626     by the shebang line (first line, starting with <code>#!</code>) in the
2627     script. On Win32 systems this line usually looks like:</p>
2628
2629     <div class="example"><p><code>
2630       #!C:/Perl/bin/perl.exe
2631     </code></p></div>
2632
2633     <p>or, if <code>perl</code> is in the <code>PATH</code>, simply:</p>
2634
2635     <div class="example"><p><code>
2636       #!perl
2637     </code></p></div>
2638
2639     <p>Setting <code>ScriptInterpreterSource Registry</code> will
2640     cause the Windows Registry tree <code>HKEY_CLASSES_ROOT</code> to be
2641     searched using the script file extension (e.g., <code>.pl</code>) as a
2642     search key. The command defined by the registry subkey
2643     <code>Shell\ExecCGI\Command</code> or, if it does not exist, by the subkey
2644     <code>Shell\Open\Command</code> is used to open the script file. If the
2645     registry keys cannot be found, Apache falls back to the behavior of the
2646     <code>Script</code> option.</p>
2647
2648     <div class="warning"><h3>Security</h3>
2649     <p>Be careful when using <code>ScriptInterpreterSource
2650     Registry</code> with <code class="directive"><a href="../mod/mod_alias.html#scriptalias">ScriptAlias</a></code>'ed directories, because
2651     Apache will try to execute <strong>every</strong> file within this
2652     directory. The <code>Registry</code> setting may cause undesired
2653     program calls on files which are typically not executed. For
2654     example, the default open command on <code>.htm</code> files on
2655     most Windows systems will execute Microsoft Internet Explorer, so
2656     any HTTP request for an <code>.htm</code> file existing within the
2657     script directory would start the browser in the background on the
2658     server. This is a good way to crash your system within a minute or
2659     so.</p>
2660     </div>
2661
2662     <p>The option <code>Registry-Strict</code> which is new in Apache
2663     2.0 does the same thing as <code>Registry</code> but uses only the
2664     subkey <code>Shell\ExecCGI\Command</code>. The
2665     <code>ExecCGI</code> key is not a common one. It must be
2666     configured manually in the windows registry and hence prevents
2667     accidental program calls on your system.</p>
2668
2669 </div>
2670 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2671 <div class="directive-section"><h2><a name="ServerAdmin" id="ServerAdmin">ServerAdmin</a> <a name="serveradmin" id="serveradmin">Directive</a></h2>
2672 <table class="directive">
2673 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Email address that the server includes in error
2674 messages sent to the client</td></tr>
2675 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerAdmin <var>email-address</var>|<var>URL</var></code></td></tr>
2676 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
2677 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2678 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2679 </table>
2680     <p>The <code class="directive">ServerAdmin</code> sets the contact address
2681     that the server includes in any error messages it returns to the
2682     client. If the <code>httpd</code> doesn't recognize the supplied argument
2683     as an URL, it
2684     assumes, that it's an <var>email-address</var> and prepends it with
2685     <code>mailto:</code> in hyperlink targets. However, it's recommended to
2686     actually use an email address, since there are a lot of CGI scripts that
2687     make that assumption. If you want to use an URL, it should point to another
2688     server under your control. Otherwise users may not be able to contact you in
2689     case of errors.</p>
2690
2691     <p>It may be worth setting up a dedicated address for this, e.g.</p>
2692
2693     <div class="example"><p><code>
2694       ServerAdmin www-admin@foo.example.com
2695     </code></p></div>
2696     <p>as users do not always mention that they are talking about the
2697     server!</p>
2698
2699 </div>
2700 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2701 <div class="directive-section"><h2><a name="ServerAlias" id="ServerAlias">ServerAlias</a> <a name="serveralias" id="serveralias">Directive</a></h2>
2702 <table class="directive">
2703 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Alternate names for a host used when matching requests
2704 to name-virtual hosts</td></tr>
2705 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerAlias <var>hostname</var> [<var>hostname</var>] ...</code></td></tr>
2706 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>virtual host</td></tr>
2707 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2708 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2709 </table>
2710     <p>The <code class="directive">ServerAlias</code> directive sets the
2711     alternate names for a host, for use with <a href="../vhosts/name-based.html">name-based virtual hosts</a>. The
2712     <code class="directive">ServerAlias</code> may include wildcards, if appropriate.</p>
2713
2714     <div class="example"><p><code>
2715       &lt;VirtualHost *:80&gt;<br />
2716       ServerName server.domain.com<br />
2717       ServerAlias server server2.domain.com server2<br />
2718       ServerAlias *.example.com<br />
2719       # ...<br />
2720       &lt;/VirtualHost&gt;
2721     </code></p></div>
2722
2723 <h3>See also</h3>
2724 <ul>
2725 <li><a href="../vhosts/">Apache Virtual Host documentation</a></li>
2726 </ul>
2727 </div>
2728 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2729 <div class="directive-section"><h2><a name="ServerName" id="ServerName">ServerName</a> <a name="servername" id="servername">Directive</a></h2>
2730 <table class="directive">
2731 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Hostname and port that the server uses to identify
2732 itself</td></tr>
2733 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerName [<var>scheme</var>://]<var>fully-qualified-domain-name</var>[:<var>port</var>]</code></td></tr>
2734 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
2735 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2736 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2737 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>In version 2.0, this
2738      directive supersedes the functionality of the <code class="directive">Port</code>
2739      directive from version 1.3.</td></tr>
2740 </table>
2741     <p>The <code class="directive">ServerName</code> directive sets the
2742     request scheme, hostname and
2743     port that the server uses to identify itself.  This is used when
2744     creating redirection URLs. For example, if the name of the
2745     machine hosting the web server is <code>simple.example.com</code>,
2746     but the machine also has the DNS alias <code>www.example.com</code>
2747     and you wish the web server to be so identified, the following
2748     directive should be used:</p>
2749
2750     <div class="example"><p><code>
2751       ServerName www.example.com:80
2752     </code></p></div>
2753
2754     <p>If no <code class="directive">ServerName</code> is specified, then the
2755     server attempts to deduce the hostname by performing a reverse
2756     lookup on the IP address. If no port is specified in the
2757     <code class="directive">ServerName</code>, then the server will use the
2758     port from the incoming request. For optimal reliability and
2759     predictability, you should specify an explicit hostname and port
2760     using the <code class="directive">ServerName</code> directive.</p>
2761
2762     <p>If you are using <a href="../vhosts/name-based.html">name-based virtual hosts</a>,
2763     the <code class="directive">ServerName</code> inside a
2764     <code class="directive"><a href="#virtualhost">&lt;VirtualHost&gt;</a></code>
2765     section specifies what hostname must appear in the request's
2766     <code>Host:</code> header to match this virtual host.</p>
2767
2768
2769     <p>Sometimes, the server runs behind a device that processes SSL,
2770     such as a reverse proxy, load balancer or SSL offload
2771     appliance. When this is the case, specify the
2772     <code>https://</code> scheme and the port number to which the
2773     clients connect in the <code class="directive">ServerName</code> directive
2774     to make sure that the server generates the correct
2775     self-referential URLs. 
2776     </p>
2777
2778     <p>See the description of the
2779     <code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code> and
2780     <code class="directive"><a href="#usecanonicalphysicalport">UseCanonicalPhysicalPort</a></code> directives for
2781     settings which determine whether self-referential URLs (e.g., by the
2782     <code class="module"><a href="../mod/mod_dir.html">mod_dir</a></code> module) will refer to the
2783     specified port, or to the port number given in the client's request.
2784     </p>
2785
2786
2787 <h3>See also</h3>
2788 <ul>
2789 <li><a href="../dns-caveats.html">Issues Regarding DNS and
2790     Apache</a></li>
2791 <li><a href="../vhosts/">Apache virtual host
2792     documentation</a></li>
2793 <li><code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code></li>
2794 <li><code class="directive"><a href="#usecanonicalphysicalport">UseCanonicalPhysicalPort</a></code></li>
2795 <li><code class="directive"><a href="#namevirtualhost">NameVirtualHost</a></code></li>
2796 <li><code class="directive"><a href="#serveralias">ServerAlias</a></code></li>
2797 </ul>
2798 </div>
2799 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2800 <div class="directive-section"><h2><a name="ServerPath" id="ServerPath">ServerPath</a> <a name="serverpath" id="serverpath">Directive</a></h2>
2801 <table class="directive">
2802 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Legacy URL pathname for a name-based virtual host that
2803 is accessed by an incompatible browser</td></tr>
2804 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerPath <var>URL-path</var></code></td></tr>
2805 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>virtual host</td></tr>
2806 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2807 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2808 </table>
2809     <p>The <code class="directive">ServerPath</code> directive sets the legacy
2810     URL pathname for a host, for use with <a href="../vhosts/">name-based virtual hosts</a>.</p>
2811
2812 <h3>See also</h3>
2813 <ul>
2814 <li><a href="../vhosts/">Apache Virtual Host documentation</a></li>
2815 </ul>
2816 </div>
2817 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2818 <div class="directive-section"><h2><a name="ServerRoot" id="ServerRoot">ServerRoot</a> <a name="serverroot" id="serverroot">Directive</a></h2>
2819 <table class="directive">
2820 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Base directory for the server installation</td></tr>
2821 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerRoot <var>directory-path</var></code></td></tr>
2822 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerRoot /usr/local/apache</code></td></tr>
2823 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2824 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2825 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2826 </table>
2827     <p>The <code class="directive">ServerRoot</code> directive sets the
2828     directory in which the server lives. Typically it will contain the
2829     subdirectories <code>conf/</code> and <code>logs/</code>. Relative
2830     paths in other configuration directives (such as <code class="directive"><a href="#include">Include</a></code> or <code class="directive"><a href="../mod/mod_so.html#loadmodule">LoadModule</a></code>, for example) are taken as 
2831     relative to this directory.</p>
2832
2833     <div class="example"><h3>Example</h3><p><code>
2834       ServerRoot /home/httpd
2835     </code></p></div>
2836
2837
2838 <h3>See also</h3>
2839 <ul>
2840 <li><a href="../invoking.html">the <code>-d</code>
2841     option to <code>httpd</code></a></li>
2842 <li><a href="../misc/security_tips.html#serverroot">the
2843     security tips</a> for information on how to properly set
2844     permissions on the <code class="directive">ServerRoot</code></li>
2845 </ul>
2846 </div>
2847 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2848 <div class="directive-section"><h2><a name="ServerSignature" id="ServerSignature">ServerSignature</a> <a name="serversignature" id="serversignature">Directive</a></h2>
2849 <table class="directive">
2850 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures the footer on server-generated documents</td></tr>
2851 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerSignature On|Off|EMail</code></td></tr>
2852 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerSignature Off</code></td></tr>
2853 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2854 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
2855 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2856 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2857 </table>
2858     <p>The <code class="directive">ServerSignature</code> directive allows the
2859     configuration of a trailing footer line under server-generated
2860     documents (error messages, <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code> ftp directory
2861     listings, <code class="module"><a href="../mod/mod_info.html">mod_info</a></code> output, ...). The reason why you
2862     would want to enable such a footer line is that in a chain of proxies,
2863     the user often has no possibility to tell which of the chained servers
2864     actually produced a returned error message.</p>
2865
2866     <p>The <code>Off</code>
2867     setting, which is the default, suppresses the footer line (and is
2868     therefore compatible with the behavior of Apache-1.2 and
2869     below). The <code>On</code> setting simply adds a line with the
2870     server version number and <code class="directive"><a href="#servername">ServerName</a></code> of the serving virtual host,
2871     and the <code>EMail</code> setting additionally creates a
2872     "mailto:" reference to the <code class="directive"><a href="#serveradmin">ServerAdmin</a></code> of the referenced
2873     document.</p>
2874
2875     <p>After version 2.0.44, the details of the server version number
2876     presented are controlled by the <code class="directive"><a href="#servertokens">ServerTokens</a></code> directive.</p>
2877
2878 <h3>See also</h3>
2879 <ul>
2880 <li><code class="directive"><a href="#servertokens">ServerTokens</a></code></li>
2881 </ul>
2882 </div>
2883 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2884 <div class="directive-section"><h2><a name="ServerTokens" id="ServerTokens">ServerTokens</a> <a name="servertokens" id="servertokens">Directive</a></h2>
2885 <table class="directive">
2886 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures the <code>Server</code> HTTP response
2887 header</td></tr>
2888 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerTokens Major|Minor|Min[imal]|Prod[uctOnly]|OS|Full</code></td></tr>
2889 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerTokens Full</code></td></tr>
2890 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2891 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2892 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2893 </table>
2894     <p>This directive controls whether <code>Server</code> response
2895     header field which is sent back to clients includes a
2896     description of the generic OS-type of the server as well as
2897     information about compiled-in modules.</p>
2898
2899     <dl>
2900       <dt><code>ServerTokens Prod[uctOnly]</code></dt>
2901
2902       <dd>Server sends (<em>e.g.</em>): <code>Server:
2903       Apache</code></dd>
2904
2905       <dt><code>ServerTokens Major</code></dt>
2906
2907       <dd>Server sends (<em>e.g.</em>): <code>Server:
2908       Apache/2</code></dd>
2909
2910       <dt><code>ServerTokens Minor</code></dt>
2911
2912       <dd>Server sends (<em>e.g.</em>): <code>Server:
2913       Apache/2.0</code></dd>
2914
2915       <dt><code>ServerTokens Min[imal]</code></dt>
2916
2917       <dd>Server sends (<em>e.g.</em>): <code>Server:
2918       Apache/2.0.41</code></dd>
2919
2920       <dt><code>ServerTokens OS</code></dt>
2921
2922       <dd>Server sends (<em>e.g.</em>): <code>Server: Apache/2.0.41
2923       (Unix)</code></dd>
2924
2925       <dt><code>ServerTokens Full</code> (or not specified)</dt>
2926
2927       <dd>Server sends (<em>e.g.</em>): <code>Server: Apache/2.0.41
2928       (Unix) PHP/4.2.2 MyMod/1.2</code></dd>
2929     </dl>
2930
2931     <p>This setting applies to the entire server, and cannot be
2932     enabled or disabled on a virtualhost-by-virtualhost basis.</p>
2933
2934     <p>After version 2.0.44, this directive also controls the
2935     information presented by the <code class="directive"><a href="#serversignature">ServerSignature</a></code> directive.</p>
2936
2937 <h3>See also</h3>
2938 <ul>
2939 <li><code class="directive"><a href="#serversignature">ServerSignature</a></code></li>
2940 </ul>
2941 </div>
2942 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2943 <div class="directive-section"><h2><a name="SetHandler" id="SetHandler">SetHandler</a> <a name="sethandler" id="sethandler">Directive</a></h2>
2944 <table class="directive">
2945 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Forces all matching files to be processed by a
2946 handler</td></tr>
2947 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetHandler <var>handler-name</var>|None</code></td></tr>
2948 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2949 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
2950 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2951 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2952 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Moved into the core in Apache 2.0</td></tr>
2953 </table>
2954     <p>When placed into an <code>.htaccess</code> file or a
2955     <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> or
2956     <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
2957     section, this directive forces all matching files to be parsed
2958     through the <a href="../handler.html">handler</a> given by
2959     <var>handler-name</var>. For example, if you had a directory you
2960     wanted to be parsed entirely as imagemap rule files, regardless
2961     of extension, you might put the following into an
2962     <code>.htaccess</code> file in that directory:</p>
2963
2964     <div class="example"><p><code>
2965       SetHandler imap-file
2966     </code></p></div>
2967
2968     <p>Another example: if you wanted to have the server display a
2969     status report whenever a URL of
2970     <code>http://servername/status</code> was called, you might put
2971     the following into <code>httpd.conf</code>:</p>
2972
2973     <div class="example"><p><code>
2974       &lt;Location /status&gt;<br />
2975       <span class="indent">
2976         SetHandler server-status<br />
2977       </span>
2978       &lt;/Location&gt;
2979     </code></p></div>
2980
2981     <p>You can override an earlier defined <code class="directive">SetHandler</code>
2982     directive by using the value <code>None</code>.</p>
2983     <p><strong>Note:</strong> because SetHandler overrides default handlers,
2984     normal behaviour such as handling of URLs ending in a slash (/) as
2985     directories or index files is suppressed.</p>
2986
2987 <h3>See also</h3>
2988 <ul>
2989 <li><code class="directive"><a href="../mod/mod_mime.html#addhandler">AddHandler</a></code></li>
2990 </ul>
2991 </div>
2992 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
2993 <div class="directive-section"><h2><a name="SetInputFilter" id="SetInputFilter">SetInputFilter</a> <a name="setinputfilter" id="setinputfilter">Directive</a></h2>
2994 <table class="directive">
2995 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Sets the filters that will process client requests and POST
2996 input</td></tr>
2997 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetInputFilter <var>filter</var>[;<var>filter</var>...]</code></td></tr>
2998 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2999 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
3000 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3001 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3002 </table>
3003     <p>The <code class="directive">SetInputFilter</code> directive sets the
3004     filter or filters which will process client requests and POST
3005     input when they are received by the server. This is in addition to
3006     any filters defined elsewhere, including the
3007     <code class="directive"><a href="../mod/mod_mime.html#addinputfilter">AddInputFilter</a></code>
3008     directive.</p>
3009
3010     <p>If more than one filter is specified, they must be separated
3011     by semicolons in the order in which they should process the
3012     content.</p>
3013
3014 <h3>See also</h3>
3015 <ul>
3016 <li><a href="../filter.html">Filters</a> documentation</li>
3017 </ul>
3018 </div>
3019 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3020 <div class="directive-section"><h2><a name="SetOutputFilter" id="SetOutputFilter">SetOutputFilter</a> <a name="setoutputfilter" id="setoutputfilter">Directive</a></h2>
3021 <table class="directive">
3022 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Sets the filters that will process responses from the
3023 server</td></tr>
3024 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetOutputFilter <var>filter</var>[;<var>filter</var>...]</code></td></tr>
3025 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
3026 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
3027 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3028 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3029 </table>
3030     <p>The <code class="directive">SetOutputFilter</code> directive sets the filters
3031     which will process responses from the server before they are
3032     sent to the client. This is in addition to any filters defined
3033     elsewhere, including the
3034     <code class="directive"><a href="../mod/mod_mime.html#addoutputfilter">AddOutputFilter</a></code>
3035     directive.</p>
3036
3037     <p>For example, the following configuration will process all files
3038     in the <code>/www/data/</code> directory for server-side
3039     includes.</p>
3040
3041     <div class="example"><p><code>
3042       &lt;Directory /www/data/&gt;<br />
3043       <span class="indent">
3044         SetOutputFilter INCLUDES<br />
3045       </span>
3046       &lt;/Directory&gt;
3047     </code></p></div>
3048
3049     <p>If more than one filter is specified, they must be separated
3050     by semicolons in the order in which they should process the
3051     content.</p>
3052
3053 <h3>See also</h3>
3054 <ul>
3055 <li><a href="../filter.html">Filters</a> documentation</li>
3056 </ul>
3057 </div>
3058 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3059 <div class="directive-section"><h2><a name="TimeOut" id="TimeOut">TimeOut</a> <a name="timeout" id="timeout">Directive</a></h2>
3060 <table class="directive">
3061 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Amount of time the server will wait for
3062 certain events before failing a request</td></tr>
3063 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>TimeOut <var>seconds</var></code></td></tr>
3064 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>TimeOut 300</code></td></tr>
3065 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
3066 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3067 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3068 </table>
3069     <p>The <code class="directive">TimeOut</code> directive defines the length
3070     of time Apache will wait for I/O in various circumstances:</p>
3071
3072     <ol>
3073       <li>When reading data from the client, the length of time to
3074       wait for a TCP packet to arrive if the read buffer is
3075       empty.</li>
3076
3077       <li>When writing data to the client, the length of time to wait
3078       for an acknowledgement of a packet if the send buffer is
3079       full.</li>
3080
3081       <li>In <code class="module"><a href="../mod/mod_cgi.html">mod_cgi</a></code>, the length of time to wait for
3082       output from a CGI script.</li>
3083
3084       <li>In <code class="module"><a href="../mod/mod_ext_filter.html">mod_ext_filter</a></code>, the length of time to
3085       wait for output from a filtering process.</li>
3086
3087       <li>In <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code>, the default timeout value if
3088       <code class="directive"><a href="../mod/mod_proxy.html#proxytimeout">ProxyTimeout</a></code> is not
3089       configured.</li>
3090     </ol>
3091
3092
3093 </div>
3094 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3095 <div class="directive-section"><h2><a name="TraceEnable" id="TraceEnable">TraceEnable</a> <a name="traceenable" id="traceenable">Directive</a></h2>
3096 <table class="directive">
3097 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Determines the behaviour on <code>TRACE</code>
3098 requests</td></tr>
3099 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>TraceEnable <var>[on|off|extended]</var></code></td></tr>
3100 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>TraceEnable on</code></td></tr>
3101 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
3102 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3103 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3104 <tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 1.3.34, 2.0.55 and later</td></tr>
3105 </table>
3106     <p>This directive overrides the behavior of <code>TRACE</code> for both
3107     the core server and <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code>.  The default
3108     <code>TraceEnable on</code> permits <code>TRACE</code> requests per
3109     RFC 2616, which disallows any request body to accompany the request.
3110     <code>TraceEnable off</code> causes the core server and
3111     <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code> to return a <code>405</code> (Method not
3112     allowed) error to the client.</p>
3113
3114     <p>Finally, for testing and diagnostic purposes only, request
3115     bodies may be allowed using the non-compliant <code>TraceEnable 
3116     extended</code> directive.  The core (as an origin server) will
3117     restrict the request body to 64k (plus 8k for chunk headers if
3118     <code>Transfer-Encoding: chunked</code> is used).  The core will
3119     reflect the full headers and all chunk headers with the response
3120     body.  As a proxy server, the request body is not restricted to 64k.</p>
3121
3122 </div>
3123 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3124 <div class="directive-section"><h2><a name="UseCanonicalName" id="UseCanonicalName">UseCanonicalName</a> <a name="usecanonicalname" id="usecanonicalname">Directive</a></h2>
3125 <table class="directive">
3126 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures how the server determines its own name and
3127 port</td></tr>
3128 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>UseCanonicalName On|Off|DNS</code></td></tr>
3129 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>UseCanonicalName Off</code></td></tr>
3130 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
3131 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3132 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3133 </table>
3134     <p>In many situations Apache must construct a <em>self-referential</em>
3135     URL -- that is, a URL that refers back to the same server. With
3136     <code>UseCanonicalName On</code> Apache will use the hostname and port
3137     specified in the <code class="directive"><a href="#servername">ServerName</a></code>
3138     directive to construct the canonical name for the server. This name
3139     is used in all self-referential URLs, and for the values of
3140     <code>SERVER_NAME</code> and <code>SERVER_PORT</code> in CGIs.</p>
3141
3142     <p>With <code>UseCanonicalName Off</code> Apache will form
3143     self-referential URLs using the hostname and port supplied by
3144     the client if any are supplied (otherwise it will use the
3145     canonical name, as defined above). These values are the same
3146     that are used to implement <a href="../vhosts/name-based.html">name based virtual hosts</a>,
3147     and are available with the same clients. The CGI variables
3148     <code>SERVER_NAME</code> and <code>SERVER_PORT</code> will be
3149     constructed from the client supplied values as well.</p>
3150
3151     <p>An example where this may be useful is on an intranet server
3152     where you have users connecting to the machine using short
3153     names such as <code>www</code>. You'll notice that if the users
3154     type a shortname, and a URL which is a directory, such as
3155     <code>http://www/splat</code>, <em>without the trailing
3156     slash</em> then Apache will redirect them to
3157     <code>http://www.domain.com/splat/</code>. If you have
3158     authentication enabled, this will cause the user to have to
3159     authenticate twice (once for <code>www</code> and once again
3160     for <code>www.domain.com</code> -- see <a href="http://httpd.apache.org/docs/misc/FAQ.html#prompted-twice">the
3161     FAQ on this subject for more information</a>). But if
3162     <code class="directive">UseCanonicalName</code> is set <code>Off</code>, then
3163     Apache will redirect to <code>http://www/splat/</code>.</p>
3164
3165     <p>There is a third option, <code>UseCanonicalName DNS</code>,
3166     which is intended for use with mass IP-based virtual hosting to
3167     support ancient clients that do not provide a
3168     <code>Host:</code> header. With this option Apache does a
3169     reverse DNS lookup on the server IP address that the client
3170     connected to in order to work out self-referential URLs.</p>
3171
3172     <div class="warning"><h3>Warning</h3>
3173     <p>If CGIs make assumptions about the values of <code>SERVER_NAME</code>
3174     they may be broken by this option. The client is essentially free
3175     to give whatever value they want as a hostname. But if the CGI is
3176     only using <code>SERVER_NAME</code> to construct self-referential URLs
3177     then it should be just fine.</p>
3178     </div>
3179
3180 <h3>See also</h3>
3181 <ul>
3182 <li><code class="directive"><a href="#usecanonicalphysicalport">UseCanonicalPhysicalPort</a></code></li>
3183 <li><code class="directive"><a href="#servername">ServerName</a></code></li>
3184 <li><code class="directive"><a href="../mod/mpm_common.html#listen">Listen</a></code></li>
3185 </ul>
3186 </div>
3187 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3188 <div class="directive-section"><h2><a name="UseCanonicalPhysicalPort" id="UseCanonicalPhysicalPort">UseCanonicalPhysicalPort</a> <a name="usecanonicalphysicalport" id="usecanonicalphysicalport">Directive</a></h2>
3189 <table class="directive">
3190 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures how the server determines its own name and
3191 port</td></tr>
3192 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>UseCanonicalPhysicalPort On|Off</code></td></tr>
3193 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>UseCanonicalPhysicalPort Off</code></td></tr>
3194 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
3195 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3196 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3197 </table>
3198     <p>In many situations Apache must construct a <em>self-referential</em>
3199     URL -- that is, a URL that refers back to the same server. With
3200     <code>UseCanonicalPhysicalPort On</code> Apache will, when
3201     constructing the canonical port for the server to honor
3202     the <code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code> directive,
3203     provide the actual physical port number being used by this request
3204     as a potential port. With <code>UseCanonicalPhysicalPort Off</code>
3205     Apache will not ever use the actual physical port number, instead
3206     relying on all configured information to construct a valid port number.</p>
3207
3208     <div class="note"><h3>Note</h3>
3209     <p>The ordering of when the physical port is used is as follows:<br /><br />
3210      <code>UseCanonicalName On</code></p>
3211      <ul>
3212       <li>Port provided in <code>Servername</code></li>
3213       <li>Physical port</li>
3214       <li>Default port</li>
3215      </ul>
3216      <code>UseCanonicalName Off | DNS</code>
3217      <ul>
3218       <li>Parsed port from <code>Host:</code> header</li>
3219       <li>Physical port</li>
3220       <li>Port provided in <code>Servername</code></li>
3221       <li>Default port</li>
3222      </ul>
3223     
3224     <p>With <code>UseCanonicalPhysicalPort Off</code>, the
3225     physical ports are removed from the ordering.</p>
3226     </div>
3227
3228
3229 <h3>See also</h3>
3230 <ul>
3231 <li><code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code></li>
3232 <li><code class="directive"><a href="#servername">ServerName</a></code></li>
3233 <li><code class="directive"><a href="../mod/mpm_common.html#listen">Listen</a></code></li>
3234 </ul>
3235 </div>
3236 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
3237 <div class="directive-section"><h2><a name="VirtualHost" id="VirtualHost">&lt;VirtualHost&gt;</a> <a name="virtualhost" id="virtualhost">Directive</a></h2>
3238 <table class="directive">
3239 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply only to a specific
3240 hostname or IP address</td></tr>
3241 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;VirtualHost
3242     <var>addr</var>[:<var>port</var>] [<var>addr</var>[:<var>port</var>]]
3243     ...&gt; ... &lt;/VirtualHost&gt;</code></td></tr>
3244 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
3245 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3246 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3247 </table>
3248     <p><code class="directive">&lt;VirtualHost&gt;</code> and
3249     <code>&lt;/VirtualHost&gt;</code> are used to enclose a group of
3250     directives that will apply only to a particular virtual host. Any
3251     directive that is allowed in a virtual host context may be
3252     used. When the server receives a request for a document on a
3253     particular virtual host, it uses the configuration directives
3254     enclosed in the <code class="directive">&lt;VirtualHost&gt;</code>
3255     section. <var>Addr</var> can be:</p>
3256
3257     <ul>
3258       <li>The IP address of the virtual host;</li>
3259
3260       <li>A fully qualified domain name for the IP address of the
3261       virtual host (not recommended);</li>
3262
3263       <li>The character <code>*</code>, which is used only in combination with
3264       <code>NameVirtualHost *</code> to match all IP addresses; or</li>
3265
3266       <li>The string <code>_default_</code>, which is used only
3267       with IP virtual hosting to catch unmatched IP addresses.</li>
3268     </ul>
3269
3270     <div class="example"><h3>Example</h3><p><code>
3271       &lt;VirtualHost 10.1.2.3&gt;<br />
3272       <span class="indent">
3273         ServerAdmin webmaster@host.example.com<br />
3274         DocumentRoot /www/docs/host.example.com<br />
3275         ServerName host.example.com<br />
3276         ErrorLog logs/host.example.com-error_log<br />
3277         TransferLog logs/host.example.com-access_log<br />
3278       </span>
3279       &lt;/VirtualHost&gt;
3280     </code></p></div>
3281
3282
3283     <p>IPv6 addresses must be specified in square brackets because
3284     the optional port number could not be determined otherwise.  An
3285     IPv6 example is shown below:</p>
3286
3287     <div class="example"><p><code>
3288       &lt;VirtualHost [2001:db8::a00:20ff:fea7:ccea]&gt;<br />
3289       <span class="indent">
3290         ServerAdmin webmaster@host.example.com<br />
3291         DocumentRoot /www/docs/host.example.com<br />
3292         ServerName host.example.com<br />
3293         ErrorLog logs/host.example.com-error_log<br />
3294         TransferLog logs/host.example.com-access_log<br />
3295       </span>
3296       &lt;/VirtualHost&gt;
3297     </code></p></div>
3298
3299     <p>Each Virtual Host must correspond to a different IP address,
3300     different port number or a different host name for the server,
3301     in the former case the server machine must be configured to
3302     accept IP packets for multiple addresses. (If the machine does
3303     not have multiple network interfaces, then this can be
3304     accomplished with the <code>ifconfig alias</code> command -- if
3305     your OS supports it).</p>
3306
3307     <div class="note"><h3>Note</h3>
3308     <p>The use of <code class="directive">&lt;VirtualHost&gt;</code> does
3309     <strong>not</strong> affect what addresses Apache listens on. You
3310     may need to ensure that Apache is listening on the correct addresses
3311     using <code class="directive"><a href="../mod/mpm_common.html#listen">Listen</a></code>.</p>
3312     </div>
3313
3314     <p>When using IP-based virtual hosting, the special name
3315     <code>_default_</code> can be specified in
3316     which case this virtual host will match any IP address that is
3317     not explicitly listed in another virtual host. In the absence
3318     of any <code>_default_</code> virtual host the "main" server config,
3319     consisting of all those definitions outside any VirtualHost
3320     section, is used when no IP-match occurs.</p>
3321
3322     <p>You can specify a <code>:port</code> to change the port that is
3323     matched. If unspecified then it defaults to the same port as the
3324     most recent <code class="directive"><a href="../mod/mpm_common.html#listen">Listen</a></code>
3325     statement of the main server. You may also specify <code>:*</code>
3326     to match all ports on that address. (This is recommended when used
3327     with <code>_default_</code>.)</p>
3328
3329     <p>A <code class="directive"><a href="#servername">ServerName</a></code> should be
3330     specified inside each <code class="directive">&lt;VirtualHost&gt;</code> block. If it is absent, the
3331     <code class="directive"><a href="#servername">ServerName</a></code> from the "main"
3332     server configuration will be inherited.</p>
3333
3334     <div class="warning"><h3>Security</h3>
3335     <p>See the <a href="../misc/security_tips.html">security tips</a>
3336     document for details on why your security could be compromised if the
3337     directory where log files are stored is writable by anyone other
3338     than the user that starts the server.</p>
3339     </div>
3340
3341 <h3>See also</h3>
3342 <ul>
3343 <li><a href="../vhosts/">Apache Virtual Host documentation</a></li>
3344 <li><a href="../dns-caveats.html">Issues Regarding DNS and
3345     Apache</a></li>
3346 <li><a href="../bind.html">Setting
3347     which addresses and ports Apache uses</a></li>
3348 <li><a href="../sections.html">How &lt;Directory&gt;, &lt;Location&gt;
3349     and &lt;Files&gt; sections work</a> for an explanation of how these
3350     different sections are combined when a request is received</li>
3351 </ul>
3352 </div>
3353 </div>
3354 <div class="bottomlang">
3355 <p><span>Available Languages: </span><a href="../de/mod/core.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
3356 <a href="../en/mod/core.html" title="English">&nbsp;en&nbsp;</a> |
3357 <a href="../ja/mod/core.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
3358 <a href="../tr/mod/core.html" hreflang="tr" rel="alternate" title="Türkçe">&nbsp;tr&nbsp;</a></p>
3359 </div><div id="footer">
3360 <p class="apache">Copyright 2009 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
3361 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div>
3362 </body></html>