core.html.en revision 8b052d682204371decc64f942aede5ef1da98955
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<?xml version="1.0" encoding="ISO-8859-1"?>
530eba85dbd41b8a0fa5255d3648d1440199a661slive<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
e942c741056732f50da2074b36fe59805d370650slive<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
5f5d1b4cc970b7f06ff8ef6526128e9a27303d88nd XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd This file is generated from xml source: DO NOT EDIT
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding -->
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<title>core - Apache HTTP Server</title>
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<link href="/style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<link href="/style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<link href="/style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<link href="/images/favicon.ico" rel="shortcut icon" /></head>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<body>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<div id="page-header">
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<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>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<p class="apache">Apache HTTP Server Version 2.1</p>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<img alt="" src="/images/feather.gif" /></div>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="/images/left.gif" /></a></div>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<div id="path">
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<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-project/">Documentation</a> &gt; <a href="../">Version 2.1</a> &gt; <a href="./">Modules</a></div>
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<div id="page-content">
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<div id="preamble"><h1>Apache Core Features</h1>
7db9f691a00ead175b03335457ca296a33ddf31bnd<div class="toplang">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<p><span>Available Languages: </span><a href="/de/mod/core.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<a href="/en/mod/core.html" title="English">&nbsp;en&nbsp;</a></p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Core Apache HTTP Server features that are always
530eba85dbd41b8a0fa5255d3648d1440199a661sliveavailable</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="module-dict.html#Status">Status:</a></th><td>Core</td></tr></table>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna</div>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<div id="quickview"><h3 class="directives">Directives</h3>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<ul id="toc">
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#acceptpathinfo">AcceptPathInfo</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#accessfilename">AccessFileName</a></li>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<li><img alt="" src="/images/down.gif" /> <a href="#adddefaultcharset">AddDefaultCharset</a></li>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<li><img alt="" src="/images/down.gif" /> <a href="#addoutputfilterbytype">AddOutputFilterByType</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#allowencodedslashes">AllowEncodedSlashes</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#allowoverride">AllowOverride</a></li>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<li><img alt="" src="/images/down.gif" /> <a href="#authname">AuthName</a></li>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<li><img alt="" src="/images/down.gif" /> <a href="#authtype">AuthType</a></li>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<li><img alt="" src="/images/down.gif" /> <a href="#cgimapextension">CGIMapExtension</a></li>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<li><img alt="" src="/images/down.gif" /> <a href="#contentdigest">ContentDigest</a></li>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<li><img alt="" src="/images/down.gif" /> <a href="#defaulttype">DefaultType</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#directory">&lt;Directory&gt;</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#directorymatch">&lt;DirectoryMatch&gt;</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#documentroot">DocumentRoot</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#enablemmap">EnableMMAP</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#enablesendfile">EnableSendfile</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#errordocument">ErrorDocument</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#errorlog">ErrorLog</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#fileetag">FileETag</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#files">&lt;Files&gt;</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#filesmatch">&lt;FilesMatch&gt;</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#forcetype">ForceType</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#hostnamelookups">HostnameLookups</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#ifdefine">&lt;IfDefine&gt;</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#ifmodule">&lt;IfModule&gt;</a></li>
4e9f8c5414e5fe39b5393641533edca65f6e8b91poirier<li><img alt="" src="/images/down.gif" /> <a href="#include">Include</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#keepalive">KeepAlive</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#keepalivetimeout">KeepAliveTimeout</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#limit">&lt;Limit&gt;</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#limitexcept">&lt;LimitExcept&gt;</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#limitinternalrecursion">LimitInternalRecursion</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#limitrequestbody">LimitRequestBody</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#limitrequestfields">LimitRequestFields</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#limitrequestfieldsize">LimitRequestFieldSize</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#limitrequestline">LimitRequestLine</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#limitxmlrequestbody">LimitXMLRequestBody</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#location">&lt;Location&gt;</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#locationmatch">&lt;LocationMatch&gt;</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#loglevel">LogLevel</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#maxkeepaliverequests">MaxKeepAliveRequests</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#namevirtualhost">NameVirtualHost</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#options">Options</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#require">Require</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#rlimitcpu">RLimitCPU</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#rlimitmem">RLimitMEM</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#rlimitnproc">RLimitNPROC</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#satisfy">Satisfy</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#scriptinterpretersource">ScriptInterpreterSource</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#serveradmin">ServerAdmin</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<li><img alt="" src="/images/down.gif" /> <a href="#serveralias">ServerAlias</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#servername">ServerName</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#serverpath">ServerPath</a></li>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<li><img alt="" src="/images/down.gif" /> <a href="#serverroot">ServerRoot</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#serversignature">ServerSignature</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#servertokens">ServerTokens</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#sethandler">SetHandler</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#setinputfilter">SetInputFilter</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#setoutputfilter">SetOutputFilter</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#timeout">TimeOut</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#usecanonicalname">UseCanonicalName</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<li><img alt="" src="/images/down.gif" /> <a href="#virtualhost">&lt;VirtualHost&gt;</a></li>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe</ul>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe</div>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<div class="directive-section"><h2><a name="AcceptPathInfo" id="AcceptPathInfo">AcceptPathInfo</a> <a name="acceptpathinfo" id="acceptpathinfo">Directive</a></h2>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<table class="directive">
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Resources accept trailing pathname information</td></tr>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AcceptPathInfo On|Off|Default</code></td></tr>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AcceptPathInfo Default</code></td></tr>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.30 and later</td></tr>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna</table>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <p>This directive controls whether requests that contain trailing
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna pathname information that follows an actual filename (or
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna non-existent file in an existing directory) will be accepted or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive rejected. The trailing pathname information can be made
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive available to scripts in the <code>PATH_INFO</code> environment
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess variable.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For example, assume the location <code>/test/</code> points to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a directory that contains only the single file
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>here.html</code>. Then requests for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/test/here.html/more</code> and
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele <code>/test/nothere.html/more</code> both collect
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen <code>/more</code> as <code>PATH_INFO</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The three possible arguments for the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive">AcceptPathInfo</code> directive are:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dl>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>Off</code></dt><dd>A request will only be accepted if it
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive maps to a literal path that exists. Therefore a request with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive trailing pathname information after the true filename such as
fb77c505254b6e9c925e23e734463e87574f8f40kess <code>/test/here.html/more</code> in the above example will return
fb77c505254b6e9c925e23e734463e87574f8f40kess a 404 NOT FOUND error.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>On</code></dt><dd>A request will be accepted if a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive leading path component maps to a file that exists. The above
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive example <code>/test/here.html/more</code> will be accepted if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/test/here.html</code> maps to a valid file.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
fb77c505254b6e9c925e23e734463e87574f8f40kess <dt><code>Default</code></dt><dd>The treatment of requests with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive trailing pathname information is determined by the <a href="/handler.html">handler</a> responsible for the request.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The core handler for normal files defaults to rejecting
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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-isa</a>, generally accept
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>PATH_INFO</code> by default.</dd>
fb77c505254b6e9c925e23e734463e87574f8f40kess </dl>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The primary purpose of the <code>AcceptPathInfo</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive is to allow you to override the handler's choice of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accepting or rejecting <code>PATH_INFO</code>. This override is required,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for example, when you use a <a href="/filter.html">filter</a>, such
fb77c505254b6e9c925e23e734463e87574f8f40kess as <a href="mod_include.html">INCLUDES</a>, to generate content
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive based on <code>PATH_INFO</code>. The core handler would usually reject
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the request, so you can use the following configuration to enable
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive such a script:</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Files "mypaths.shtml"&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
fb77c505254b6e9c925e23e734463e87574f8f40kess Options +Includes<br />
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess SetOutputFilter INCLUDES<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AcceptPathInfo On<br />
bc4b55ec8f31569d606d5680d50189a355bcd7a6rbowen </span>
fb77c505254b6e9c925e23e734463e87574f8f40kess &lt;/Files&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
fb77c505254b6e9c925e23e734463e87574f8f40kess<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
fb77c505254b6e9c925e23e734463e87574f8f40kess<div class="directive-section"><h2><a name="AccessFileName" id="AccessFileName">AccessFileName</a> <a name="accessfilename" id="accessfilename">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Name of the distributed configuration file</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AccessFileName <var>filename</var> [<var>filename</var>] ...</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AccessFileName .htaccess</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd</table>
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>While processing a request the server looks for
130d299c4b2b15be45532a176604c71fdc7bea5bnd the first existing configuration file from this list of names in
ef8e89e090461194ecadd31e8796a2c51e0531a2kess every directory of the path to the document, if distributed
130d299c4b2b15be45532a176604c71fdc7bea5bnd configuration files are <a href="#allowoverride">enabled for that
130d299c4b2b15be45532a176604c71fdc7bea5bnd directory</a>. For example:</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AccessFileName .acl
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>before returning the document
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/usr/local/web/index.html</code>, the server will read
003f0c9fda6664daf5092a0e42f65ede20098153slive <code>/.acl</code>, <code>/usr/.acl</code>,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>/usr/local/.acl</code> and <code>/usr/local/web/.acl</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for directives, unless they have been disabled with</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess AllowOverride None<br />
003f0c9fda6664daf5092a0e42f65ede20098153slive </span>
003f0c9fda6664daf5092a0e42f65ede20098153slive &lt;/Directory&gt;
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess </code></p></div>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<li><code class="directive"><a href="#allowoverride">AllowOverride</a></code></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<li><a href="/configuring.html">Configuration Files</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/howto/htaccess.html">.htaccess Files</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="AddDefaultCharset" id="AddDefaultCharset">AddDefaultCharset</a> <a name="adddefaultcharset" id="adddefaultcharset">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Default character set to be added for a
130d299c4b2b15be45532a176604c71fdc7bea5bndresponse without an explicit character set</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AddDefaultCharset On|Off|<var>charset</var></code></td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AddDefaultCharset Off</code></td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive specifies the name of the character set that
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive will be added to any response that does not have any parameter on
1a3f62ca37273a15a06bb94a61d3c6fcf4bf38c9rbowen the content type in the HTTP headers. This will override any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive character set specified in the body of the document via a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>META</code> tag. A setting of <code>AddDefaultCharset
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Off</code> disables this
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive functionality. <code>AddDefaultCharset On</code> enables
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding Apache's internal default charset of <code>iso-8859-1</code> as
684f2a9a422185adda0692a1203c5ad6687fc5c5nd required by the directive. You can also specify an alternate
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <var>charset</var> to be used. For example:</p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AddDefaultCharset utf-8
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
003f0c9fda6664daf5092a0e42f65ede20098153slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<div class="directive-section"><h2><a name="AddOutputFilterByType" id="AddOutputFilterByType">AddOutputFilterByType</a> <a name="addoutputfilterbytype" id="addoutputfilterbytype">Directive</a></h2>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<table class="directive">
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>assigns an output filter to a particular MIME-type</td></tr>
684f2a9a422185adda0692a1203c5ad6687fc5c5nd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AddOutputFilterByType <var>filter</var>[;<var>filter</var>...]
a8ce9095d102e43fecb81093a132b90b9a227f78kess<var>MIME-type</var> [<var>MIME-type</var>] ...</code></td></tr>
684f2a9a422185adda0692a1203c5ad6687fc5c5nd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.33 and later</td></tr>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding</table>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <p>This directive activates a particular output <a href="/filter.html">filter</a> for a request depending on the
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding response MIME-type.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>The following example uses the <code>DEFLATE</code> filter, which
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd is provided by <code class="module"><a href="/mod/mod_deflate.html">mod_deflate</a></code>. It will compress all
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd output (either static or dynamic) which is labeled as
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding <code>text/html</code> or <code>text/plain</code> before it is sent
684f2a9a422185adda0692a1203c5ad6687fc5c5nd to the client.</p>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding <div class="example"><p><code>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding AddOutputFilterByType DEFLATE text/html text/plain
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding </code></p></div>
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding <p>If you want the content to be processed by more than one filter, their
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding names have to be separated by semicolons. It's also possible to use one
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding <code class="directive">AddOutputFilterByType</code> directive for each of
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding these filters.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
843a03fe0b138a4c1f64cb90a014e9417ac30691fielding <p>The configuration below causes all script output labeled as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>text/html</code> to be processed at first by the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>INCLUDES</code> filter and then by the <code>DEFLATE</code>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd filter.</p>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd
9583adab6bc4b3758e41963c905d9dad9f067131nd <div class="example"><p><code>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd &lt;Location /cgi-bin/&gt;<br />
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <span class="indent">
77ead9e0262e4f08ec336d1a65b2edef7705c839nd Options Includes<br />
77ead9e0262e4f08ec336d1a65b2edef7705c839nd AddOutputFilterByType INCLUDES;DEFLATE text/html<br />
77ead9e0262e4f08ec336d1a65b2edef7705c839nd </span>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen &lt;/Location&gt;
77ead9e0262e4f08ec336d1a65b2edef7705c839nd </code></p></div>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <div class="warning"><h3>Note</h3>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <p>Enabling filters with <code class="directive">AddOutputFilterByType</code>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd may fail partially or completely in some cases. For expample, no
77ead9e0262e4f08ec336d1a65b2edef7705c839nd filters are applied if the MIME-type could not be determined and falls
77ead9e0262e4f08ec336d1a65b2edef7705c839nd back to the <code class="directive"><a href="#defaulttype">DefaultType</a></code> setting,
77ead9e0262e4f08ec336d1a65b2edef7705c839nd even if the <code class="directive"><a href="#defaulttype">DefaultType</a></code> is the
77ead9e0262e4f08ec336d1a65b2edef7705c839nd same.</p>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <p>However, if you want to make sure, that the filters will be
77ead9e0262e4f08ec336d1a65b2edef7705c839nd applied, assign the content type to a resource explicitely, for
9b5e2c5e769dc678a1aca06df75c32022b2f1492trawick example with <code class="directive"><a href="/mod/mod_mime.html#addtype">AddType</a></code> or
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <code class="directive"><a href="#forcetype">ForceType</a></code>. Setting the
77ead9e0262e4f08ec336d1a65b2edef7705c839nd content type within a (non-nph) CGI script is also safe.</p>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd
77ead9e0262e4f08ec336d1a65b2edef7705c839nd <p>The by-type output filters are never applied on proxy requests.</p>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd </div>
77ead9e0262e4f08ec336d1a65b2edef7705c839nd
77ead9e0262e4f08ec336d1a65b2edef7705c839nd<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="/mod/mod_mime.html#addoutputfilter">AddOutputFilter</a></code></li>
003f0c9fda6664daf5092a0e42f65ede20098153slive<li><code class="directive"><a href="#setoutputfilter">SetOutputFilter</a></code></li>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<li><a href="/filter.html">filters</a></li>
fb77c505254b6e9c925e23e734463e87574f8f40kess</ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</div>
4ea161d94782fa56f4b36d496f35ff8577c43065covener<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="AllowEncodedSlashes" id="AllowEncodedSlashes">AllowEncodedSlashes</a> <a name="allowencodedslashes" id="allowencodedslashes">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Determines whether encoded path separators in URLs are allowed to
fb77c505254b6e9c925e23e734463e87574f8f40kessbe passed through</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AllowEncodedSlashes On|Off</code></td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AllowEncodedSlashes Off</code></td></tr>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
10673857794a4b3d9568ca2d983722a87ed352f1rbowen<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.46 and later</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess</table>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd <p>The <code class="directive">AllowEncodedSlashes</code> directive allows URLs
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd which contain encoded path separators (<code>%2F</code> for <code>/</code>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd and additionally <code>%5C</code> for <code>\</code> on according systems)
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd to be used. Normally such URLs are refused with a 404 (Not found) error.</p>
10673857794a4b3d9568ca2d983722a87ed352f1rbowen
10673857794a4b3d9568ca2d983722a87ed352f1rbowen <p>Turning <code class="directive">AllowEncodedSlashes</code> <code>On</code> is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive mostly useful when used in conjunction with <code>PATH_INFO</code>.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess <div class="note"><h3>Note</h3>
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>Allowing encoded slashes does <em>not</em> imply <em>decoding</em>.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Occurences of <code>%2F</code> or <code>%5C</code> (<em>only</em> on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive according systems) will be left as such in the otherwise decoded URL
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive string.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
fb77c505254b6e9c925e23e734463e87574f8f40kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#acceptpathinfo">AcceptPathInfo</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="AllowOverride" id="AllowOverride">AllowOverride</a> <a name="allowoverride" id="allowoverride">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Types of directives that are allowed in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive.htaccess files</td></tr>
1f53e295ebd19aed1767d12da7abfab9936c148cjerenkrantz<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AllowOverride All|None|<var>directive-type</var>
1f53e295ebd19aed1767d12da7abfab9936c148cjerenkrantz[<var>directive-type</var>] ...</code></td></tr>
9ed9eaf871c58d281af02e76125ceadb5060afa5nd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>AllowOverride All</code></td></tr>
9cd3b05d7b70f07a742bbaf548fa4fa2bdbe5ce6noodl<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory</td></tr>
9cd3b05d7b70f07a742bbaf548fa4fa2bdbe5ce6noodl<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1f53e295ebd19aed1767d12da7abfab9936c148cjerenkrantz<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
9cd3b05d7b70f07a742bbaf548fa4fa2bdbe5ce6noodl</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When the server finds an <code>.htaccess</code> file (as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specified by <code class="directive"><a href="#accessfilename">AccessFileName</a></code>)
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive it needs to know which directives declared in that file can override
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive earlier configuration directives.</p>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <div class="note"><h3>Only available in &lt;Directory&gt; sections</h3>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <code class="directive">AllowOverride</code> is valid only in
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding sections, not in <code class="directive"><a href="#location">&lt;Location&gt;</a></code> or <code class="directive"><a href="#files">&lt;Files&gt;</a></code> sections.
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding </div>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <p>When this directive is set to <code>None</code>, then
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <a href="#accessfilename">.htaccess</a> files are completely ignored.
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem In this case, the server will not even attempt to read
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <code>.htaccess</code> files in the filesystem.</p>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <p>When this directive is set to <code>All</code>, then any
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem directive which has the .htaccess <a href="directive-dict.html#Context">Context</a> is allowed in
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <code>.htaccess</code> files.</p>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <p>The <var>directive-type</var> can be one of the following
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem groupings of directives.</p>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <dl>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <dt>AuthConfig</dt>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <dd>
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem Allow use of the authorization directives (<code class="directive"><a href="/mod/mod_authn_dbm.html#authdbmgroupfile">AuthDBMGroupFile</a></code>,
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <code class="directive"><a href="/mod/mod_authn_dbm.html#authdbmuserfile">AuthDBMUserFile</a></code>,
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <code class="directive"><a href="/mod/mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></code>,
5528d1a30ae8560e2d7a96d734ffe31500dc6113rpluem <code class="directive"><a href="#authname">AuthName</a></code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#authtype">AuthType</a></code>, <code class="directive"><a href="/mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code>, <code class="directive"><a href="#require">Require</a></code>, <em>etc.</em>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt>FileInfo</dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling document types (<code class="directive"><a href="#defaulttype">DefaultType</a></code>, <code class="directive"><a href="#errordocument">ErrorDocument</a></code>, <code class="directive"><a href="#forcetype">ForceType</a></code>, <code class="directive"><a href="/mod/mod_negotiation.html#languagepriority">LanguagePriority</a></code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#sethandler">SetHandler</a></code>, <code class="directive"><a href="#setinputfilter">SetInputFilter</a></code>, <code class="directive"><a href="#setoutputfilter">SetOutputFilter</a></code>, and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="module"><a href="/mod/mod_mime.html">mod_mime</a></code> Add* and Remove*
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives, <em>etc.</em>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt>Indexes</dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling directory indexing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (<code class="directive"><a href="/mod/mod_autoindex.html#adddescription">AddDescription</a></code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="/mod/mod_autoindex.html#addiconbytype">AddIconByType</a></code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>etc.</em>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt>Limit</dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>
9ed9eaf871c58d281af02e76125ceadb5060afa5nd 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>
9ed9eaf871c58d281af02e76125ceadb5060afa5nd
9ed9eaf871c58d281af02e76125ceadb5060afa5nd <dt>Options</dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
103a93c625bcde1a6a7a5155b64dcda36f612180pquerna <dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling specific directory
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive features (<code class="directive"><a href="#options">Options</a></code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="/mod/mod_include.html#xbithack">XBitHack</a></code>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </dl>
103a93c625bcde1a6a7a5155b64dcda36f612180pquerna
103a93c625bcde1a6a7a5155b64dcda36f612180pquerna <p>Example:</p>
f23fb63b05f89f47d7a3099491f2c68dcce432e9kess
f23fb63b05f89f47d7a3099491f2c68dcce432e9kess <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AllowOverride AuthConfig Indexes
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<li><code class="directive"><a href="#accessfilename">AccessFileName</a></code></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<li><a href="/configuring.html">Configuration Files</a></li>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd<li><a href="/howto/htaccess.html">.htaccess Files</a></li>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd</ul>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd</div>
b12b918ae6baf9c5762ed61b7393d0e2198378c0nd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
da637bcae7b6e150470e701af29da5604a34a17erbowen<div class="directive-section"><h2><a name="AuthName" id="AuthName">AuthName</a> <a name="authname" id="authname">Directive</a></h2>
da637bcae7b6e150470e701af29da5604a34a17erbowen<table class="directive">
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Authorization realm for use in HTTP
da637bcae7b6e150470e701af29da5604a34a17erbowenauthentication</td></tr>
da637bcae7b6e150470e701af29da5604a34a17erbowen<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AuthName <var>auth-domain</var></code></td></tr>
da637bcae7b6e150470e701af29da5604a34a17erbowen<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
da637bcae7b6e150470e701af29da5604a34a17erbowen<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig</td></tr>
da637bcae7b6e150470e701af29da5604a34a17erbowen<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the name of the authorization realm for a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory. This realm is given to the client so that the user
54bcd0e21a5c79158afd3b78bf707a493a5fb33crbowen knows which username and password to send.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive">AuthName</code> takes a single argument; if the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive realm name contains spaces, it must be enclosed in quotation
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes marks. It must be accompanied by <code class="directive"><a href="#authtype">AuthType</a></code> and <code class="directive"><a href="#require">Require</a></code> directives, and directives such
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes as <code class="directive"><a href="/mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code> and
fb77c505254b6e9c925e23e734463e87574f8f40kess <code class="directive"><a href="/mod/mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></code> to
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes work.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes <p>For example:</p>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes <div class="example"><p><code>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes AuthName "Top Secret"
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes </code></p></div>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen <p>The string provided for the <code>AuthName</code> is what will
fb77c505254b6e9c925e23e734463e87574f8f40kess appear in the password dialog provided by most browsers.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<h3>See also</h3>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<ul>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes<li><a href="/howto/auth.html">Authentication, Authorization, and
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes Access Control</a></li>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<div class="directive-section"><h2><a name="AuthType" id="AuthType">AuthType</a> <a name="authtype" id="authtype">Directive</a></h2>
fb77c505254b6e9c925e23e734463e87574f8f40kess<table class="directive">
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Type of user authentication</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>AuthType Basic|Digest</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive selects the type of user authentication for a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory. Only <code>Basic</code> and <code>Digest</code> are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive currently implemented.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
5bb5fba250bf526bc51d13b25378d54acb93c1cbnoodl It must be accompanied by <code class="directive"><a href="#authname">AuthName</a></code> and <code class="directive"><a href="#require">Require</a></code> directives, and directives such
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive as <code class="directive"><a href="/mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="/mod/mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></code> to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive work.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/howto/auth.html">Authentication, Authorization,
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveand Access Control</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="directive-section"><h2><a name="CGIMapExtension" id="CGIMapExtension">CGIMapExtension</a> <a name="cgimapextension" id="cgimapextension">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Technique for locating the interpreter for CGI
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivescripts</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>CGIMapExtension <var>cgi-path</var> <var>.extension</var></code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>NetWare only</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess</table>
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>This directive is used to control how Apache finds the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive interpreter used to run CGI scripts. For example, setting
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>CGIMapExtension sys:\foo.nlm .foo</code> will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive cause all CGI script files with a <code>.foo</code> extension to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive be passed to the FOO interpreter.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding</div>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<div class="directive-section"><h2><a name="ContentDigest" id="ContentDigest">ContentDigest</a> <a name="contentdigest" id="contentdigest">Directive</a></h2>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<table class="directive">
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables the generation of Content-MD5 HTTP Response
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fieldingheaders</td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ContentDigest On|Off</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ContentDigest Off</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Options</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive enables the generation of
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <code>Content-MD5</code> headers as defined in RFC1864
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding respectively RFC2068.</p>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>MD5 is an algorithm for computing a "message digest"
e4881891552e185a7408318dfc7f62ebabe73cf6niq (sometimes called "fingerprint") of arbitrary-length data, with
e4881891552e185a7408318dfc7f62ebabe73cf6niq a high degree of confidence that any alterations in the data
e4881891552e185a7408318dfc7f62ebabe73cf6niq will be reflected in alterations in the message digest.</p>
e4881891552e185a7408318dfc7f62ebabe73cf6niq
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <p>The <code>Content-MD5</code> header provides an end-to-end
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding message integrity check (MIC) of the entity-body. A proxy or
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding client may check this header for detecting accidental
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding modification of the entity-body in transit. Example header:</p>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <div class="example"><p><code>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding </code></p></div>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding <p>Note that this can cause performance problems on your server
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive since the message digest is computed on every request (the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive values are not cached).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl <p><code>Content-MD5</code> is only sent for documents served
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl by the <code class="module"><a href="/mod/core.html">core</a></code>, and not by any module. For example,
20b0f809c3823eda58808be053ffc305dfa9c785sf SSI documents, output from CGI scripts, and byte range responses
20b0f809c3823eda58808be053ffc305dfa9c785sf do not have this header.</p>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl</div>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
ccf2a600dd72cc3c3c44f5d4126d9bb60fa83894takashi<div class="directive-section"><h2><a name="DefaultType" id="DefaultType">DefaultType</a> <a name="defaulttype" id="defaulttype">Directive</a></h2>
ccf2a600dd72cc3c3c44f5d4126d9bb60fa83894takashi<table class="directive">
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>MIME content-type that will be sent if the
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodlserver cannot determine a type in any other way</td></tr>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>DefaultType <var>MIME-type</var></code></td></tr>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>DefaultType text/plain</code></td></tr>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
898475b582dd849de5915df0f2089b72ed8b2e2bcovener <p>There will be times when the server is asked to provide a
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd document whose type cannot be determined by its MIME types
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive mappings.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The server must inform the client of the content-type of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document, so in the event of an unknown type it uses the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>DefaultType</code>. For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
898475b582dd849de5915df0f2089b72ed8b2e2bcovener DefaultType image/gif
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor </code></p></div>
898475b582dd849de5915df0f2089b72ed8b2e2bcovener
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>would be appropriate for a directory which contained many GIF
003f0c9fda6664daf5092a0e42f65ede20098153slive images with filenames missing the <code>.gif</code> extension.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>Note that unlike <code class="directive"><a href="#forcetype">ForceType</a></code>, this directive only
fb77c505254b6e9c925e23e734463e87574f8f40kess provides the default mime-type. All other mime-type definitions,
fb77c505254b6e9c925e23e734463e87574f8f40kess including filename extensions, that might identify the media type
003f0c9fda6664daf5092a0e42f65ede20098153slive will override this default.</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive
003f0c9fda6664daf5092a0e42f65ede20098153slive</div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<div class="directive-section"><h2><a name="Directory" id="Directory">&lt;Directory&gt;</a> <a name="directory" id="directory">Directive</a></h2>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<table class="directive">
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enclose a group of directives that apply only to the
130d299c4b2b15be45532a176604c71fdc7bea5bndnamed file-system directory and sub-directories</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Directory <var>directory-path</var>&gt;
130d299c4b2b15be45532a176604c71fdc7bea5bnd... &lt;/Directory&gt;</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</table>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen <p><code class="directive">&lt;Directory&gt;</code> and
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>&lt;/Directory&gt;</code> are used to enclose a group of
fb77c505254b6e9c925e23e734463e87574f8f40kess directives that will apply only to the named directory and
fb77c505254b6e9c925e23e734463e87574f8f40kess sub-directories of that directory. Any directive that is allowed
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd in a directory context may be used. <var>Directory-path</var> is
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd either the full path to a directory, or a wild-card string using
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen Unix shell-style matching. In a wild-card string, <code>?</code> matches
030108b1816bcda3d925df65357feabdce83bc94slive any single character, and <code>*</code> matches any sequences of
030108b1816bcda3d925df65357feabdce83bc94slive characters. You may also use <code>[]</code> character ranges. None
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive of the wildcards match a `/' character, so <code>&lt;Directory
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd /*/public_html&gt;</code> will not match
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>/home/user/public_html</code>, but <code>&lt;Directory
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd /home/*/public_html&gt;</code> will match. Example:</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><p><code>
fb77c505254b6e9c925e23e734463e87574f8f40kess &lt;Directory /usr/local/httpd/htdocs&gt;<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Options Indexes FollowSymLinks<br />
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess </span>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess &lt;/Directory&gt;
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Be careful with the <var>directory-path</var> arguments:
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive They have to literally match the filesystem path which Apache uses
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to access the files. Directives applied to a particular
130d299c4b2b15be45532a176604c71fdc7bea5bnd <code>&lt;Directory&gt;</code> will not apply to files accessed from
130d299c4b2b15be45532a176604c71fdc7bea5bnd that same directory via a different path, such as via different symbolic
130d299c4b2b15be45532a176604c71fdc7bea5bnd links.</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd </div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>Extended regular
130d299c4b2b15be45532a176604c71fdc7bea5bnd expressions can also be used, with the addition of the
cdffd1263801c18587cefdebc4510df486d5906brbowen <code>~</code> character. For example:</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <div class="example"><p><code>
130d299c4b2b15be45532a176604c71fdc7bea5bnd &lt;Directory ~ "^/www/.*/[0-9]{3}"&gt;
130d299c4b2b15be45532a176604c71fdc7bea5bnd </code></p></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>would match directories in <code>/www/</code> that consisted of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive three numbers.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If multiple (non-regular expression) <code class="directive">&lt;Directory&gt;</code> sections
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive match the directory (or one of its parents) containing a document,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive then the directives are applied in the order of shortest match
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive first, interspersed with the directives from the <a href="#accessfilename">.htaccess</a> files. For example,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive with</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /&gt;<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <span class="indent">
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess AllowOverride None<br />
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess </span>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/Directory&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /home/&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AllowOverride FileInfo<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </span>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/Directory&gt;
130d299c4b2b15be45532a176604c71fdc7bea5bnd </code></p></div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>for access to the document <code>/home/web/dir/doc.html</code>
130d299c4b2b15be45532a176604c71fdc7bea5bnd the steps are:</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <li>Apply directive <code>AllowOverride None</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (disabling <code>.htaccess</code> files).</li>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <li>Apply directive <code>AllowOverride FileInfo</code> (for
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess directory <code>/home</code>).</li>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <li>Apply any <code>FileInfo</code> directives in
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <code>/home/.htaccess</code>, <code>/home/web/.htaccess</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/home/web/dir/.htaccess</code> in that order.</li>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen </ul>
fb77c505254b6e9c925e23e734463e87574f8f40kess
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen <p>Regular expressions are not considered until after all of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive normal sections have been applied. Then all of the regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expressions are tested in the order they appeared in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive configuration file. For example, with</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <div class="example"><p><code>
130d299c4b2b15be45532a176604c71fdc7bea5bnd &lt;Directory ~ abc$&gt;<br />
130d299c4b2b15be45532a176604c71fdc7bea5bnd <span class="indent">
130d299c4b2b15be45532a176604c71fdc7bea5bnd # ... directives here ...<br />
130d299c4b2b15be45532a176604c71fdc7bea5bnd </span>
130d299c4b2b15be45532a176604c71fdc7bea5bnd &lt;/Directory&gt;
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>the regular expression section won't be considered until after
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive all normal <code class="directive">&lt;Directory&gt;</code>s and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>.htaccess</code> files have been applied. Then the regular
fb77c505254b6e9c925e23e734463e87574f8f40kess expression will match on <code>/home/abc/public_html/abc</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the corresponding <code class="directive">&lt;Directory&gt;</code> will
fb77c505254b6e9c925e23e734463e87574f8f40kess be applied.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><strong>Note that the default Apache access for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>&lt;Directory /&gt;</code> is <code>Allow from All</code>.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive This means that Apache will serve any file mapped from an URL. It is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive recommended that you change this with a block such
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess as</strong></p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Order Deny,Allow<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Deny from All<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </span>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess &lt;/Directory&gt;
898475b582dd849de5915df0f2089b72ed8b2e2bcovener </code></p></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
7b5535ed88e0f561b3bfb3330137bd804846afd4slive <p><strong>and then override this for directories you
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>want</em> accessible. See the <a href="/misc/security_tips.html">Security Tips</a> page for more
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive details.</strong></p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The directory sections occur in the <code>httpd.conf</code> file.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive">&lt;Directory&gt;</code> directives
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<h3>See also</h3>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<ul>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<li><a href="/sections.html">How &lt;Directory&gt;,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd &lt;Location&gt; and &lt;Files&gt; sections work</a> for an
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd explanation of how these different sections are combined when a
6954edc623ca2c179eb5b33e97e4304d06fd649frbowen request is received</li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="DirectoryMatch" id="DirectoryMatch">&lt;DirectoryMatch&gt;</a> <a name="directorymatch" id="directorymatch">Directive</a></h2>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<table class="directive">
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enclose directives that apply to
fa1c7ce09927decc1eecd1e9a35cc5331078a052covenerfile-system directories matching a regular expression and their
fa1c7ce09927decc1eecd1e9a35cc5331078a052covenersubdirectories</td></tr>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;DirectoryMatch <var>regex</var>&gt;
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener... &lt;/DirectoryMatch&gt;</code></td></tr>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener</table>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <p><code class="directive">&lt;DirectoryMatch&gt;</code> and
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <code>&lt;/DirectoryMatch&gt;</code> are used to enclose a group
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener of directives which will apply only to the named directory and
fa1c7ce09927decc1eecd1e9a35cc5331078a052covener sub-directories of that directory, the same as <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>. However, it
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive takes as an argument a regular expression. For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess &lt;DirectoryMatch "^/www/.*/[0-9]{3}"&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>would match directories in <code>/www/</code> that consisted of three
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess numbers.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> for
003f0c9fda6664daf5092a0e42f65ede20098153slivea description of how regular expressions are mixed in with normal
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<code class="directive">&lt;Directory&gt;</code>s</li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt; and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive&lt;Files&gt; sections work</a> for an explanation of how these different
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivesections are combined when a request is received</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<div class="directive-section"><h2><a name="DocumentRoot" id="DocumentRoot">DocumentRoot</a> <a name="documentroot" id="documentroot">Directive</a></h2>
fb77c505254b6e9c925e23e734463e87574f8f40kess<table class="directive">
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Directory that forms the main document tree visible
fb77c505254b6e9c925e23e734463e87574f8f40kessfrom the web</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>DocumentRoot <var>directory-path</var></code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>DocumentRoot /usr/local/apache/htdocs</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the directory from which <code>httpd</code>
ffe8ed2cd88be2c415ddef11f50394c52df9190ctrawick 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
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor path from the requested URL to the document root to make the
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor path to the document. Example:</p>
c68acc9d712af079afa2bd1a5a4aeef9a3ea573ckess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive DocumentRoot /usr/web
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
1b01d1ee11c612226cb3141eed4581dc179266c1rbowen <p>then an access to
1b01d1ee11c612226cb3141eed4581dc179266c1rbowen <code>http://www.my.host.com/index.html</code> refers to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/usr/web/index.html</code>. If the <var>directory-path</var> is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive not absolute then it is assumed to be relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp
af18698b10b429b270551ca3a5d51a75e1c9db22brianp <p>The <code class="directive">DocumentRoot</code> should be specified without
003f0c9fda6664daf5092a0e42f65ede20098153slive a trailing slash.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess<h3>See also</h3>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<ul>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<li><a href="/urlmapping.html">Mapping URLs to Filesystem
af18698b10b429b270551ca3a5d51a75e1c9db22brianpLocation</a></li>
003f0c9fda6664daf5092a0e42f65ede20098153slive</ul>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp</div>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<div class="directive-section"><h2><a name="EnableMMAP" id="EnableMMAP">EnableMMAP</a> <a name="enablemmap" id="enablemmap">Directive</a></h2>
003f0c9fda6664daf5092a0e42f65ede20098153slive<table class="directive">
003f0c9fda6664daf5092a0e42f65ede20098153slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Use memory-mapping to read files during delivery</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnableMMAP On|Off</code></td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnableMMAP On</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</table>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>This directive controls whether the <code>httpd</code> may use
af18698b10b429b270551ca3a5d51a75e1c9db22brianp memory-mapping if it needs to read the contents of a file during
af18698b10b429b270551ca3a5d51a75e1c9db22brianp delivery. By default, when the handling of a request requires
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd access to the data within a file -- for example, when delivering a
13cbe1d8f52c8097cb581e7eb259693b64d41d10poirier server-parsed file using <code class="module"><a href="/mod/mod_include.html">mod_include</a></code> -- Apache
13cbe1d8f52c8097cb581e7eb259693b64d41d10poirier memory-maps the file if the OS supports it.</p>
13cbe1d8f52c8097cb581e7eb259693b64d41d10poirier
13cbe1d8f52c8097cb581e7eb259693b64d41d10poirier <p>This memory-mapping sometimes yields a performance improvement.
af18698b10b429b270551ca3a5d51a75e1c9db22brianp But in some environments, it is better to disable the memory-mapping
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd to prevent operational problems:</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <li>On some multiprocessor systems, memory-mapping can reduce the
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd performance of the <code>httpd</code>.</li>
fb77c505254b6e9c925e23e734463e87574f8f40kess <li>With an NFS-mounted <code class="directive"><a href="#documentroot">DocumentRoot</a></code>,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd the <code>httpd</code> may crash due to a segmentation fault if a file
41ef8b3051855b802104193ee0a587515af60a37wrowe is deleted or truncated while the <code>httpd</code> has it
41ef8b3051855b802104193ee0a587515af60a37wrowe memory-mapped.</li>
41ef8b3051855b802104193ee0a587515af60a37wrowe </ul>
41ef8b3051855b802104193ee0a587515af60a37wrowe
41ef8b3051855b802104193ee0a587515af60a37wrowe <p>For server configurations that are vulnerable to these problems,
41ef8b3051855b802104193ee0a587515af60a37wrowe you should disable memory-mapping of delivered files by specifying:</p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <div class="example"><p><code>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess EnableMMAP Off
41ef8b3051855b802104193ee0a587515af60a37wrowe </code></p></div>
41ef8b3051855b802104193ee0a587515af60a37wrowe
41ef8b3051855b802104193ee0a587515af60a37wrowe <p>For NFS mounted files, this feature may be disabled explicitly for
41ef8b3051855b802104193ee0a587515af60a37wrowe the offending files by specifying:</p>
41ef8b3051855b802104193ee0a587515af60a37wrowe
41ef8b3051855b802104193ee0a587515af60a37wrowe <div class="example"><p><code>
41ef8b3051855b802104193ee0a587515af60a37wrowe &lt;Directory "/path-to-nfs-files"&gt;
41ef8b3051855b802104193ee0a587515af60a37wrowe <span class="indent">
fb77c505254b6e9c925e23e734463e87574f8f40kess EnableMMAP Off
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf </span>
41ef8b3051855b802104193ee0a587515af60a37wrowe &lt;/Directory&gt;
41ef8b3051855b802104193ee0a587515af60a37wrowe </code></p></div>
41ef8b3051855b802104193ee0a587515af60a37wrowe
41ef8b3051855b802104193ee0a587515af60a37wrowe</div>
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf<div class="directive-section"><h2><a name="EnableSendfile" id="EnableSendfile">EnableSendfile</a> <a name="enablesendfile" id="enablesendfile">Directive</a></h2>
41ef8b3051855b802104193ee0a587515af60a37wrowe<table class="directive">
41ef8b3051855b802104193ee0a587515af60a37wrowe<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>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnableSendfile On|Off</code></td></tr>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnableSendfile On</code></td></tr>
41ef8b3051855b802104193ee0a587515af60a37wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
41ef8b3051855b802104193ee0a587515af60a37wrowe<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
41ef8b3051855b802104193ee0a587515af60a37wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
41ef8b3051855b802104193ee0a587515af60a37wrowe<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.44 and later</td></tr>
9b5e2c5e769dc678a1aca06df75c32022b2f1492trawick</table>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <p>This directive controls whether <code>httpd</code> may use the sendfile
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess support from the kernel to transmit file contents to the client.
41ef8b3051855b802104193ee0a587515af60a37wrowe By default, when the handling of a request requires no access
41ef8b3051855b802104193ee0a587515af60a37wrowe to the data within a file -- for example, when delivering a
41ef8b3051855b802104193ee0a587515af60a37wrowe static file -- Apache uses sendfile to deliver the file contents
41ef8b3051855b802104193ee0a587515af60a37wrowe without ever reading the file if the OS supports it.</p>
41ef8b3051855b802104193ee0a587515af60a37wrowe
9fb925624300c864fe3969a264e52aa83f3c2dd0slive <p>This sendfile mechanism avoids seperate read and send operations,
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess and buffer allocations. But on some platforms or within some
78f4d313fd5edf76dc5cfb8725e082a08cd29740jwoolley filesystems, it is better to disable this feature to avoid
78f4d313fd5edf76dc5cfb8725e082a08cd29740jwoolley operational problems:</p>
2025fe01de41805f6148851335693aa5ebe2faffnd
2025fe01de41805f6148851335693aa5ebe2faffnd <ul>
9fb925624300c864fe3969a264e52aa83f3c2dd0slive <li>Some platforms may have broken sendfile support that the build
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf system did not detect, especially if the binaries were built on
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess another box and moved to such a machine with broken sendfile
9fb925624300c864fe3969a264e52aa83f3c2dd0slive support.</li>
41ef8b3051855b802104193ee0a587515af60a37wrowe <li>On Linux the use of sendfile triggers TCP-checksum
41ef8b3051855b802104193ee0a587515af60a37wrowe offloading bugs on certain networking cards when using IPv6.</li>
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf <li>With a network-mounted <code class="directive"><a href="#documentroot">DocumentRoot</a></code> (e.g., NFS or SMB),
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf the kernel may be unable to serve the network file through
41ef8b3051855b802104193ee0a587515af60a37wrowe its own cache.</li>
41ef8b3051855b802104193ee0a587515af60a37wrowe </ul>
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf
41ef8b3051855b802104193ee0a587515af60a37wrowe <p>For server configurations that are vulnerable to these problems,
41ef8b3051855b802104193ee0a587515af60a37wrowe you should disable this feature by specifying:</p>
9c233808c898095865fcc0a2dc1cf594d0d8faf3sf
9fb925624300c864fe3969a264e52aa83f3c2dd0slive <div class="example"><p><code>
41ef8b3051855b802104193ee0a587515af60a37wrowe EnableSendfile Off
41ef8b3051855b802104193ee0a587515af60a37wrowe </code></p></div>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>For NFS or SMB mounted files, this feature may be disabled explicitly
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess for the offending files by specifying:</p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
41ef8b3051855b802104193ee0a587515af60a37wrowe <div class="example"><p><code>
41ef8b3051855b802104193ee0a587515af60a37wrowe &lt;Directory "/path-to-nfs-files"&gt;
832853bb93c1831daf24e4727c5ca0e1b1786e83lars <span class="indent">
832853bb93c1831daf24e4727c5ca0e1b1786e83lars EnableSendfile Off
78f97ce162b66a0dbfd7af4dcd9984f162569b04minfrin </span>
832853bb93c1831daf24e4727c5ca0e1b1786e83lars &lt;/Directory&gt;
832853bb93c1831daf24e4727c5ca0e1b1786e83lars </code></p></div>
832853bb93c1831daf24e4727c5ca0e1b1786e83lars
af18698b10b429b270551ca3a5d51a75e1c9db22brianp</div>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp<div class="directive-section"><h2><a name="ErrorDocument" id="ErrorDocument">ErrorDocument</a> <a name="errordocument" id="errordocument">Directive</a></h2>
79c754eb51681c3389cd966753e902c429f78939trawick<table class="directive">
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>What the server will return to the client
79c754eb51681c3389cd966753e902c429f78939trawickin case of an error</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ErrorDocument <var>error-code</var> <var>document</var></code></td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Quoting syntax for text messages is different in Apache
79c754eb51681c3389cd966753e902c429f78939trawick2.0</td></tr>
79c754eb51681c3389cd966753e902c429f78939trawick</table>
79c754eb51681c3389cd966753e902c429f78939trawick <p>In the event of a problem or error, Apache can be configured
79c754eb51681c3389cd966753e902c429f78939trawick to do one of four things,</p>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <ol>
79c754eb51681c3389cd966753e902c429f78939trawick <li>output a simple hardcoded error message</li>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <li>output a customized message</li>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <li>redirect to a local <var>URL-path</var> to handle the
79c754eb51681c3389cd966753e902c429f78939trawick problem/error</li>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <li>redirect to an external <var>URL</var> to handle the
79c754eb51681c3389cd966753e902c429f78939trawick problem/error</li>
79c754eb51681c3389cd966753e902c429f78939trawick </ol>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <p>The first option is the default, while options 2-4 are
79c754eb51681c3389cd966753e902c429f78939trawick configured using the <code class="directive">ErrorDocument</code>
79c754eb51681c3389cd966753e902c429f78939trawick directive, which is followed by the HTTP response code and a URL
79c754eb51681c3389cd966753e902c429f78939trawick or a message. Apache will sometimes offer additional information
79c754eb51681c3389cd966753e902c429f78939trawick regarding the problem/error.</p>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <p>URLs can begin with a slash (/) for local URLs, or be a full
79c754eb51681c3389cd966753e902c429f78939trawick URL which the client can resolve. Alternatively, a message can
79c754eb51681c3389cd966753e902c429f78939trawick be provided to be displayed by the browser. Examples:</p>
79c754eb51681c3389cd966753e902c429f78939trawick
79c754eb51681c3389cd966753e902c429f78939trawick <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorDocument 500 http://foo.example.com/cgi-bin/tester<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorDocument 404 /cgi-bin/bad_urls.pl<br />
003f0c9fda6664daf5092a0e42f65ede20098153slive ErrorDocument 401 /subscription_info.html<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorDocument 403 "Sorry can't allow you access today"
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note that when you specify an <code class="directive">ErrorDocument</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that points to a remote URL (ie. anything with a method such as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>http</code> in front of it), Apache will send a redirect to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive client to tell it where to find the document, even if the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document ends up being on the same server. This has several
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen implications, the most important being that the client will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive the original error status code, but instead will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive a redirect status code. This in turn can confuse web
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive robots and other clients which try to determine if a URL is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive valid using the status code. In addition, if you use a remote
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive URL in an <code>ErrorDocument 401</code>, the client will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive know to prompt the user for a password since it will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive the 401 status code. Therefore, <strong>if you use an
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>ErrorDocument 401</code> directive then it must refer to a local
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document.</strong></p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>Microsoft Internet Explorer (MSIE) will by default ignore
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server-generated error messages when they are "too small" and substitute
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive its own "friendly" error messages. The size threshold varies depending on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the type of error, but in general, if you make your error document
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive greater than 512 bytes, then MSIE will show the server-generated
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive error rather than masking it. More information is available in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Microsoft Knowledgebase article <a href="http://support.microsoft.com/default.aspx?scid=kb;en-us;Q294807">Q294807</a>.</p>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Prior to version 2.0, messages were indicated by prefixing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive them with a single unmatched double quote character.</p>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<h3>See also</h3>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<ul>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<li><a href="/custom-error.html">documentation of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive customizable responses</a></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="directive-section"><h2><a name="ErrorLog" id="ErrorLog">ErrorLog</a> <a name="errorlog" id="errorlog">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Location where the server will log errors</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<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>
f7fe99050600166042c04b8e595fb75499eed7f0geoff<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ErrorLog logs/error_log (Unix) ErrorLog logs/error.log (Windows and OS/2)</code></td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
f7fe99050600166042c04b8e595fb75499eed7f0geoff<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
f7fe99050600166042c04b8e595fb75499eed7f0geoff</table>
f7fe99050600166042c04b8e595fb75499eed7f0geoff <p>The <code class="directive">ErrorLog</code> directive sets the name of
f7fe99050600166042c04b8e595fb75499eed7f0geoff the file to which the server will log any errors it encounters. If
f7fe99050600166042c04b8e595fb75499eed7f0geoff the <var>file-path</var> is not absolute then it is assumed to be
f7fe99050600166042c04b8e595fb75499eed7f0geoff relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
f7fe99050600166042c04b8e595fb75499eed7f0geoff
f7fe99050600166042c04b8e595fb75499eed7f0geoff <div class="example"><h3>Example</h3><p><code>
f7fe99050600166042c04b8e595fb75499eed7f0geoff ErrorLog /var/log/httpd/error_log
f7fe99050600166042c04b8e595fb75499eed7f0geoff </code></p></div>
f7fe99050600166042c04b8e595fb75499eed7f0geoff
f7fe99050600166042c04b8e595fb75499eed7f0geoff <p>If the <var>file-path</var>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive begins with a pipe (|) then it is assumed to be a command to spawn
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to handle the error log.</p>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><h3>Example</h3><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorLog "|/usr/local/bin/httpd_errors"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Using <code>syslog</code> instead of a filename enables logging
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive via syslogd(8) if the system supports it. The default is to use
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive syslog facility <code>local7</code>, but you can override this by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive using the <code>syslog:<var>facility</var></code> syntax where
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <var>facility</var> can be one of the names usually documented in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive syslog(1).</p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><h3>Example</h3><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorLog syslog:user
fb77c505254b6e9c925e23e734463e87574f8f40kess </code></p></div>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>SECURITY: See the <a href="/misc/security_tips.html#serverroot">security tips</a>
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive document for details on why your security could be compromised
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive if the directory where logfiles are stored is writable by
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive anyone other than the user that starts the server.</p>
9b5e2c5e769dc678a1aca06df75c32022b2f1492trawick <div class="warning"><h3>Note</h3>
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>When entering a file path on non-Unix platforms, care should be taken
fb77c505254b6e9c925e23e734463e87574f8f40kess to make sure that only forward slashed are used even though the platform
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive may allow the use of back slashes. In general it is a good idea to always
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive use forward slashes throughout the configuration files.</p>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive </div>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<h3>See also</h3>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<ul>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<li><code class="directive"><a href="#loglevel">LogLevel</a></code></li>
69fba5b8aa0b0dc408f649cfdaab064ce120b05bslive<li><a href="/logs.html">Apache Log Files</a></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor</ul>
b5d3d68a9f683722eac7a3ca507c3e571908dfc0rbowen</div>
b5d3d68a9f683722eac7a3ca507c3e571908dfc0rbowen<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
b5d3d68a9f683722eac7a3ca507c3e571908dfc0rbowen<div class="directive-section"><h2><a name="FileETag" id="FileETag">FileETag</a> <a name="fileetag" id="fileetag">Directive</a></h2>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>File attributes used to create the ETag
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveHTTP response header</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>FileETag <var>component</var> ...</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>FileETag INode MTime Size</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess</table>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>
4a13940dc2990df0a798718d3a3f9cf1566c2217bjh The <code class="directive">FileETag</code> directive configures the file
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive attributes that are used to create the <code>ETag</code> (entity
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive tag) response header field when the document is based on a file.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (The <code>ETag</code> value is used in cache management to save
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive network bandwidth.) In Apache 1.3.22 and earlier, the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>ETag</code> value was <em>always</em> formed
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive from the file's inode, size, and last-modified time (mtime). The
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <code class="directive">FileETag</code> directive allows you to choose
c68acc9d712af079afa2bd1a5a4aeef9a3ea573ckess which of these -- if any -- should be used. The recognized keywords are:
fb109b84906e3ee61680aa289953c2f9e859354erbowen </p>
fb109b84906e3ee61680aa289953c2f9e859354erbowen
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dl>
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dt><strong>INode</strong></dt>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <dd>The file's i-node number will be included in the calculation</dd>
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dt><strong>MTime</strong></dt>
960188481b7025ac8ef7221b67af83dd27e46cd0rjung <dd>The date and time the file was last modified will be included</dd>
960188481b7025ac8ef7221b67af83dd27e46cd0rjung <dt><strong>Size</strong></dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>The number of bytes in the file will be included</dd>
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dt><strong>All</strong></dt>
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dd>All available fields will be used. This is equivalent to:
fb109b84906e3ee61680aa289953c2f9e859354erbowen <div class="example"><p><code>FileETag INode MTime Size</code></p></div></dd>
fb109b84906e3ee61680aa289953c2f9e859354erbowen <dt><strong>None</strong></dt>
960188481b7025ac8ef7221b67af83dd27e46cd0rjung <dd>If a document is file-based, no <code>ETag</code> field will be
960188481b7025ac8ef7221b67af83dd27e46cd0rjung included in the response</dd>
960188481b7025ac8ef7221b67af83dd27e46cd0rjung </dl>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <code>INode</code>, <code>MTime</code>, and <code>Size</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive keywords may be prefixed with either <code>+</code> or <code>-</code>,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd which allow changes to be made to the default setting inherited
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd from a broader scope. Any keyword appearing without such a prefix
5155e92c6100b47513159eee1b2b9914ab204a5acovener immediately and completely cancels the inherited setting.</p>
5155e92c6100b47513159eee1b2b9914ab204a5acovener
5155e92c6100b47513159eee1b2b9914ab204a5acovener <p>If a directory's configuration includes
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>FileETag&nbsp;INode&nbsp;MTime&nbsp;Size</code>, and a
fb109b84906e3ee61680aa289953c2f9e859354erbowen subdirectory's includes <code>FileETag&nbsp;-INode</code>,
fb109b84906e3ee61680aa289953c2f9e859354erbowen the setting for that subdirectory (which will be inherited by
fb109b84906e3ee61680aa289953c2f9e859354erbowen any sub-subdirectories that don't override it) will be equivalent to
fb109b84906e3ee61680aa289953c2f9e859354erbowen <code>FileETag&nbsp;MTime&nbsp;Size</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
9b5e2c5e769dc678a1aca06df75c32022b2f1492trawick<div class="directive-section"><h2><a name="Files" id="Files">&lt;Files&gt;</a> <a name="files" id="files">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
2bac697634d965d9d9a921a99a68b2c454c8a95dbnicholes<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply to matched
2bac697634d965d9d9a921a99a68b2c454c8a95dbnicholesfilenames</td></tr>
d950cf9262224a223e2ff5c51393708071e14b94covener<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>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2bac697634d965d9d9a921a99a68b2c454c8a95dbnicholes<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
2bac697634d965d9d9a921a99a68b2c454c8a95dbnicholes<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen <p>The <code class="directive">&lt;Files&gt;</code> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive limits the scope of the enclosed directives by filename. It is comparable
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf and <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf directives. It should be matched with a <code>&lt;/Files&gt;</code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf directive. The directives given within this section will be applied to
e302f38fd646764ce1a1e1c578d794aef514a9e5sf any object with a basename (last component of filename) matching the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf specified filename. <code class="directive">&lt;Files&gt;</code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf sections are processed in the order they appear in the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf configuration file, after the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections and
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code>.htaccess</code> files are read, but before <code class="directive"><a href="#location">&lt;Location&gt;</a></code> sections. Note
e302f38fd646764ce1a1e1c578d794aef514a9e5sf that <code class="directive">&lt;Files&gt;</code> can be nested
e302f38fd646764ce1a1e1c578d794aef514a9e5sf inside <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections to restrict the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf portion of the filesystem they apply to.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>The <var>filename</var> argument should include a filename, or
e302f38fd646764ce1a1e1c578d794aef514a9e5sf a wild-card string, where <code>?</code> matches any single character,
e302f38fd646764ce1a1e1c578d794aef514a9e5sf and <code>*</code> matches any sequences of characters. Extended regular
e302f38fd646764ce1a1e1c578d794aef514a9e5sf expressions can also be used, with the addition of the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code>~</code> character. For example:</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
18ee8bb3db5cc3b04291f89301bd5d14dc271066lgentis <div class="example"><p><code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;Files ~ "\.(gif|jpe?g|png)$"&gt;
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </code></p></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>would match most common Internet graphics formats. <code class="directive"><a href="#filesmatch">&lt;FilesMatch&gt;</a></code> is preferred,
e302f38fd646764ce1a1e1c578d794aef514a9e5sf however.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <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
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code>.htaccess</code> files. This allows users to control access to
e302f38fd646764ce1a1e1c578d794aef514a9e5sf their own files, at a file-by-file level.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<h3>See also</h3>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<ul>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt;
e302f38fd646764ce1a1e1c578d794aef514a9e5sf and &lt;Files&gt; sections work</a> for an explanation of how these
e302f38fd646764ce1a1e1c578d794aef514a9e5sf different sections are combined when a request is received</li>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</ul>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="directive-section"><h2><a name="FilesMatch" id="FilesMatch">&lt;FilesMatch&gt;</a> <a name="filesmatch" id="filesmatch">Directive</a></h2>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<table class="directive">
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply to regular-expression matched
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsffilenames</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<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>
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf</table>
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf <p>The <code class="directive">&lt;FilesMatch&gt;</code> directive
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf limits the scope of the enclosed directives by filename, just as the
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf <code class="directive"><a href="#files">&lt;Files&gt;</a></code> directive
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf does. However, it accepts a regular expression. For example:</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <div class="example"><p><code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;FilesMatch "\.(gif|jpe?g|png)$"&gt;
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </code></p></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>would match most common Internet graphics formats.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<h3>See also</h3>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<ul>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt;
e302f38fd646764ce1a1e1c578d794aef514a9e5sf and &lt;Files&gt; sections work</a> for an explanation of how these
e302f38fd646764ce1a1e1c578d794aef514a9e5sf different sections are combined when a request is received</li>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</ul>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="directive-section"><h2><a name="ForceType" id="ForceType">ForceType</a> <a name="forcetype" id="forcetype">Directive</a></h2>
4497075b5e08b0c8ee89425a1758258ae80550fcsf<table class="directive">
4497075b5e08b0c8ee89425a1758258ae80550fcsf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Forces all matching files to be served with the specified
4497075b5e08b0c8ee89425a1758258ae80550fcsfMIME content-type</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ForceType <var>MIME-type</var>|None</code></td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Moved to the core in Apache 2.0</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</table>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>When placed into an <code>.htaccess</code> file or a
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>, or
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code class="directive"><a href="#location">&lt;Location&gt;</a></code> or
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code class="directive"><a href="#files">&lt;Files&gt;</a></code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf section, this directive forces all matching files to be served
e302f38fd646764ce1a1e1c578d794aef514a9e5sf with the content type identification given by
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <var>MIME-type</var>. For example, if you had a directory full of
e302f38fd646764ce1a1e1c578d794aef514a9e5sf GIF files, but did not want to label them all with <code>.gif</code>,
e302f38fd646764ce1a1e1c578d794aef514a9e5sf you might want to use:</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <div class="example"><p><code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf ForceType image/gif
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </code></p></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>Note that unlike <code class="directive"><a href="#defaulttype">DefaultType</a></code>,
e302f38fd646764ce1a1e1c578d794aef514a9e5sf this directive overrides all mime-type associations, including
e302f38fd646764ce1a1e1c578d794aef514a9e5sf filename extensions, that might identify the media type.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>You can override any <code class="directive">ForceType</code> setting
e302f38fd646764ce1a1e1c578d794aef514a9e5sf by using the value of <code>None</code>:</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <div class="example"><p><code>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf # force all files to be image/gif:<br />
4497075b5e08b0c8ee89425a1758258ae80550fcsf &lt;Location /images&gt;<br />
4497075b5e08b0c8ee89425a1758258ae80550fcsf <span class="indent">
4497075b5e08b0c8ee89425a1758258ae80550fcsf ForceType image/gif<br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </span>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;/Location&gt;<br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf # but normal mime-type associations here:<br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;Location /images/mixed&gt;<br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <span class="indent">
e302f38fd646764ce1a1e1c578d794aef514a9e5sf ForceType None<br />
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </span>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;/Location&gt;
e302f38fd646764ce1a1e1c578d794aef514a9e5sf </code></p></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="directive-section"><h2><a name="HostnameLookups" id="HostnameLookups">HostnameLookups</a> <a name="hostnamelookups" id="hostnamelookups">Directive</a></h2>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<table class="directive">
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables DNS lookups on client IP addresses</td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>HostnameLookups On|Off|Double</code></td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>HostnameLookups Off</code></td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf</table>
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf <p>This directive enables DNS lookups so that host names can be
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf logged (and passed to CGIs/SSIs in <code>REMOTE_HOST</code>).
9228509ac5da8374df4a5d50b7da139e7b31f8a3sf The value <code>Double</code> refers to doing double-reverse
e302f38fd646764ce1a1e1c578d794aef514a9e5sf DNS lookup. That is, after a reverse lookup is performed, a forward
e302f38fd646764ce1a1e1c578d794aef514a9e5sf lookup is then performed on that result. At least one of the ip
e302f38fd646764ce1a1e1c578d794aef514a9e5sf addresses in the forward lookup must match the original
e302f38fd646764ce1a1e1c578d794aef514a9e5sf address. (In "tcpwrappers" terminology this is called
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code>PARANOID</code>.)</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <p>Regardless of the setting, when <code class="module"><a href="/mod/mod_authz_host.html">mod_authz_host</a></code> is
e302f38fd646764ce1a1e1c578d794aef514a9e5sf used for controlling access by hostname, a double reverse lookup
e302f38fd646764ce1a1e1c578d794aef514a9e5sf will be performed. This is necessary for security. Note that the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf result of this double-reverse isn't generally available unless you
e302f38fd646764ce1a1e1c578d794aef514a9e5sf set <code>HostnameLookups Double</code>. For example, if only
e302f38fd646764ce1a1e1c578d794aef514a9e5sf <code>HostnameLookups On</code> and a request is made to an object
ce4dc40a4e87991087488f70d96d3447d7557294sf that is protected by hostname restrictions, regardless of whether
ce4dc40a4e87991087488f70d96d3447d7557294sf the double-reverse fails or not, CGIs will still be passed the
e302f38fd646764ce1a1e1c578d794aef514a9e5sf single-reverse result in <code>REMOTE_HOST</code>.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf <p>The default is <code>Off</code> in order to save the network
e302f38fd646764ce1a1e1c578d794aef514a9e5sf traffic for those sites that don't truly need the reverse
e302f38fd646764ce1a1e1c578d794aef514a9e5sf lookups done. It is also better for the end users because they
e302f38fd646764ce1a1e1c578d794aef514a9e5sf don't have to suffer the extra latency that a lookup entails.
e302f38fd646764ce1a1e1c578d794aef514a9e5sf Heavily loaded sites should leave this directive
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf <code>Off</code>, since DNS lookups can take considerable
e302f38fd646764ce1a1e1c578d794aef514a9e5sf amounts of time. The utility <a href="/programs/logresolve.html">logresolve</a>, compiled by default
e302f38fd646764ce1a1e1c578d794aef514a9e5sf to the <code>bin</code> subdirectory of your installation directory, can
e302f38fd646764ce1a1e1c578d794aef514a9e5sf be used to look up host names from logged IP addresses offline.</p>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf
b5c4b00201fdc3ed11c6cc05cf3f9a7912ac0cfbsf</div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<div class="directive-section"><h2><a name="IfDefine" id="IfDefine">&lt;IfDefine&gt;</a> <a name="ifdefine" id="ifdefine">Directive</a></h2>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<table class="directive">
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Encloses directives that will be processed only
e302f38fd646764ce1a1e1c578d794aef514a9e5sfif a test is true at startup</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;IfDefine [!]<var>parameter-name</var>&gt; ...
e302f38fd646764ce1a1e1c578d794aef514a9e5sf &lt;/IfDefine&gt;</code></td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
e302f38fd646764ce1a1e1c578d794aef514a9e5sf</table>
a8ee031b2224ce5473826c9d4f603681589245fawrowe <p>The <code>&lt;IfDefine <var>test</var>&gt;...&lt;/IfDefine&gt;
a8ee031b2224ce5473826c9d4f603681589245fawrowe </code> section is used to mark directives that are conditional. The
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor directives within an <code class="directive">&lt;IfDefine&gt;</code>
a8ee031b2224ce5473826c9d4f603681589245fawrowe section are only processed if the <var>test</var> is true. If <var>
a8ee031b2224ce5473826c9d4f603681589245fawrowe test</var> is false, everything between the start and end markers is
a8ee031b2224ce5473826c9d4f603681589245fawrowe ignored.</p>
a8ee031b2224ce5473826c9d4f603681589245fawrowe
a8ee031b2224ce5473826c9d4f603681589245fawrowe <p>The <var>test</var> in the <code class="directive">&lt;IfDefine&gt;</code> section directive can be one of two forms:</p>
a8ee031b2224ce5473826c9d4f603681589245fawrowe
a8ee031b2224ce5473826c9d4f603681589245fawrowe <ul>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <li><var>parameter-name</var></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
a8ee031b2224ce5473826c9d4f603681589245fawrowe <li><code>!</code><var>parameter-name</var></li>
a8ee031b2224ce5473826c9d4f603681589245fawrowe </ul>
a8ee031b2224ce5473826c9d4f603681589245fawrowe
a8ee031b2224ce5473826c9d4f603681589245fawrowe <p>In the former case, the directives between the start and end
a8ee031b2224ce5473826c9d4f603681589245fawrowe markers are only processed if the parameter named
a8ee031b2224ce5473826c9d4f603681589245fawrowe <var>parameter-name</var> is defined. The second format reverses
a8ee031b2224ce5473826c9d4f603681589245fawrowe the test, and only processes the directives if
a8ee031b2224ce5473826c9d4f603681589245fawrowe <var>parameter-name</var> is <strong>not</strong> defined.</p>
a8ee031b2224ce5473826c9d4f603681589245fawrowe
34b157732214cedcd129cd9fe7c4290757505d60minfrin <p>The <var>parameter-name</var> argument is a define as given on
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor the <code>httpd</code> command line via <code>-D<var>parameter-</var>
a8ee031b2224ce5473826c9d4f603681589245fawrowe </code>, at the time the server was started.</p>
a8ee031b2224ce5473826c9d4f603681589245fawrowe
a8ee031b2224ce5473826c9d4f603681589245fawrowe <p><code class="directive">&lt;IfDefine&gt;</code> sections are
a8ee031b2224ce5473826c9d4f603681589245fawrowe nest-able, which can be used to implement simple
02c86afa991026c4146423dc84bc126e57d28df6wrowe multiple-parameter tests. Example:</p>
34b157732214cedcd129cd9fe7c4290757505d60minfrin
34b157732214cedcd129cd9fe7c4290757505d60minfrin <div class="example"><p><code>
34b157732214cedcd129cd9fe7c4290757505d60minfrin httpd -DReverseProxy ...<br />
34b157732214cedcd129cd9fe7c4290757505d60minfrin <br />
a8ee031b2224ce5473826c9d4f603681589245fawrowe # httpd.conf<br />
a8ee031b2224ce5473826c9d4f603681589245fawrowe &lt;IfDefine ReverseProxy&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive LoadModule rewrite_module modules/mod_rewrite.so<br />
003f0c9fda6664daf5092a0e42f65ede20098153slive LoadModule proxy_module modules/libproxy.so<br />
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covener </span>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd &lt;/IfDefine&gt;
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="IfModule" id="IfModule">&lt;IfModule&gt;</a> <a name="ifmodule" id="ifmodule">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Encloses directives that are processed conditional on the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivepresence or absence of a specific module</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;IfModule [!]<var>module-name</var>&gt; ...
fb77c505254b6e9c925e23e734463e87574f8f40kess &lt;/IfModule&gt;</code></td></tr>
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covener<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
c976a7c7d20f2be319b128dd7d0b1568da224c0arbowen<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <code>&lt;IfModule <var>test</var>&gt;...&lt;/IfModule&gt;</code>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd section is used to mark directives that are conditional on the presence of
530eba85dbd41b8a0fa5255d3648d1440199a661slive a specific module. The directives within an <code class="directive">&lt;IfModule&gt;</code> section are only processed if the <var>test</var>
530eba85dbd41b8a0fa5255d3648d1440199a661slive is true. If <var>test</var> is false, everything between the start and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive end markers is ignored.</p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <var>test</var> in the <code class="directive">&lt;IfModule&gt;</code> section directive can be one of two forms:</p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <ul>
530eba85dbd41b8a0fa5255d3648d1440199a661slive <li><var>module name</var></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <li>!<var>module name</var></li>
530eba85dbd41b8a0fa5255d3648d1440199a661slive </ul>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>In the former case, the directives between the start and end
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive markers are only processed if the module named <var>module
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd name</var> is included in Apache -- either compiled in or
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd dynamically loaded using <code class="directive"><a href="/mod/mod_so.html#loadmodule">LoadModule</a></code>. The second format reverses the test,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd and only processes the directives if <var>module name</var> is
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <strong>not</strong> included.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>The <var>module name</var> argument is the file name of the
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd module, at the time it was compiled. For example,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>mod_rewrite.c</code>. If a module consists of several
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd source files, use the name of the file containing the string
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>STANDARD20_MODULE_STUFF</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><code class="directive">&lt;IfModule&gt;</code> sections are
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd nest-able, which can be used to implement simple multiple-module
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem tests.</p>
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem <div class="note">This section should only be used if you need to have one
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem configuration file that works whether or not a specific module
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem is available. In normal operation, directives need not be
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem placed in <code class="directive">&lt;IfModule&gt;</code>
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem sections.</div>
0db981f8fdfb62c5149efa079f0369b73d472d04rpluem
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covener</div>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<div class="directive-section"><h2><a name="Include" id="Include">Include</a> <a name="include" id="include">Directive</a></h2>
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covener<table class="directive">
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covener<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Includes other configuration files from within
a5f060e0c74a44cb8896ae794c08f94f7c9a46a7covenerthe server configuration files</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<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>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Wildcard matching available in 2.0.41 and later</td></tr>
003f0c9fda6664daf5092a0e42f65ede20098153slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive allows inclusion of other configuration files
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd from within the server configuration files.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Shell-style (<code>fnmatch()</code>) wildcard characters can be used to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive include several files at once, in alphabetical order. In
003f0c9fda6664daf5092a0e42f65ede20098153slive addition, if <code class="directive">Include</code> points to a directory,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive rather than a file, Apache will read all files in that directory
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive and any subdirectory. But including entire directories is not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive recommended, because it is easy to accidentally leave temporary
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess files in a directory that can cause <code>httpd</code> to
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess fail.</p>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <p>The file path specified may be an absolute path, or may be relative
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess to the <code class="directive"><a href="#serverroot">ServerRoot</a></code> directory.</p>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Examples:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Include /usr/local/apache2/conf/ssl.conf<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Include /usr/local/apache2/conf/vhosts/*.conf
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Or, providing paths relative to your <code class="directive"><a href="#serverroot">ServerRoot</a></code> directory:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Include conf/ssl.conf<br />
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd Include conf/vhosts/*.conf
fb77c505254b6e9c925e23e734463e87574f8f40kess </code></p></div>
030108b1816bcda3d925df65357feabdce83bc94slive
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <p>Running <code>apachectl configtest</code> will give you a list
030108b1816bcda3d925df65357feabdce83bc94slive of the files that are being processed during the configuration
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive check:</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><p><code>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd root@host# apachectl configtest<br />
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd Processing config file: /usr/local/apache2/conf/ssl.conf<br />
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd Processing config file: /usr/local/apache2/conf/vhosts/vhost1.conf<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess Processing config file: /usr/local/apache2/conf/vhosts/vhost2.conf<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess Syntax OK
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/programs/apachectl.html">apachectl</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
fb77c505254b6e9c925e23e734463e87574f8f40kess</div>
fb77c505254b6e9c925e23e734463e87574f8f40kess<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="KeepAlive" id="KeepAlive">KeepAlive</a> <a name="keepalive" id="keepalive">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables HTTP persistent connections</td></tr>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>KeepAlive On|Off</code></td></tr>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>KeepAlive On</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>The Keep-Alive extension to HTTP/1.0 and the persistent
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive connection feature of HTTP/1.1 provide long-lived HTTP sessions
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd which allow multiple requests to be sent over the same TCP
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive connection. In some cases this has been shown to result in an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive almost 50% speedup in latency times for HTML documents with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive many images. To enable Keep-Alive connections, set
003f0c9fda6664daf5092a0e42f65ede20098153slive <code>KeepAlive On</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For HTTP/1.0 clients, Keep-Alive connections will only be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive used if they are specifically requested by a client. In
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess addition, a Keep-Alive connection with an HTTP/1.0 client can
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess only be used when the length of the content is known in
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor advance. This implies that dynamic content such as CGI output,
030108b1816bcda3d925df65357feabdce83bc94slive SSI pages, and server-generated directory listings will
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd generally not use Keep-Alive connections to HTTP/1.0 clients.
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd For HTTP/1.1 clients, persistent connections are the default
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd unless otherwise specified. If the client requests it, chunked
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd encoding will be used in order to send content of unknown
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive length over persistent connections.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess<ul>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<li><code class="directive"><a href="#maxkeepaliverequests">MaxKeepAliveRequests</a></code></li>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess</ul>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="KeepAliveTimeout" id="KeepAliveTimeout">KeepAliveTimeout</a> <a name="keepalivetimeout" id="keepalivetimeout">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Amount of time the server will wait for subsequent
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliverequests on a persistent connection</td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>KeepAliveTimeout <var>seconds</var></code></td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>KeepAliveTimeout 15</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
003f0c9fda6664daf5092a0e42f65ede20098153slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The number of seconds Apache will wait for a subsequent
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request before closing the connection. Once a request has been
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive received, the timeout value specified by the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#timeout">Timeout</a></code> directive applies.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Setting <code class="directive">KeepAliveTimeout</code> to a high value
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive may cause performance problems in heavily loaded servers. The
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive higher the timeout, the more server processes will be kept
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding occupied waiting on connections with idle clients.</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
fb77c505254b6e9c925e23e734463e87574f8f40kess</div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="directive-section"><h2><a name="Limit" id="Limit">&lt;Limit&gt;</a> <a name="limit" id="limit">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restrict enclosed access controls to only certain HTTP
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivemethods</td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Limit <var>method</var> [<var>method</var>] ... &gt; ...
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding &lt;/Limit&gt;</code></td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
7654193c1faf603feec999850322ad79e6c551bcnd<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
b24c77ceb4cea5ffa92536e19f0aa83608960dc4fielding<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
c97e8972ab1f4dd167e3dc4db87daf91114009fbnd</table>
7654193c1faf603feec999850322ad79e6c551bcnd <p>Access controls are normally effective for
7654193c1faf603feec999850322ad79e6c551bcnd <strong>all</strong> access methods, and this is the usual
7654193c1faf603feec999850322ad79e6c551bcnd desired behavior. <strong>In the general case, access control
7654193c1faf603feec999850322ad79e6c551bcnd directives should not be placed within a
7654193c1faf603feec999850322ad79e6c551bcnd <code class="directive">&lt;Limit&gt;</code> section.</strong></p>
7654193c1faf603feec999850322ad79e6c551bcnd
7654193c1faf603feec999850322ad79e6c551bcnd <p>The purpose of the <code class="directive">&lt;Limit&gt;</code>
7654193c1faf603feec999850322ad79e6c551bcnd directive is to restrict the effect of the access controls to the
7654193c1faf603feec999850322ad79e6c551bcnd nominated HTTP methods. For all other methods, the access
7654193c1faf603feec999850322ad79e6c551bcnd restrictions that are enclosed in the <code class="directive">&lt;Limit&gt;</code> bracket <strong>will have no
7654193c1faf603feec999850322ad79e6c551bcnd effect</strong>. The following example applies the access control
7654193c1faf603feec999850322ad79e6c551bcnd only to the methods <code>POST</code>, <code>PUT</code>, and
c97e8972ab1f4dd167e3dc4db87daf91114009fbnd <code>DELETE</code>, leaving all other methods unprotected:</p>
7654193c1faf603feec999850322ad79e6c551bcnd
7654193c1faf603feec999850322ad79e6c551bcnd <div class="example"><p><code>
7654193c1faf603feec999850322ad79e6c551bcnd &lt;Limit POST PUT DELETE&gt;<br />
439acee10571861c670c438038a62f90a08bf137covener <span class="indent">
439acee10571861c670c438038a62f90a08bf137covener Require valid-user<br />
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor </span>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor &lt;/Limit&gt;
439acee10571861c670c438038a62f90a08bf137covener </code></p></div>
439acee10571861c670c438038a62f90a08bf137covener
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The method names listed can be one or more of: <code>GET</code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>POST</code>, <code>PUT</code>, <code>DELETE</code>,
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener <code>CONNECT</code>, <code>OPTIONS</code>,
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener <code>PATCH</code>, <code>PROPFIND</code>, <code>PROPPATCH</code>,
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener <code>MKCOL</code>, <code>COPY</code>, <code>MOVE</code>,
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener <code>LOCK</code>, and <code>UNLOCK</code>. <strong>The method name is
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener case-sensitive.</strong> If <code>GET</code> is used it will also
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener restrict <code>HEAD</code> requests. The <code>TRACE</code> method
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener cannot be limited.</p>
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener <div class="warning">A <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> section should always be
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener used in preference to a <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code> section when restricting access,
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener since a <code class="directive"><a href="#limitexcept">&lt;LimitExcept&gt;</a></code> section provides protection
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener against arbitrary methods.</div>
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor</div>
df5042f69eea159c73cd7b16542d4ca7d879b0b5trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener<div class="directive-section"><h2><a name="LimitExcept" id="LimitExcept">&lt;LimitExcept&gt;</a> <a name="limitexcept" id="limitexcept">Directive</a></h2>
c3e2e664a67b1adb9b6a6b91ff161f4f562cecf6covener<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restrict access controls to all HTTP methods
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveexcept the named ones</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;LimitExcept <var>method</var> [<var>method</var>] ... &gt; ...
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/LimitExcept&gt;</code></td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><code class="directive">&lt;LimitExcept&gt;</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>&lt;/LimitExcept&gt;</code> are used to enclose
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a group of access control directives which will then apply to any
fb77c505254b6e9c925e23e734463e87574f8f40kess HTTP access method <strong>not</strong> listed in the arguments;
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess 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
9b5e2c5e769dc678a1aca06df75c32022b2f1492trawick both standard and nonstandard/unrecognized methods. See the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive documentation for <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code> for more details.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
9ed9eaf871c58d281af02e76125ceadb5060afa5nd <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;LimitExcept POST GET&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require valid-user<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess </span>
fb77c505254b6e9c925e23e734463e87574f8f40kess &lt;/LimitExcept&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
fb77c505254b6e9c925e23e734463e87574f8f40kess<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="LimitInternalRecursion" id="LimitInternalRecursion">LimitInternalRecursion</a> <a name="limitinternalrecursion" id="limitinternalrecursion">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Determine maximum number of internal redirects and nested
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivesubrequests</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitInternalRecursion <var>number</var> [<var>number</var>]</code></td></tr>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitInternalRecursion 10</code></td></tr>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a1ef40892ffa2b44fc249423c5b6c42a74a84c68nd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.0.47 and later</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
750d12c59545dbbac70390988de94f7e901b08f2niq redirects the original request to a CGI script. A subrequest is Apache's
750d12c59545dbbac70390988de94f7e901b08f2niq mechanism to find out what would happen for some URI if it were requested.
750d12c59545dbbac70390988de94f7e901b08f2niq For example, <code class="module"><a href="/mod/mod_dir.html">mod_dir</a></code> uses subrequests to look for the
750d12c59545dbbac70390988de94f7e901b08f2niq files listed in the <code class="directive"><a href="/mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>
750d12c59545dbbac70390988de94f7e901b08f2niq directive.</p>
750d12c59545dbbac70390988de94f7e901b08f2niq
750d12c59545dbbac70390988de94f7e901b08f2niq <p><code class="directive">LimitInternalRecursion</code> prevents the server
750d12c59545dbbac70390988de94f7e901b08f2niq from crashing when entering an infinite loop of internal redirects or
750d12c59545dbbac70390988de94f7e901b08f2niq subrequests. Such loops are usually caused by misconfigurations.</p>
750d12c59545dbbac70390988de94f7e901b08f2niq
750d12c59545dbbac70390988de94f7e901b08f2niq <p>The directive stores two different limits, which are evaluated on
750d12c59545dbbac70390988de94f7e901b08f2niq per-request basis. The first <var>number</var> is the maximum number of
750d12c59545dbbac70390988de94f7e901b08f2niq internal redirects, that may follow each other. The second <var>number</var>
750d12c59545dbbac70390988de94f7e901b08f2niq determines, how deep subrequests may be nested. If you specify only one
750d12c59545dbbac70390988de94f7e901b08f2niq <var>number</var>, it will be assigned to both limits.</p>
750d12c59545dbbac70390988de94f7e901b08f2niq
750d12c59545dbbac70390988de94f7e901b08f2niq <div class="example"><h3>Example</h3><p><code>
750d12c59545dbbac70390988de94f7e901b08f2niq LimitInternalRecursion 5
750d12c59545dbbac70390988de94f7e901b08f2niq </code></p></div>
750d12c59545dbbac70390988de94f7e901b08f2niq
750d12c59545dbbac70390988de94f7e901b08f2niq</div>
13fa73dcc1b52bc8b86ac7008ce81e8c94c1c7f2rbowen<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
13fa73dcc1b52bc8b86ac7008ce81e8c94c1c7f2rbowen<div class="directive-section"><h2><a name="LimitRequestBody" id="LimitRequestBody">LimitRequestBody</a> <a name="limitrequestbody" id="limitrequestbody">Directive</a></h2>
13fa73dcc1b52bc8b86ac7008ce81e8c94c1c7f2rbowen<table class="directive">
13fa73dcc1b52bc8b86ac7008ce81e8c94c1c7f2rbowen<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Restricts the total size of the HTTP request body sent
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalicfrom the client</td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestBody <var>bytes</var></code></td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestBody 0</code></td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1a0ca5f6b566a5eb77d63f466fcf78fb388a4182igalic</table>
750d12c59545dbbac70390988de94f7e901b08f2niq <p>This directive specifies the number of <var>bytes</var> from 0
750d12c59545dbbac70390988de94f7e901b08f2niq (meaning unlimited) to 2147483647 (2GB) that are allowed in a
94aba9caa9b2f7a0e95a55f51264c908b69470e2igalic request body.</p>
94aba9caa9b2f7a0e95a55f51264c908b69470e2igalic
750d12c59545dbbac70390988de94f7e901b08f2niq <p>The <code class="directive">LimitRequestBody</code> directive allows
750d12c59545dbbac70390988de94f7e901b08f2niq the user to set a limit on the allowed size of an HTTP request
750d12c59545dbbac70390988de94f7e901b08f2niq message body within the context in which the directive is given
750d12c59545dbbac70390988de94f7e901b08f2niq (server, per-directory, per-file or per-location). If the client
750d12c59545dbbac70390988de94f7e901b08f2niq request exceeds that limit, the server will return an error
750d12c59545dbbac70390988de94f7e901b08f2niq response instead of servicing the request. The size of a normal
750d12c59545dbbac70390988de94f7e901b08f2niq request message body will vary greatly depending on the nature of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the resource and the methods allowed on that resource. CGI scripts
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive typically use the message body for retrieving form information.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Implementations of the <code>PUT</code> method will require
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a value at least as large as any representation that the server
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd wishes to accept for that resource.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive gives the server administrator greater
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive control over abnormal client request behavior, which may be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive useful for avoiding some forms of denial-of-service
003f0c9fda6664daf5092a0e42f65ede20098153slive attacks.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If, for example, you are permitting file upload to a particular
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd location, and wish to limit the size of the uploaded file to 100K,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd you might use the following directive:</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><p><code>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd LimitRequestBody 102400
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="LimitRequestFields" id="LimitRequestFields">LimitRequestFields</a> <a name="limitrequestfields" id="limitrequestfields">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the number of HTTP request header fields that
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cndwill be accepted from the client</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestFields <var>number</var></code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestFields 100</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p><var>Number</var> is an integer from 0 (meaning unlimited) to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 32767. The default value is defined by the compile-time
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl constant <code>DEFAULT_LIMIT_REQUEST_FIELDS</code> (100 as
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl distributed).</p>
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl
6e483e0b8aa3fa574288a7452221392a03e2b9a3noodl <p>The <code class="directive">LimitRequestFields</code> directive allows
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the server administrator to modify the limit on the number of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request header fields allowed in an HTTP request. A server needs
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive this value to be larger than the number of fields that a normal
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive client request might include. The number of request header fields
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive used by a client rarely exceeds 20, but this may vary among
130d299c4b2b15be45532a176604c71fdc7bea5bnd different client implementations, often depending upon the extent
a00429a6b3b4dbb113b6dc67cfc0507f610276e9takashi to which a user has configured their browser to support detailed
130d299c4b2b15be45532a176604c71fdc7bea5bnd content negotiation. Optional HTTP extensions are often expressed
130d299c4b2b15be45532a176604c71fdc7bea5bnd using request header fields.</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>This directive gives the server administrator greater
a00429a6b3b4dbb113b6dc67cfc0507f610276e9takashi control over abnormal client request behavior, which may be
a00429a6b3b4dbb113b6dc67cfc0507f610276e9takashi useful for avoiding some forms of denial-of-service attacks.
955d7fc3e7adb6463b7243e15c04e858718e799etakashi The value should be increased if normal clients see an error
955d7fc3e7adb6463b7243e15c04e858718e799etakashi response from the server that indicates too many fields were
955d7fc3e7adb6463b7243e15c04e858718e799etakashi sent in the request.</p>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi
955d7fc3e7adb6463b7243e15c04e858718e799etakashi <p>For example:</p>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi
955d7fc3e7adb6463b7243e15c04e858718e799etakashi <div class="example"><p><code>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi LimitRequestFields 50
955d7fc3e7adb6463b7243e15c04e858718e799etakashi </code></p></div>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi
78f97ce162b66a0dbfd7af4dcd9984f162569b04minfrin
955d7fc3e7adb6463b7243e15c04e858718e799etakashi</div>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi<div class="directive-section"><h2><a name="LimitRequestFieldSize" id="LimitRequestFieldSize">LimitRequestFieldSize</a> <a name="limitrequestfieldsize" id="limitrequestfieldsize">Directive</a></h2>
955d7fc3e7adb6463b7243e15c04e858718e799etakashi<table class="directive">
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the size of the HTTP request header allowed from the
130d299c4b2b15be45532a176604c71fdc7bea5bndclient</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestFieldsize <var>bytes</var></code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestFieldsize 8190</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive specifies the number of <var>bytes</var> from 0
a04a96aae08a62f2d9d5833b3313a9751fa3f680yoshiki to the value of the compile-time constant
55d36f9b61520c2374ab463e77e8a62daa416398nd <code>DEFAULT_LIMIT_REQUEST_FIELDSIZE</code> (8190 as
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess distributed) that will be allowed in an HTTP request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive header.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <code class="directive">LimitRequestFieldSize</code> directive
003f0c9fda6664daf5092a0e42f65ede20098153slive allows the server administrator to reduce the limit on the allowed
55d36f9b61520c2374ab463e77e8a62daa416398nd size of an HTTP request header field below the normal input buffer
55d36f9b61520c2374ab463e77e8a62daa416398nd size compiled with the server. A server needs this value to be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive large enough to hold any one header field from a normal client
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request. The size of a normal request header field will vary
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd greatly among different client implementations, often depending
fb77c505254b6e9c925e23e734463e87574f8f40kess upon the extent to which a user has configured their browser to
fb77c505254b6e9c925e23e734463e87574f8f40kess support detailed content negotiation.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>This directive gives the server administrator greater
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd control over abnormal client request behavior, which may be
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd useful for avoiding some forms of denial-of-service attacks.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
55d36f9b61520c2374ab463e77e8a62daa416398nd LimitRequestFieldSize 4094
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
55d36f9b61520c2374ab463e77e8a62daa416398nd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note">Under normal conditions, the value should not be changed from
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default.</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
55d36f9b61520c2374ab463e77e8a62daa416398nd
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="directive-section"><h2><a name="LimitRequestLine" id="LimitRequestLine">LimitRequestLine</a> <a name="limitrequestline" id="limitrequestline">Directive</a></h2>
55d36f9b61520c2374ab463e77e8a62daa416398nd<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limit the size of the HTTP request line that will be accepted
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefrom the client</td></tr>
55d36f9b61520c2374ab463e77e8a62daa416398nd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitRequestLine <var>bytes</var></code></td></tr>
55d36f9b61520c2374ab463e77e8a62daa416398nd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitRequestLine 8190</code></td></tr>
55d36f9b61520c2374ab463e77e8a62daa416398nd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
55d36f9b61520c2374ab463e77e8a62daa416398nd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
55d36f9b61520c2374ab463e77e8a62daa416398nd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
bea526116133aa3d7dabd1924bfc580b37fbf22aslive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the number of <var>bytes</var> from 0 to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the value of the compile-time constant
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>DEFAULT_LIMIT_REQUEST_LINE</code> (8190 as distributed)
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that will be allowed on the HTTP request-line.</p>
bea526116133aa3d7dabd1924bfc580b37fbf22aslive
bea526116133aa3d7dabd1924bfc580b37fbf22aslive <p>The <code class="directive">LimitRequestLine</code> directive allows
bea526116133aa3d7dabd1924bfc580b37fbf22aslive the server administrator to reduce the limit on the allowed size
fb77c505254b6e9c925e23e734463e87574f8f40kess of a client's HTTP request-line below the normal input buffer size
bea526116133aa3d7dabd1924bfc580b37fbf22aslive compiled with the server. Since the request-line consists of the
bea526116133aa3d7dabd1924bfc580b37fbf22aslive HTTP method, URI, and protocol version, the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive">LimitRequestLine</code> directive places a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive restriction on the length of a request-URI allowed for a request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive on the server. A server needs this value to be large enough to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive hold any of its resource names, including any information that
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive might be passed in the query part of a <code>GET</code> request.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive gives the server administrator greater
3621f3acee323a877639a96d84891095eb07933aminfrin control over abnormal client request behavior, which may be
003f0c9fda6664daf5092a0e42f65ede20098153slive useful for avoiding some forms of denial-of-service attacks.</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>For example:</p>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive LimitRequestLine 4094
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note">Under normal conditions, the value should not be changed from
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default.</div>
5b258a8d58679c6587757189339bb3c2d0488f93poirier
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin</div>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<div class="directive-section"><h2><a name="LimitXMLRequestBody" id="LimitXMLRequestBody">LimitXMLRequestBody</a> <a name="limitxmlrequestbody" id="limitxmlrequestbody">Directive</a></h2>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<table class="directive">
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the size of an XML-based request body</td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LimitXMLRequestBody <var>bytes</var></code></td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LimitXMLRequestBody 1000000</code></td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
3621f3acee323a877639a96d84891095eb07933aminfrin<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
3621f3acee323a877639a96d84891095eb07933aminfrin</table>
3621f3acee323a877639a96d84891095eb07933aminfrin <p>Limit (in bytes) on maximum size of an XML-based request
3621f3acee323a877639a96d84891095eb07933aminfrin body. A value of <code>0</code> will disable any checking.</p>
3621f3acee323a877639a96d84891095eb07933aminfrin
3621f3acee323a877639a96d84891095eb07933aminfrin <p>Example:</p>
3621f3acee323a877639a96d84891095eb07933aminfrin
3621f3acee323a877639a96d84891095eb07933aminfrin <div class="example"><p><code>
3621f3acee323a877639a96d84891095eb07933aminfrin LimitXMLRequestBody 0
3621f3acee323a877639a96d84891095eb07933aminfrin </code></p></div>
3621f3acee323a877639a96d84891095eb07933aminfrin
3621f3acee323a877639a96d84891095eb07933aminfrin
3621f3acee323a877639a96d84891095eb07933aminfrin</div>
3621f3acee323a877639a96d84891095eb07933aminfrin<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
3621f3acee323a877639a96d84891095eb07933aminfrin<div class="directive-section"><h2><a name="Location" id="Location">&lt;Location&gt;</a> <a name="location" id="location">Directive</a></h2>
3621f3acee323a877639a96d84891095eb07933aminfrin<table class="directive">
3621f3acee323a877639a96d84891095eb07933aminfrin<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Applies the enclosed directives only to matching
3621f3acee323a877639a96d84891095eb07933aminfrinURLs</td></tr>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;Location
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin <var>URL-path</var>|<var>URL</var>&gt; ... &lt;/Location&gt;</code></td></tr>
3621f3acee323a877639a96d84891095eb07933aminfrin<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
03aa31ad82759363ba1a55589e517b16308ef635minfrin<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
c68acc9d712af079afa2bd1a5a4aeef9a3ea573ckess</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <code class="directive">&lt;Location&gt;</code> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive limits the scope of the enclosed directives by URL. It is similar to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd directive, and starts a subsection which is terminated with a
7b5535ed88e0f561b3bfb3330137bd804846afd4slive <code>&lt;/Location&gt;</code> directive. <code class="directive">&lt;Location&gt;</code> sections are processed in the
7b5535ed88e0f561b3bfb3330137bd804846afd4slive order they appear in the configuration file, after the <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections and
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <code>.htaccess</code> files are read, and after the <code class="directive"><a href="#files">&lt;Files&gt;</a></code> sections.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
7b5535ed88e0f561b3bfb3330137bd804846afd4slive <p><code class="directive">&lt;Location&gt;</code> sections operate
7b5535ed88e0f561b3bfb3330137bd804846afd4slive completely outside the filesystem. This has several consequences.
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd Most importantly, <code class="directive">&lt;Location&gt;</code>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd directives should not be used to control access to filesystem
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd locations. Since several different URLs may map to the same
7b5535ed88e0f561b3bfb3330137bd804846afd4slive filesystem location, such access controls may by circumvented.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin <div class="note"><h3>When to use <code class="directive">&lt;Location&gt;</code></h3>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin
3621f3acee323a877639a96d84891095eb07933aminfrin <p>Use <code class="directive">&lt;Location&gt;</code> to apply
3621f3acee323a877639a96d84891095eb07933aminfrin directives to content that lives outside the filesystem. For
3621f3acee323a877639a96d84891095eb07933aminfrin 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
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <code>&lt;Location /&gt;</code>, which is an easy way to
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin apply a configuration to the entire server.</p>
3621f3acee323a877639a96d84891095eb07933aminfrin </div>
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin <p>For all origin (non-proxy) requests, the URL to be matched is a
cf8a8738330694e60bad421fcc8361d80b0e9124minfrin URL-path of the form <code>/path/</code>. No scheme, hostname,
3621f3acee323a877639a96d84891095eb07933aminfrin port, or query string may be included. For proxy requests, the
3621f3acee323a877639a96d84891095eb07933aminfrin URL to be matched is of the form
03aa31ad82759363ba1a55589e517b16308ef635minfrin <code>scheme://servername/path</code>, and you must include the
3621f3acee323a877639a96d84891095eb07933aminfrin prefix.</p>
3621f3acee323a877639a96d84891095eb07933aminfrin
3621f3acee323a877639a96d84891095eb07933aminfrin <p>The URL may use wildcards. In a wild-card string, <code>?</code> matches
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor any single character, and <code>*</code> matches any sequences of
3621f3acee323a877639a96d84891095eb07933aminfrin characters.</p>
3621f3acee323a877639a96d84891095eb07933aminfrin
03aa31ad82759363ba1a55589e517b16308ef635minfrin <p>Extended regular
3621f3acee323a877639a96d84891095eb07933aminfrin expressions can also be used, with the addition of the
3621f3acee323a877639a96d84891095eb07933aminfrin <code>~</code> character. For example:</p>
3621f3acee323a877639a96d84891095eb07933aminfrin
03aa31ad82759363ba1a55589e517b16308ef635minfrin <div class="example"><p><code>
03aa31ad82759363ba1a55589e517b16308ef635minfrin &lt;Location ~ "/(extra|special)/data"&gt;
03aa31ad82759363ba1a55589e517b16308ef635minfrin </code></p></div>
03aa31ad82759363ba1a55589e517b16308ef635minfrin
03aa31ad82759363ba1a55589e517b16308ef635minfrin <p>would match URLs that contained the substring <code>/extra/data</code>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor or <code>/special/data</code>. The directive <code class="directive"><a href="#locationmatch">&lt;LocationMatch&gt;</a></code> behaves
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive identical to the regex version of <code class="directive">&lt;Location&gt;</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>The <code class="directive">&lt;Location&gt;</code>
fb77c505254b6e9c925e23e734463e87574f8f40kess functionality is especially useful when combined with the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#sethandler">SetHandler</a></code>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele directive. For example, to enable status requests, but allow them
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele only from browsers at <code>foo.com</code>, you might use:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Location /status&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive SetHandler server-status<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Order Deny,Allow<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Deny from all<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess Allow from .foo.com<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </span>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/Location&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note"><h3>Note about / (slash)</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The slash character has special meaning depending on where in a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive URL it appears. People may be used to its behavior in the filesystem
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive where multiple adjacent slashes are frequently collapsed to a single
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive slash (<em>i.e.</em>, <code>/home///foo</code> is the same as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/home/foo</code>). In URL-space this is not necessarily true.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The <code class="directive"><a href="#locationmatch">&lt;LocationMatch&gt;</a></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive and the regex version of <code class="directive">&lt;Location&gt;</code> require you to explicitly specify multiple
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive slashes if that is your intention.</p>
891df99fdfa41fc8a486568f4d31ddf4a571258adreid
891df99fdfa41fc8a486568f4d31ddf4a571258adreid <p>For example, <code>&lt;LocationMatch ^/abc&gt;</code> would match
59368b594c9b09b59ae58c7de26d2d5ce1c99a29takashi the request URL <code>/abc</code> but not the request URL <code>
be192cefa381d5bae6868034687471754cb43175sf //abc</code>. The (non-regex) <code class="directive">&lt;Location&gt;</code> directive behaves similarly when used for
891df99fdfa41fc8a486568f4d31ddf4a571258adreid proxy requests. But when (non-regex) <code class="directive">&lt;Location&gt;</code> is used for non-proxy requests it will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive implicitly match multiple slashes with a single slash. For example,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive if you specify <code>&lt;Location /abc/def&gt;</code> and the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request is to <code>/abc//def</code> then it will match.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<h3>See also</h3>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<ul>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt;
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick and &lt;Files&gt; sections work</a> for an explanation of how these
9f38f3ec3e8087985d108a24ae796962fef83644takashi different sections are combined when a request is received</li>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick</ul>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick</div>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<div class="directive-section"><h2><a name="LocationMatch" id="LocationMatch">&lt;LocationMatch&gt;</a> <a name="locationmatch" id="locationmatch">Directive</a></h2>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<table class="directive">
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Applies the enclosed directives only to regular-expression
98f5034c8cbf2ef025b317b3e01acae82e143b11trawickmatching URLs</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;LocationMatch
9f38f3ec3e8087985d108a24ae796962fef83644takashi <var>regex</var>&gt; ... &lt;/LocationMatch&gt;</code></td></tr>
9f38f3ec3e8087985d108a24ae796962fef83644takashi<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick</table>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick <p>The <code class="directive">&lt;LocationMatch&gt;</code> directive
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick limits the scope of the enclosed directives by URL, in an identical manner
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick to <code class="directive"><a href="#location">&lt;Location&gt;</a></code>. However,
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick it takes a regular expression as an argument instead of a simple
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor string. For example:</p>
85349f40d98fb3fc7a18ef25dc40eaaae6eead1ctakashi
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener <div class="example"><p><code>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick &lt;LocationMatch "/(extra|special)/data"&gt;
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick </code></p></div>
98f5034c8cbf2ef025b317b3e01acae82e143b11trawick
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>would match URLs that contained the substring <code>/extra/data</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or <code>/special/data</code>.</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<h3>See also</h3>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt;
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd and &lt;Files&gt; sections work</a> for an explanation of how these
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive different sections are combined when a request is received</li>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="LogLevel" id="LogLevel">LogLevel</a> <a name="loglevel" id="loglevel">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Controls the verbosity of the ErrorLog</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>LogLevel <var>level</var></code></td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>LogLevel warn</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p><code class="directive">LogLevel</code> adjusts the verbosity of the
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess messages recorded in the error logs (see <code class="directive"><a href="#errorlog">ErrorLog</a></code> directive). The following
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <var>level</var>s are available, in order of decreasing
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess significance:</p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <table class="bordered">
130d299c4b2b15be45532a176604c71fdc7bea5bnd <tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd <th><strong>Level</strong> </th>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <th><strong>Description</strong> </th>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <th><strong>Example</strong> </th>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <td><code>emerg</code> </td>
6c5c651b0b97607b8c8b4965c1385c67699f217fnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <td>Emergencies - system is unusable.</td>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <td>"Child cannot open lock file. Exiting"</td>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </tr>
6c5c651b0b97607b8c8b4965c1385c67699f217fnd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <tr>
750d12c59545dbbac70390988de94f7e901b08f2niq <td><code>alert</code> </td>
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive <td>Action must be taken immediately.</td>
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>"getpwuid: couldn't determine user name from uid"</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd </tr>
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive <tr>
4bb78e7cdd53f50240cff4ad7a97c7ed36483797slive <td><code>crit</code> </td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>Critical Conditions.</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>"socket: Failed to get a socket, exiting child"</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd </tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td><code>error</code> </td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>Error conditions.</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>"Premature end of script headers"</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd </tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td><code>warn</code> </td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>Warning conditions.</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>"child process 1234 did not exit, sending another
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd SIGHUP"</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd </tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <tr>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <td><code>notice</code> </td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>Normal but significant condition.</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <td>"httpd: caught SIGBUS, attempting to dump core in
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor ..."</td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd </tr>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td><code>info</code> </td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>Informational.</td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"Server seems busy, (you may need to increase
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess StartServers, or Min/MaxSpareServers)..."</td>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd <tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td><code>debug</code> </td>
7245e9b991db85d9d9a587fe5f4051f642ebdc3cchrisd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>Debug-level messages</td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"Opening config file ..."</td>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen </tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen </table>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>When a particular level is specified, messages from all
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive other levels of higher significance will be reported as well.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>E.g.</em>, when <code>LogLevel info</code> is specified,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive then messages with log levels of <code>notice</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>warn</code> will also be posted.</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>Using a level of at least <code>crit</code> is
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen recommended.</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>For example:</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <div class="example"><p><code>
130d299c4b2b15be45532a176604c71fdc7bea5bnd LogLevel notice
7ef9b6763ad87846cf83c3f71467f43e349d080aerikabele </code></p></div>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <div class="note"><h3>Note</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When logging to a regular file messages of the level
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>notice</code> cannot be suppressed and thus are always
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive logged. However, this doesn't apply when logging is done
03e0a375c2435102fb2b51e34cccff52acbfddcdnd using <code>syslog</code>.</p>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd </div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd
03e0a375c2435102fb2b51e34cccff52acbfddcdnd</div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<div class="directive-section"><h2><a name="MaxKeepAliveRequests" id="MaxKeepAliveRequests">MaxKeepAliveRequests</a> <a name="maxkeepaliverequests" id="maxkeepaliverequests">Directive</a></h2>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<table class="directive">
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Number of requests allowed on a persistent
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowenconnection</td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxKeepAliveRequests <var>number</var></code></td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>MaxKeepAliveRequests 100</code></td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd</table>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd <p>The <code class="directive">MaxKeepAliveRequests</code> directive
03e0a375c2435102fb2b51e34cccff52acbfddcdnd limits the number of requests allowed per connection when
03e0a375c2435102fb2b51e34cccff52acbfddcdnd <code class="directive"><a href="#keepalive">KeepAlive</a></code> is on. If it is
03e0a375c2435102fb2b51e34cccff52acbfddcdnd set to <code>0</code>, unlimited requests will be allowed. We
03e0a375c2435102fb2b51e34cccff52acbfddcdnd recommend that this setting be kept to a high value for maximum
03e0a375c2435102fb2b51e34cccff52acbfddcdnd server performance.</p>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd
03e0a375c2435102fb2b51e34cccff52acbfddcdnd <p>For example:</p>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd
03e0a375c2435102fb2b51e34cccff52acbfddcdnd <div class="example"><p><code>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd MaxKeepAliveRequests 500
03e0a375c2435102fb2b51e34cccff52acbfddcdnd </code></p></div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd
03e0a375c2435102fb2b51e34cccff52acbfddcdnd</div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<div class="directive-section"><h2><a name="NameVirtualHost" id="NameVirtualHost">NameVirtualHost</a> <a name="namevirtualhost" id="namevirtualhost">Directive</a></h2>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<table class="directive">
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Designates an IP address for name-virtual
03e0a375c2435102fb2b51e34cccff52acbfddcdndhosting</td></tr>
03e0a375c2435102fb2b51e34cccff52acbfddcdnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>NameVirtualHost <var>addr</var>[:<var>port</var>]</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>The <code class="directive">NameVirtualHost</code> directive is a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive required directive if you want to configure <a href="/vhosts/">name-based virtual hosts</a>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Although <var>addr</var> can be hostname it is recommended
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that you always use an IP address, e.g.</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive NameVirtualHost 111.22.33.44
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
6fad623c3cc52b4a84d4d36538f6eed886f49f98covener <p>With the <code class="directive">NameVirtualHost</code> directive you
6fad623c3cc52b4a84d4d36538f6eed886f49f98covener specify the IP address on which the server will receive requests
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for the name-based virtual hosts. This will usually be the address
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to which your name-based virtual host names resolve. In cases
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive where a firewall or other proxy receives the requests and forwards
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive them on a different IP address to the server, you must specify the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive IP address of the physical interface on the machine which will be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive servicing the requests. If you have multiple name-based hosts on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive multiple addresses, repeat the directive for each address.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note"><h3>Note</h3>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>Note, that the "main server" and any <code>_default_</code> servers
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess will <strong>never</strong> be served for a request to a
fb77c505254b6e9c925e23e734463e87574f8f40kess <code class="directive">NameVirtualHost</code> IP Address (unless for some
fb77c505254b6e9c925e23e734463e87574f8f40kess reason you specify <code class="directive">NameVirtualHost</code> but then
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive don't define any <code class="directive">VirtualHost</code>s for that
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive address).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Optionally you can specify a port number on which the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen name-based virtual hosts should be used, e.g.</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <div class="example"><p><code>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen NameVirtualHost 111.22.33.44:8080
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen </code></p></div>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>IPv6 addresses must be enclosed in square brackets, as shown
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen in the following example:</p>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <div class="example"><p><code>
6fad623c3cc52b4a84d4d36538f6eed886f49f98covener NameVirtualHost [fe80::a00:20ff:fea7:ccea]:8080
6fad623c3cc52b4a84d4d36538f6eed886f49f98covener </code></p></div>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>To receive requests on all interfaces, you can use an argument of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>*</code></p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive NameVirtualHost *
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="note"><h3>Argument to <code class="directive">&lt;VirtualHost&gt;</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive</h3>
e0ef044feba0082771091af42798cada5bb1f4fcrbowen <p>Note that the argument to the <code class="directive">&lt;VirtualHost&gt;</code> directive must
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive exactly match the argument to the <code class="directive">NameVirtualHost</code> directive.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive NameVirtualHost 1.2.3.4<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;VirtualHost 1.2.3.4&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive # ...<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/VirtualHost&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/vhosts/">Virtual Hosts
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivedocumentation</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="Options" id="Options">Options</a> <a name="options" id="options">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures what features are available in a particular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivedirectory</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Options
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive [+|-]<var>option</var> [[+|-]<var>option</var>] ...</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Options All</code></td></tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Options</td></tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</table>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>The <code class="directive">Options</code> directive controls which
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen server features are available in a particular directory.</p>
2f505ba07f89ba6a175d6ceae67fb273c4eb0993covener
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <p><var>option</var> can be set to <code>None</code>, in which
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener case none of the extra features are enabled, or one or more of
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener the following:</p>
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener <dl>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>All</code></dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>All options except for <code>MultiViews</code>. This is the default
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive setting.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>ExecCGI</code></dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
ae134ecc8faf4e6a8eb68e1c3724506771442a46rbowen <dd>
ae134ecc8faf4e6a8eb68e1c3724506771442a46rbowen Execution of CGI scripts using <code class="module"><a href="/mod/mod_cgi.html">mod_cgi</a></code>
e0ef044feba0082771091af42798cada5bb1f4fcrbowen is permitted.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>FollowSymLinks</code></dt>
72580dbc2a55511f13f377063725b9f143b20826stoddard
72580dbc2a55511f13f377063725b9f143b20826stoddard <dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess The server will follow symbolic links in this directory.
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <div class="note">
72580dbc2a55511f13f377063725b9f143b20826stoddard <p>Even though the server follows the symlink it does <em>not</em>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor change the pathname used to match against <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> sections.</p>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <p>Note also, that this option <strong>gets ignored</strong> if set
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor inside a <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
72580dbc2a55511f13f377063725b9f143b20826stoddard section.</p>
56d7eed7205462540aec7202cd82d9f5516fc537kess </div></dd>
72580dbc2a55511f13f377063725b9f143b20826stoddard
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>Includes</code></dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Server-side includes provided by <code class="module"><a href="/mod/mod_include.html">mod_include</a></code>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen are permitted.</dd>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <dt><code>IncludesNOEXEC</code></dt>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
ef8e89e090461194ecadd31e8796a2c51e0531a2kess <dd>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Server-side includes are permitted, but the <code>#exec
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen cmd</code> and <code>#exec cgi</code> are disabled. It is still
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen possible to <code>#include virtual</code> CGI scripts from
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <code class="directive"><a href="/mod/mod_alias.html#scriptalias">ScriptAlias</a></code>ed
2f505ba07f89ba6a175d6ceae67fb273c4eb0993covener directories.</dd>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener <dt><code>Indexes</code></dt>
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener <dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive If a URL which maps to a directory is requested, and there
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive is no <code class="directive"><a href="/mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (<em>e.g.</em>, <code>index.html</code>) in that directory, then
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="module"><a href="/mod/mod_autoindex.html">mod_autoindex</a></code> will return a formatted listing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive of the directory.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>MultiViews</code></dt>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>
e0ef044feba0082771091af42798cada5bb1f4fcrbowen <a href="/content-negotiation.html">Content negotiated</a>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive "MultiViews" are allowed using
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="module"><a href="/mod/mod_negotiation.html">mod_negotiation</a></code>.</dd>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
72580dbc2a55511f13f377063725b9f143b20826stoddard <dt><code>SymLinksIfOwnerMatch</code></dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>The server will only follow symbolic links for which the
72580dbc2a55511f13f377063725b9f143b20826stoddard target file or directory is owned by the same user id as the
72580dbc2a55511f13f377063725b9f143b20826stoddard link.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note"><h3>Note</h3> This option gets ignored if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive set inside a <code class="directive"><a href="#location">&lt;Location&gt;</a></code> section.</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </dl>
fb77c505254b6e9c925e23e734463e87574f8f40kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Normally, if multiple <code class="directive">Options</code> could
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive apply to a directory, then the most specific one is used and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive others are ignored; the options are not merged. (See <a href="/sections.html#mergin">how sections are merged</a>.)
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen However if <em>all</em> the options on the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <code class="directive">Options</code> directive are preceded by a
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <code>+</code> or <code>-</code> symbol, the options are
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen merged. Any options preceded by a <code>+</code> are added to the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen options currently in force, and any options preceded by a
ef8e89e090461194ecadd31e8796a2c51e0531a2kess <code>-</code> are removed from the options currently in
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen force. </p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>For example, without any <code>+</code> and <code>-</code> symbols:</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener <div class="example"><p><code>
2f505ba07f89ba6a175d6ceae67fb273c4eb0993covener &lt;Directory /web/docs&gt;<br />
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <span class="indent">
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener Options Indexes FollowSymLinks<br />
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener </span>
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener &lt;/Directory&gt;<br />
611f7fd8a0a5ee4a29eeed79dfd8bf6faaa3c613covener <br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /web/docs/spec&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Options Includes<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </span>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/Directory&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>then only <code>Includes</code> will be set for the
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele <code>/web/docs/spec</code> directory. However if the second
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele <code class="directive">Options</code> directive uses the <code>+</code> and
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele <code>-</code> symbols:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;Directory /web/docs&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Options Indexes FollowSymLinks<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen </span>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen &lt;/Directory&gt;<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <br />
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd &lt;Directory /web/docs/spec&gt;<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <span class="indent">
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Options +Includes -Indexes<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </span>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/Directory&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>then the options <code>FollowSymLinks</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Includes</code> are set for the <code>/web/docs/spec</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
fb77c505254b6e9c925e23e734463e87574f8f40kess <div class="note"><h3>Note</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Using <code>-IncludesNOEXEC</code> or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>-Includes</code> disables server-side includes completely
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive regardless of the previous setting.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <p>The default in the absence of any other settings is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>All</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
7852e17fb37b2a02ccdcab107f2c7f5fd41fd201nd</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="Require" id="Require">Require</a> <a name="require" id="require">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Selects which authenticated users can access
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivea resource</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Require <var>entity-name</var> [<var>entity-name</var>] ...</code></td></tr>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig</td></tr>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive</table>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive <p>This directive selects which authenticated users can access
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive a directory. The allowed syntaxes are:</p>
d950cf9262224a223e2ff5c51393708071e14b94covener
d950cf9262224a223e2ff5c51393708071e14b94covener <dl>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic <dt><code>Require user <var>userid</var> [<var>userid</var>]
d950cf9262224a223e2ff5c51393708071e14b94covener ...</code></dt>
d950cf9262224a223e2ff5c51393708071e14b94covener <dd>Only the named users can access the resource.</dd>
d950cf9262224a223e2ff5c51393708071e14b94covener
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <dt><code>Require group <var>group-name</var> [<var>group-name</var>]
d950cf9262224a223e2ff5c51393708071e14b94covener ...</code></dt>
d950cf9262224a223e2ff5c51393708071e14b94covener <dd>Only users in the named groups can access the resource.</dd>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor
d950cf9262224a223e2ff5c51393708071e14b94covener <dt><code>Require valid-user</code></dt>
d950cf9262224a223e2ff5c51393708071e14b94covener <dd>All valid users can access the resource.</dd>
d950cf9262224a223e2ff5c51393708071e14b94covener </dl>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <p><code class="directive">Require</code> must be accompanied by
d950cf9262224a223e2ff5c51393708071e14b94covener <code class="directive"><a href="#authname">AuthName</a></code> and <code class="directive"><a href="#authtype">AuthType</a></code> directives, and directives such
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor as <code class="directive"><a href="/mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code>
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic and <code class="directive"><a href="/mod/mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></code> (to
d950cf9262224a223e2ff5c51393708071e14b94covener define users and groups) in order to work correctly. Example:</p>
d950cf9262224a223e2ff5c51393708071e14b94covener
d950cf9262224a223e2ff5c51393708071e14b94covener <div class="example"><p><code>
d950cf9262224a223e2ff5c51393708071e14b94covener AuthType Basic<br />
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic AuthName "Restricted Directory"<br />
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor AuthUserFile /web/users<br />
d950cf9262224a223e2ff5c51393708071e14b94covener AuthGroupFile /web/groups<br />
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor Require group admin
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic </code></p></div>
d950cf9262224a223e2ff5c51393708071e14b94covener
d950cf9262224a223e2ff5c51393708071e14b94covener <p>Access controls which are applied in this way are effective for
d950cf9262224a223e2ff5c51393708071e14b94covener <strong>all</strong> methods. <strong>This is what is normally
d950cf9262224a223e2ff5c51393708071e14b94covener desired.</strong> If you wish to apply access controls only to
d950cf9262224a223e2ff5c51393708071e14b94covener specific methods, while leaving other methods unprotected, then
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor place the <code class="directive">Require</code> statement into a
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive <code class="directive"><a href="#limit">&lt;Limit&gt;</a></code>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive section.</p>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<h3>See also</h3>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<ul>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<li><code class="directive"><a href="#satisfy">Satisfy</a></code></li>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<li><code class="module"><a href="/mod/mod_authz_host.html">mod_authz_host</a></code></li>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor</ul>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive</div>
234c8b28171d7e12b3c1f85b60fabd7c908a9c37slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="RLimitCPU" id="RLimitCPU">RLimitCPU</a> <a name="rlimitcpu" id="rlimitcpu">Directive</a></h2>
dc223428958ad9ff05011545bcdda000887b93e5slive<table class="directive">
beb923bec9bff2b49ce5027df2fe944e2b74e28brederpj<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the CPU consumption of processes launched
beb923bec9bff2b49ce5027df2fe944e2b74e28brederpjby Apache children</td></tr>
dc223428958ad9ff05011545bcdda000887b93e5slive<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>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
fb77c505254b6e9c925e23e734463e87574f8f40kess<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
d8c44cd75cf575fe51319280c12445109e878523noodl</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Takes 1 or 2 parameters. The first parameter sets the soft
030108b1816bcda3d925df65357feabdce83bc94slive resource limit for all processes and the second parameter sets
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor the maximum resource limit. Either parameter can be a number,
37742b630743e470b94618ecb3560fbd82e50b59rbowen or <code>max</code> to indicate to the server that the limit should
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd be set to the maximum allowed by the operating system
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd configuration. Raising the maximum resource limit requires that
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd the server is running as <code>root</code>, or in the initial startup
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd phase.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
fb77c505254b6e9c925e23e734463e87574f8f40kess <p>This applies to processes forked off from Apache children
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess servicing requests, not the Apache children themselves. This
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess includes CGI scripts and SSI exec commands, but not any
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess processes forked off from the Apache parent such as piped
37742b630743e470b94618ecb3560fbd82e50b59rbowen logs.</p>
37742b630743e470b94618ecb3560fbd82e50b59rbowen
37742b630743e470b94618ecb3560fbd82e50b59rbowen <p>CPU resource limits are expressed in seconds per
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive process.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#rlimitmem">RLimitMEM</a></code></li>
e8811b6d38f756b325446ded5d96857d13856511takashi<li><code class="directive"><a href="#rlimitnproc">RLimitNPROC</a></code></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</ul>
130d299c4b2b15be45532a176604c71fdc7bea5bnd</div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<div class="directive-section"><h2><a name="RLimitMEM" id="RLimitMEM">RLimitMEM</a> <a name="rlimitmem" id="rlimitmem">Directive</a></h2>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<table class="directive">
ca908c21f63a71c5efa7d32bd2cfafe9a42ba1fbrbowen<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the memory consumption of processes launched
130d299c4b2b15be45532a176604c71fdc7bea5bndby Apache children</td></tr>
130d299c4b2b15be45532a176604c71fdc7bea5bnd<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>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</table>
05201775eaa6b363b8a119c8aea5db246b967591yoshiki <p>Takes 1 or 2 parameters. The first parameter sets the soft
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd resource limit for all processes and the second parameter sets
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd the maximum resource limit. Either parameter can be a number,
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd or <code>max</code> to indicate to the server that the limit should
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd be set to the maximum allowed by the operating system
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd configuration. Raising the maximum resource limit requires that
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess the server is running as <code>root</code>, or in the initial startup
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd phase.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>This applies to processes forked off from Apache children
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd servicing requests, not the Apache children themselves. This
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd includes CGI scripts and SSI exec commands, but not any
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd processes forked off from the Apache parent such as piped
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd logs.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>Memory resource limits are expressed in bytes per
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd process.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<h3>See also</h3>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<ul>
37742b630743e470b94618ecb3560fbd82e50b59rbowen<li><code class="directive"><a href="#rlimitcpu">RLimitCPU</a></code></li>
37742b630743e470b94618ecb3560fbd82e50b59rbowen<li><code class="directive"><a href="#rlimitnproc">RLimitNPROC</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="RLimitNPROC" id="RLimitNPROC">RLimitNPROC</a> <a name="rlimitnproc" id="rlimitnproc">Directive</a></h2>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limits the number of processes that can be launched by
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveprocesses launched by Apache children</td></tr>
8490b2f9f6469d5089163f6dd303d9a81f8e908ctrawick<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>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Unset; uses operating system defaults</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess</table>
6b64034fa2a644ba291c484c0c01c7df5b8d982ckess <p>Takes 1 or 2 parameters. The first parameter sets the soft
030108b1816bcda3d925df65357feabdce83bc94slive resource limit for all processes and the second parameter sets
030108b1816bcda3d925df65357feabdce83bc94slive the maximum resource limit. Either parameter can be a number,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or <code>max</code> to indicate to the server that the limit
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd should be set to the maximum allowed by the operating system
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd configuration. Raising the maximum resource limit requires that
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd the server is running as <code>root</code>, or in the initial startup
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd phase.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>This applies to processes forked off from Apache children
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive servicing requests, not the Apache children themselves. This
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive includes CGI scripts and SSI exec commands, but not any
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess processes forked off from the Apache parent such as piped
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess logs.</p>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Process limits control the number of processes per user.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="note"><h3>Note</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If CGI processes are <strong>not</strong> running
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive under userids other than the web server userid, this directive
7fbd7281d06cec1918aa370214df77c572f871a9sf will limit the number of processes that the server itself can
7fbd7281d06cec1918aa370214df77c572f871a9sf create. Evidence of this situation will be indicated by
7fbd7281d06cec1918aa370214df77c572f871a9sf <strong><code>cannot fork</code></strong> messages in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>error_log</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
7fbd7281d06cec1918aa370214df77c572f871a9sf
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
7fbd7281d06cec1918aa370214df77c572f871a9sf<ul>
7fbd7281d06cec1918aa370214df77c572f871a9sf<li><code class="directive"><a href="#rlimitmem">RLimitMEM</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#rlimitcpu">RLimitCPU</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="Satisfy" id="Satisfy">Satisfy</a> <a name="satisfy" id="satisfy">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Interaction between host-level access control and
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveuser authentication</td></tr>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Satisfy Any|All</code></td></tr>
1597043cec6ad37fa4154bf09b0fccdabed1a239slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Satisfy All</code></td></tr>
1597043cec6ad37fa4154bf09b0fccdabed1a239slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>AuthConfig</td></tr>
530eba85dbd41b8a0fa5255d3648d1440199a661slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
530eba85dbd41b8a0fa5255d3648d1440199a661slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Access policy if both <code class="directive"><a href="/mod/mod_authz_host.html#allow">Allow</a></code> and <code class="directive"><a href="#require">Require</a></code> used. The parameter can be
530eba85dbd41b8a0fa5255d3648d1440199a661slive either <code>All</code> or <code>Any</code>. This directive is only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive useful if access to a particular area is being restricted by both
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive username/password <em>and</em> client host address. In this case
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default behavior (<code>All</code>) is to require that the client
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive passes the address access restriction <em>and</em> enters a valid
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive username and password. With the <code>Any</code> option the client will be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive granted access if they either pass the host restriction or enter a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive valid username and password. This can be used to password restrict
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive an area, but to let clients from particular addresses in without
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive prompting for a password.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For example, if you wanted to let people on your network have
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive unrestricted access to a portion of your website, but require that
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive people outside of your network provide a password, you could use a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive configuration similar to the following:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require valid-user<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow from 192.168.1<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Satisfy Any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="/mod/mod_authz_host.html#allow">Allow</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#require">Require</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="ScriptInterpreterSource" id="ScriptInterpreterSource">ScriptInterpreterSource</a> <a name="scriptinterpretersource" id="scriptinterpretersource">Directive</a></h2>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<table class="directive">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Technique for locating the interpreter for CGI
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivescripts</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ScriptInterpreterSource Registry|Registry-Strict|Script</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ScriptInterpreterSource Script</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Win32 only;
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveoption <code>Registry-Strict</code> is available in Apache 2.0 and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivelater</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive is used to control how Apache finds the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive interpreter used to run CGI scripts. The default setting is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Script</code>. This causes Apache to use the interpreter pointed to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive by the shebang line (first line, starting with <code>#!</code>) in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive script. On Win32 systems this line usually looks like:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive #!C:/Perl/bin/perl.exe
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>or, if perl is in the <code>PATH</code>, simply:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive #!perl
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Setting <code>ScriptInterpreterSource Registry</code> will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive cause the Windows Registry tree <code>HKEY_CLASSES_ROOT</code> to be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive searched using the script file extension (e.g., <code>.pl</code>) as a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive search key. The command defined by the registry subkey
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Shell\ExecCGI\Command</code> or, if it does not exist, by the subkey
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Shell\Open\Command</code> is used to open the script file. If the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive registry keys cannot be found, Apache falls back to the behavior of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Script</code> option.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
7fbd7281d06cec1918aa370214df77c572f871a9sf <div class="warning"><h3>Security</h3>
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>Be careful when using <code>ScriptInterpreterSource
7fbd7281d06cec1918aa370214df77c572f871a9sf Registry</code> with <code class="directive"><a href="/mod/mod_alias.html#scriptalias">ScriptAlias</a></code>'ed directories, because
7fbd7281d06cec1918aa370214df77c572f871a9sf Apache will try to execute <strong>every</strong> file within this
7fbd7281d06cec1918aa370214df77c572f871a9sf directory. The <code>Registry</code> setting may cause undesired
7fbd7281d06cec1918aa370214df77c572f871a9sf program calls on files which are typically not executed. For
7fbd7281d06cec1918aa370214df77c572f871a9sf example, the default open command on <code>.htm</code> files on
7fbd7281d06cec1918aa370214df77c572f871a9sf most Windows systems will execute Microsoft Internet Explorer, so
7fbd7281d06cec1918aa370214df77c572f871a9sf any HTTP request for an <code>.htm</code> file existing within the
7fbd7281d06cec1918aa370214df77c572f871a9sf script directory would start the browser in the background on the
7fbd7281d06cec1918aa370214df77c572f871a9sf server. This is a good way to crash your system within a minute or
7fbd7281d06cec1918aa370214df77c572f871a9sf so.</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf </div>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>The option <code>Registry-Strict</code> which is new in Apache
7fbd7281d06cec1918aa370214df77c572f871a9sf 2.0 does the same thing as <code>Registry</code> but uses only the
7fbd7281d06cec1918aa370214df77c572f871a9sf subkey <code>Shell\ExecCGI\Command</code>. The
7fbd7281d06cec1918aa370214df77c572f871a9sf <code>ExecCGI</code> key is not a common one. It must be
7fbd7281d06cec1918aa370214df77c572f871a9sf configured manually in the windows registry and hence prevents
7fbd7281d06cec1918aa370214df77c572f871a9sf accidental program calls on your system.</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf</div>
7fbd7281d06cec1918aa370214df77c572f871a9sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
7fbd7281d06cec1918aa370214df77c572f871a9sf<div class="directive-section"><h2><a name="ServerAdmin" id="ServerAdmin">ServerAdmin</a> <a name="serveradmin" id="serveradmin">Directive</a></h2>
7fbd7281d06cec1918aa370214df77c572f871a9sf<table class="directive">
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Email address that the server includes in error
7fbd7281d06cec1918aa370214df77c572f871a9sfmessages sent to the client</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerAdmin <var>email-address</var></code></td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf</table>
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>The <code class="directive">ServerAdmin</code> sets the e-mail address
7fbd7281d06cec1918aa370214df77c572f871a9sf that the server includes in any error messages it returns to the
7fbd7281d06cec1918aa370214df77c572f871a9sf client.</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>It may be worth setting up a dedicated address for this, e.g.</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <div class="example"><p><code>
7fbd7281d06cec1918aa370214df77c572f871a9sf ServerAdmin www-admin@foo.example.com
7fbd7281d06cec1918aa370214df77c572f871a9sf </code></p></div>
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>as users do not always mention that they are talking about the
7fbd7281d06cec1918aa370214df77c572f871a9sf server!</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf</div>
7fbd7281d06cec1918aa370214df77c572f871a9sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
7fbd7281d06cec1918aa370214df77c572f871a9sf<div class="directive-section"><h2><a name="ServerAlias" id="ServerAlias">ServerAlias</a> <a name="serveralias" id="serveralias">Directive</a></h2>
7fbd7281d06cec1918aa370214df77c572f871a9sf<table class="directive">
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Alternate names for a host used when matching requests
7fbd7281d06cec1918aa370214df77c572f871a9sfto name-virtual hosts</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerAlias <var>hostname</var> [<var>hostname</var>] ...</code></td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>virtual host</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf</table>
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>The <code class="directive">ServerAlias</code> directive sets the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive alternate names for a host, for use with <a href="/vhosts/name-based.html">name-based virtual hosts</a>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="example"><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;VirtualHost *&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ServerName server.domain.com<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ServerAlias server server2.domain.com server2<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive # ...<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;/VirtualHost&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </code></p></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<h3>See also</h3>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<ul>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<li><a href="/vhosts/">Apache Virtual Host documentation</a></li>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</ul>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd</div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
8b052d682204371decc64f942aede5ef1da98955erikabele<div class="directive-section"><h2><a name="ServerName" id="ServerName">ServerName</a> <a name="servername" id="servername">Directive</a></h2>
8b052d682204371decc64f942aede5ef1da98955erikabele<table class="directive">
8b052d682204371decc64f942aede5ef1da98955erikabele<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Hostname and port that the server uses to identify
8b052d682204371decc64f942aede5ef1da98955erikabeleitself</td></tr>
8b052d682204371decc64f942aede5ef1da98955erikabele<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerName <var>fully-qualified-domain-name</var>[:<var>port</var>]</code></td></tr>
8b052d682204371decc64f942aede5ef1da98955erikabele<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
8b052d682204371decc64f942aede5ef1da98955erikabele<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>In version 2.0, this
7fbd7281d06cec1918aa370214df77c572f871a9sf directive supersedes the functionality of the <code class="directive">Port</code>
7fbd7281d06cec1918aa370214df77c572f871a9sf directive from version 1.3.</td></tr>
7fbd7281d06cec1918aa370214df77c572f871a9sf</table>
fd410ae1fa431e734e6d0cd3c006002d4904466apoirier <p>The <code class="directive">ServerName</code> directive sets the hostname and
7fbd7281d06cec1918aa370214df77c572f871a9sf port that the server uses to identify itself. This is used when
7fbd7281d06cec1918aa370214df77c572f871a9sf creating redirection URLs. For example, if the name of the
7fbd7281d06cec1918aa370214df77c572f871a9sf machine hosting the webserver is <code>simple.example.com</code>,
7fbd7281d06cec1918aa370214df77c572f871a9sf but the machine also has the DNS alias <code>www.example.com</code>
7fbd7281d06cec1918aa370214df77c572f871a9sf and you wish the webserver to be so identified, the following
7fbd7281d06cec1918aa370214df77c572f871a9sf directive should be used:</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <div class="example"><p><code>
7fbd7281d06cec1918aa370214df77c572f871a9sf ServerName www.example.com:80
7fbd7281d06cec1918aa370214df77c572f871a9sf </code></p></div>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>If no <code class="directive">ServerName</code> is specified, then the
7fbd7281d06cec1918aa370214df77c572f871a9sf server attempts to deduce the hostname by performing a reverse
7fbd7281d06cec1918aa370214df77c572f871a9sf lookup on the IP address. If no port is specified in the
7fbd7281d06cec1918aa370214df77c572f871a9sf servername, then the server will use the port from the incoming
7fbd7281d06cec1918aa370214df77c572f871a9sf request. For optimal reliability and predictability, you should
7fbd7281d06cec1918aa370214df77c572f871a9sf specify an explicit hostname and port using the
7fbd7281d06cec1918aa370214df77c572f871a9sf <code class="directive">ServerName</code> directive.</p>
7fbd7281d06cec1918aa370214df77c572f871a9sf
7fbd7281d06cec1918aa370214df77c572f871a9sf <p>If you are using <a href="/vhosts/name-based.html">name-based virtual hosts</a>,
7fbd7281d06cec1918aa370214df77c572f871a9sf the <code class="directive">ServerName</code> inside a
7fbd7281d06cec1918aa370214df77c572f871a9sf <code class="directive"><a href="#virtualhost">&lt;VirtualHost&gt;</a></code>
7fbd7281d06cec1918aa370214df77c572f871a9sf section specifies what hostname must appear in the request's
7fbd7281d06cec1918aa370214df77c572f871a9sf <code>Host:</code> header to match this virtual host.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>See the description of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code> directive for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive settings which determine whether self-referential URL's (e.g., by the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="module"><a href="/mod/mod_dir.html">mod_dir</a></code> module) will refer to the
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess specified port, or to the port number given in the client's request.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<ul>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<li><a href="/dns-caveats.html">Issues Regarding DNS and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Apache</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/vhosts/">Apache virtual host
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive documentation</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#usecanonicalname">UseCanonicalName</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><code class="directive"><a href="#namevirtualhost">NameVirtualHost</a></code></li>
fb77c505254b6e9c925e23e734463e87574f8f40kess<li><code class="directive"><a href="#serveralias">ServerAlias</a></code></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<div class="directive-section"><h2><a name="ServerPath" id="ServerPath">ServerPath</a> <a name="serverpath" id="serverpath">Directive</a></h2>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Legacy URL pathname for a name-based virtual host that
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cndis accessed by an incompatible browser</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerPath <var>URL-path</var></code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>virtual host</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>The <code class="directive">ServerPath</code> directive sets the legacy
a0fed3e26656887c8458aa1081d516d08ced3c84trawick URL pathname for a host, for use with <a href="/vhosts/">name-based virtual hosts</a>.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<h3>See also</h3>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<li><a href="/vhosts/">Apache Virtual Host documentation</a></li>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen</ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="directive-section"><h2><a name="ServerRoot" id="ServerRoot">ServerRoot</a> <a name="serverroot" id="serverroot">Directive</a></h2>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<table class="directive">
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Base directory for the server installation</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerRoot <var>directory-path</var></code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerRoot /usr/local/apache</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>The <code class="directive">ServerRoot</code> directive sets the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick directory in which the server lives. Typically it will contain the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick subdirectories <code>conf/</code> and <code>logs/</code>. Relative
a0fed3e26656887c8458aa1081d516d08ced3c84trawick paths for other configuration files are taken as relative to this
a0fed3e26656887c8458aa1081d516d08ced3c84trawick directory.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <div class="example"><h3>Example</h3><p><code>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick ServerRoot /home/httpd
a0fed3e26656887c8458aa1081d516d08ced3c84trawick </code></p></div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<h3>See also</h3>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<li><a href="/invoking.html">the <code>-d</code>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick option to <code>httpd</code></a></li>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<li><a href="/misc/security_tips.html#serverroot">the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick security tips</a> for information on how to properly set
a0fed3e26656887c8458aa1081d516d08ced3c84trawick permissions on the <code class="directive">ServerRoot</code></li>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="directive-section"><h2><a name="ServerSignature" id="ServerSignature">ServerSignature</a> <a name="serversignature" id="serversignature">Directive</a></h2>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<table class="directive">
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures the footer on server-generated documents</td></tr>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerSignature On|Off|EMail</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerSignature Off</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>All</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>The <code class="directive">ServerSignature</code> directive allows the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick configuration of a trailing footer line under server-generated
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick documents (error messages, <code class="module"><a href="/mod/mod_proxy.html">mod_proxy</a></code> ftp directory
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick listings, <code class="module"><a href="/mod/mod_info.html">mod_info</a></code> output, ...). The reason why you
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick would want to enable such a footer line is that in a chain of proxies,
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick the user often has no possibility to tell which of the chained servers
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick actually produced a returned error message.</p>
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick <p>The <code>Off</code>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick setting, which is the default, suppresses the footer line (and is
a0fed3e26656887c8458aa1081d516d08ced3c84trawick therefore compatible with the behavior of Apache-1.2 and
a0fed3e26656887c8458aa1081d516d08ced3c84trawick below). The <code>On</code> setting simply adds a line with the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick server version number and <code class="directive"><a href="#servername">ServerName</a></code> of the serving virtual host,
a0fed3e26656887c8458aa1081d516d08ced3c84trawick and the <code>EMail</code> setting additionally creates a
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor "mailto:" reference to the <code class="directive"><a href="#serveradmin">ServerAdmin</a></code> of the referenced
a0fed3e26656887c8458aa1081d516d08ced3c84trawick document.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick <p>After version 2.0.44, the details of the server version number
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick presented are controlled by the <code class="directive"><a href="#servertokens">ServerTokens</a></code> directive.</p>
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick<h3>See also</h3>
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick<ul>
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick<li><code class="directive"><a href="#servertokens">ServerTokens</a></code></li>
bf0e7f6393e91c0a7c15cb0d889a4238c973dc2etrawick</ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="directive-section"><h2><a name="ServerTokens" id="ServerTokens">ServerTokens</a> <a name="servertokens" id="servertokens">Directive</a></h2>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<table class="directive">
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures the Server HTTP response
a0fed3e26656887c8458aa1081d516d08ced3c84trawickheader</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<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>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ServerTokens Full</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>This directive controls whether <code>Server</code> response
a0fed3e26656887c8458aa1081d516d08ced3c84trawick header field which is sent back to clients includes a
a0fed3e26656887c8458aa1081d516d08ced3c84trawick description of the generic OS-type of the server as well as
a0fed3e26656887c8458aa1081d516d08ced3c84trawick information about compiled-in modules.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dl>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens Prod[uctOnly]</code></dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dd>Server sends (<em>e.g.</em>): <code>Server:
a0fed3e26656887c8458aa1081d516d08ced3c84trawick Apache</code></dd>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens Major</code></dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor <dd>Server sends (<em>e.g.</em>): <code>Server:
a0fed3e26656887c8458aa1081d516d08ced3c84trawick Apache/2</code></dd>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens Minor</code></dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dd>Server sends (<em>e.g.</em>): <code>Server:
a0fed3e26656887c8458aa1081d516d08ced3c84trawick Apache/2.0</code></dd>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens Min[imal]</code></dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dd>Server sends (<em>e.g.</em>): <code>Server:
a0fed3e26656887c8458aa1081d516d08ced3c84trawick Apache/2.0.41</code></dd>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens OS</code></dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dd>Server sends (<em>e.g.</em>): <code>Server: Apache/2.0.41
a0fed3e26656887c8458aa1081d516d08ced3c84trawick (Unix)</code></dd>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dt><code>ServerTokens Full</code> (or not specified)</dt>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <dd>Server sends (<em>e.g.</em>): <code>Server: Apache/2.0.41
a0fed3e26656887c8458aa1081d516d08ced3c84trawick (Unix) PHP/4.2.2 MyMod/1.2</code></dd>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor </dl>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
215694531f7d868b906df96e22a80e6a1d2326a6lgentis <p>This setting applies to the entire server, and cannot be
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor enabled or disabled on a virtualhost-by-virtualhost basis.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>After version 2.0.44, this directive also controls the
a0fed3e26656887c8458aa1081d516d08ced3c84trawick information presented by the <code class="directive"><a href="#serversignature">ServerSignature</a></code> directive.</p>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<h3>See also</h3>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<ul>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<li><code class="directive"><a href="#serversignature">ServerSignature</a></code></li>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</ul>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</div>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<div class="directive-section"><h2><a name="SetHandler" id="SetHandler">SetHandler</a> <a name="sethandler" id="sethandler">Directive</a></h2>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<table class="directive">
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Forces all matching files to be processed by a
a0fed3e26656887c8458aa1081d516d08ced3c84trawickhandler</td></tr>
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetHandler <var>handler-name</var>|None</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Moved into the core in Apache 2.0</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>When placed into an <code>.htaccess</code> file or a
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <code class="directive"><a href="#directory">&lt;Directory&gt;</a></code> or
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <code class="directive"><a href="#location">&lt;Location&gt;</a></code>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick section, this directive forces all matching files to be parsed
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick through the <a href="/handler.html">handler</a> given by
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <var>handler-name</var>. For example, if you had a directory you
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick wanted to be parsed entirely as imagemap rule files, regardless
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick of extension, you might put the following into an
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <code>.htaccess</code> file in that directory:</p>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <div class="example"><p><code>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick SetHandler imap-file
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick </code></p></div>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <p>Another example: if you wanted to have the server display a
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick status report whenever a URL of
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <code>http://servername/status</code> was called, you might put
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick the following into <code>httpd.conf</code>:</p>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <div class="example"><p><code>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick &lt;Location /status&gt;<br />
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <span class="indent">
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick SetHandler server-status<br />
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick </span>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick &lt;/Location&gt;
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick </code></p></div>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <p>You can override an earlier defined <code class="directive">SetHandler</code>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick directive by using the value <code>None</code>.</p>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<h3>See also</h3>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<ul>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<li><code class="directive"><a href="/mod/mod_mime.html#addhandler">AddHandler</a></code></li>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</ul>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</div>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<div class="directive-section"><h2><a name="SetInputFilter" id="SetInputFilter">SetInputFilter</a> <a name="setinputfilter" id="setinputfilter">Directive</a></h2>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<table class="directive">
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Sets the filters that will process client requests and POST
2b6c7b8eb5fbc43564898aedac730df7e91da475trawickinput</td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetInputFilter <var>filter</var>[;<var>filter</var>...]</code></td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</table>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <p>The <code class="directive">SetInputFilter</code> directive sets the
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick filter or filters which will process client requests and POST
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick input when they are received by the server. This is in addition to
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick any filters defined elsewhere, including the
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <code class="directive"><a href="/mod/mod_mime.html#addinputfilter">AddInputFilter</a></code>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick directive.</p>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick <p>If more than one filter is specified, they must be separated
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick by semicolons in the order in which they should process the
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick content.</p>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<h3>See also</h3>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<ul>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick<li><a href="/filter.html">Filters</a> documentation</li>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</ul>
2b6c7b8eb5fbc43564898aedac730df7e91da475trawick</div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<div class="directive-section"><h2><a name="SetOutputFilter" id="SetOutputFilter">SetOutputFilter</a> <a name="setoutputfilter" id="setoutputfilter">Directive</a></h2>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<table class="directive">
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Sets the filters that will process responses from the
a0fed3e26656887c8458aa1081d516d08ced3c84trawickserver</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SetOutputFilter <var>filter</var>[;<var>filter</var>...]</code></td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Override">Override:</a></th><td>FileInfo</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick</table>
a0fed3e26656887c8458aa1081d516d08ced3c84trawick <p>The <code class="directive">SetOutputFilter</code> directive sets the filters
a0fed3e26656887c8458aa1081d516d08ced3c84trawick which will process responses from the server before they are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive sent to the client. This is in addition to any filters defined
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive elsewhere, including the
003f0c9fda6664daf5092a0e42f65ede20098153slive <code class="directive"><a href="/mod/mod_mime.html#addoutputfilter">AddOutputFilter</a></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive.</p>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For example, the following configuration will process all files
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive in the <code>/www/data/</code> directory for server-side
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive includes.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener <div class="example"><p><code>
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener &lt;Directory /www/data/&gt;<br />
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener <span class="indent">
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener SetOutputFilter INCLUDES<br />
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener </span>
fb77c505254b6e9c925e23e734463e87574f8f40kess &lt;/Directory&gt;
ffec3e56ff5331a2d732ec07e9d107303fed43f4covener </code></p></div>
3386d67e54f92fdf6a3ffc5f7f8081eed6c44badslive
3386d67e54f92fdf6a3ffc5f7f8081eed6c44badslive <p>If more than one filter is specified, they must be separated
05201775eaa6b363b8a119c8aea5db246b967591yoshiki by semicolons in the order in which they should process the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen content.</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/filter.html">Filters</a> documentation</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="directive-section"><h2><a name="TimeOut" id="TimeOut">TimeOut</a> <a name="timeout" id="timeout">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Amount of time the server will wait for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivecertain events before failing a request</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>TimeOut <var>seconds</var></code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>TimeOut 300</code></td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <code class="directive">TimeOut</code> directive currently defines
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the amount of time Apache will wait for three things:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <ol>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>The total amount of time it takes to receive a GET
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request.</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>The amount of time between receipt of TCP packets on a
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess POST or PUT request.</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic <li>The amount of time between ACKs on transmissions of TCP
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive packets in responses.</li>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </ol>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>We plan on making these separately configurable at some point
13e5182a0c199ecc7a73db97b6448a544e940868slive down the road. The timer used to default to 1200 before 1.2,
13e5182a0c199ecc7a73db97b6448a544e940868slive but has been lowered to 300 which is still far more than
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive necessary in most situations. It is not set any lower by
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess default because there may still be odd places in the code where
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the timer is not reset when a packet is sent. </p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic</div>
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<div class="directive-section"><h2><a name="UseCanonicalName" id="UseCanonicalName">UseCanonicalName</a> <a name="usecanonicalname" id="usecanonicalname">Directive</a></h2>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<table class="directive">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Configures how the server determines its own name and
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cndport</td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>UseCanonicalName On|Off|DNS</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>UseCanonicalName On</code></td></tr>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory</td></tr>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive</table>
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <p>In many situations Apache must construct a <em>self-referential</em>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive URL -- that is, a URL that refers back to the same server. With
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <code>UseCanonicalName On</code> Apache will use the hostname and port
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specified in the <code class="directive"><a href="#servername">ServerName</a></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive to construct the canonical name for the server. This name
13e5182a0c199ecc7a73db97b6448a544e940868slive is used in all self-referential URLs, and for the values of
13e5182a0c199ecc7a73db97b6448a544e940868slive <code>SERVER_NAME</code> and <code>SERVER_PORT</code> in CGIs.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>With <code>UseCanonicalName Off</code> Apache will form
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive self-referential URLs using the hostname and port supplied by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the client if any are supplied (otherwise it will use the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive canonical name, as defined above). These values are the same
13e5182a0c199ecc7a73db97b6448a544e940868slive that are used to implement <a href="/vhosts/name-based.html">name based virtual hosts</a>,
13e5182a0c199ecc7a73db97b6448a544e940868slive and are available with the same clients. The CGI variables
13e5182a0c199ecc7a73db97b6448a544e940868slive <code>SERVER_NAME</code> and <code>SERVER_PORT</code> will be
b00583f8e126bbb00b06dcf06af06c9d07978701kess constructed from the client supplied values as well.</p>
13e5182a0c199ecc7a73db97b6448a544e940868slive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>An example where this may be useful is on an intranet server
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess where you have users connecting to the machine using short
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive names such as <code>www</code>. You'll notice that if the users
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type a shortname, and a URL which is a directory, such as
0d5b778ac63bc803c0dd1a4fdef371fe7a0f4b57kess <code>http://www/splat</code>, <em>without the trailing
13e5182a0c199ecc7a73db97b6448a544e940868slive slash</em> then Apache will redirect them to
13e5182a0c199ecc7a73db97b6448a544e940868slive <code>http://www.domain.com/splat/</code>. If you have
13e5182a0c199ecc7a73db97b6448a544e940868slive authentication enabled, this will cause the user to have to
13e5182a0c199ecc7a73db97b6448a544e940868slive authenticate twice (once for <code>www</code> and once again
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for <code>www.domain.com</code> -- see <a href="http://httpd.apache.org/docs/misc/FAQ.html#prompted-twice">the
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess FAQ on this subject for more information</a>). But if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code class="directive">UseCanonicalName</code> is set <code>Off</code>, then
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Apache will redirect to <code>http://www/splat/</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive
13e5182a0c199ecc7a73db97b6448a544e940868slive <p>There is a third option, <code>UseCanonicalName DNS</code>,
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic which is intended for use with mass IP-based virtual hosting to
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic support ancient clients that do not provide a
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic <code>Host:</code> header. With this option Apache does a
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic reverse DNS lookup on the server IP address that the client
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic connected to in order to work out self-referential URLs.</p>
96969ed53a757bd9e0a4d7f2f499c9db5ef7899eigalic
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <div class="warning"><h3>Warning</h3>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>If CGIs make assumptions about the values of <code>SERVER_NAME</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive they may be broken by this option. The client is essentially free
13e5182a0c199ecc7a73db97b6448a544e940868slive to give whatever value they want as a hostname. But if the CGI is
13e5182a0c199ecc7a73db97b6448a544e940868slive only using <code>SERVER_NAME</code> to construct self-referential URLs
13e5182a0c199ecc7a73db97b6448a544e940868slive then it should be just fine.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </div>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive
13e5182a0c199ecc7a73db97b6448a544e940868slive<h3>See also</h3>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive<ul>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive<li><code class="directive"><a href="#servername">ServerName</a></code></li>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive<li><code class="directive"><a href="/mod/mpm_common.html#listen">Listen</a></code></li>
1c5fe3e61f0f3202ae0f853740d53f3aff4c4afbslive</ul>
13e5182a0c199ecc7a73db97b6448a544e940868slive</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
13e5182a0c199ecc7a73db97b6448a544e940868slive<div class="directive-section"><h2><a name="VirtualHost" id="VirtualHost">&lt;VirtualHost&gt;</a> <a name="virtualhost" id="virtualhost">Directive</a></h2>
13e5182a0c199ecc7a73db97b6448a544e940868slive<table class="directive">
13e5182a0c199ecc7a73db97b6448a544e940868slive<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply only to a specific
13e5182a0c199ecc7a73db97b6448a544e940868slivehostname or IP address</td></tr>
13e5182a0c199ecc7a73db97b6448a544e940868slive<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>&lt;VirtualHost
13e5182a0c199ecc7a73db97b6448a544e940868slive <var>addr</var>[:<var>port</var>] [<var>addr</var>[:<var>port</var>]]
13e5182a0c199ecc7a73db97b6448a544e940868slive ...&gt; ... &lt;/VirtualHost&gt;</code></td></tr>
13e5182a0c199ecc7a73db97b6448a544e940868slive<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
13e5182a0c199ecc7a73db97b6448a544e940868slive<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
13e5182a0c199ecc7a73db97b6448a544e940868slive<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr>
13e5182a0c199ecc7a73db97b6448a544e940868slive</table>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><code class="directive">&lt;VirtualHost&gt;</code> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>&lt;/VirtualHost&gt;</code> are used to enclose a group of
2cef7e294acb5d8b8b5dcb21a55438da0b73f63figalic directives that will apply only to a particular virtual host. Any
3b9c7ec844aa240622a33735d1b9cbac4232e268rbowen directive that is allowed in a virtual host context may be
2cef7e294acb5d8b8b5dcb21a55438da0b73f63figalic used. When the server receives a request for a document on a
2cef7e294acb5d8b8b5dcb21a55438da0b73f63figalic particular virtual host, it uses the configuration directives
3b9c7ec844aa240622a33735d1b9cbac4232e268rbowen enclosed in the <code class="directive">&lt;VirtualHost&gt;</code>
3b9c7ec844aa240622a33735d1b9cbac4232e268rbowen section. <var>Addr</var> can be:</p>
fb77c505254b6e9c925e23e734463e87574f8f40kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <ul>
130d299c4b2b15be45532a176604c71fdc7bea5bnd <li>The IP address of the virtual host;</li>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <li>A fully qualified domain name for the IP address of the
130d299c4b2b15be45532a176604c71fdc7bea5bnd virtual host;</li>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <li>The character <code>*</code>, which is used only in combination with
130d299c4b2b15be45532a176604c71fdc7bea5bnd <code>NameVirtualHost *</code> to match all IP addresses; or</li>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <li>The string <code>_default_</code>, which is used only
130d299c4b2b15be45532a176604c71fdc7bea5bnd with IP virtual hosting to catch unmatched IP addresses.</li>
130d299c4b2b15be45532a176604c71fdc7bea5bnd </ul>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <div class="example"><h3>Example</h3><p><code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive &lt;VirtualHost 10.1.2.3&gt;<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <span class="indent">
fb77c505254b6e9c925e23e734463e87574f8f40kess ServerAdmin webmaster@host.foo.com<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess DocumentRoot /www/docs/host.foo.com<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess ServerName host.foo.com<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ErrorLog logs/host.foo.com-error_log<br />
130d299c4b2b15be45532a176604c71fdc7bea5bnd TransferLog logs/host.foo.com-access_log<br />
130d299c4b2b15be45532a176604c71fdc7bea5bnd </span>
130d299c4b2b15be45532a176604c71fdc7bea5bnd &lt;/VirtualHost&gt;
130d299c4b2b15be45532a176604c71fdc7bea5bnd </code></p></div>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <p>IPv6 addresses must be specified in square brackets because
130d299c4b2b15be45532a176604c71fdc7bea5bnd the optional port number could not be determined otherwise. An
130d299c4b2b15be45532a176604c71fdc7bea5bnd IPv6 example is shown below:</p>
130d299c4b2b15be45532a176604c71fdc7bea5bnd
130d299c4b2b15be45532a176604c71fdc7bea5bnd <div class="example"><p><code>
130d299c4b2b15be45532a176604c71fdc7bea5bnd &lt;VirtualHost [fe80::a00:20ff:fea7:ccea]&gt;<br />
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd <span class="indent">
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd ServerAdmin webmaster@host.example.com<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive DocumentRoot /www/docs/host.example.com<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess ServerName host.example.com<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess ErrorLog logs/host.example.com-error_log<br />
fb77c505254b6e9c925e23e734463e87574f8f40kess TransferLog logs/host.example.com-access_log<br />
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </span>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess &lt;/VirtualHost&gt;
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess </code></p></div>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess
313bb560bc5c323cfd40c9cad7335b4b8e060aedkess <p>Each Virtual Host must correspond to a different IP address,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive different port number or a different host name for the server,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive in the former case the server machine must be configured to
9e0536cd66a389bdaa758a825b8bbd8fea665a3eigalic accept IP packets for multiple addresses. (If the machine does
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive not have multiple network interfaces, then this can be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accomplished with the <code>ifconfig alias</code> command -- if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive your OS supports it).</p>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <div class="note"><h3>Note</h3>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <p>The use of <code class="directive">&lt;VirtualHost&gt;</code> does
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <strong>not</strong> affect what addresses Apache listens on. You
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen may need to ensure that Apache is listening on the correct addresses
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen using <code class="directive"><a href="/mod/mpm_common.html#listen">Listen</a></code>.</p>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen </div>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <p>When using IP-based virtual hosting, the special name
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <code>_default_</code> can be specified in
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen which case this virtual host will match any IP address that is
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen not explicitly listed in another virtual host. In the absence
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen of any <code>_default_</code> virtual host the "main" server config,
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen consisting of all those definitions outside any VirtualHost
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen section, is used when no IP-match occurs. (But note that any IP
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen address that matches a <code class="directive"><a href="#namevirtualhost">NameVirtualHost</a></code> directive will use neither
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen the "main" server config nor the <code>_default_</code> virtual host.
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen See the <a href="/vhosts/name-based.html">name-based virtual hosting</a>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen documentation for further details.)</p>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <p>You can specify a <code>:port</code> to change the port that is
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen matched. If unspecified then it defaults to the same port as the
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen most recent <code class="directive"><a href="/mod/mpm_common.html#listen">Listen</a></code>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen statement of the main server. You may also specify <code>:*</code>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen to match all ports on that address. (This is recommended when used
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen with <code>_default_</code>.)</p>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <div class="warning"><h3>Security</h3>
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowen <p>See the <a href="/misc/security_tips.html">security tips</a>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document for details on why your security could be compromised if the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory where logfiles are stored is writable by anyone other
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive than the user that starts the server.</p>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen </div>
ef8e89e090461194ecadd31e8796a2c51e0531a2kess
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<h3>See also</h3>
530eba85dbd41b8a0fa5255d3648d1440199a661slive<ul>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<li><a href="/vhosts/">Apache Virtual Host documentation</a></li>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<li><a href="/dns-caveats.html">Issues Regarding DNS and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Apache</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/bind.html">Setting
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive which addresses and ports Apache uses</a></li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<li><a href="/sections.html">How &lt;Directory&gt;, &lt;Location&gt;
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive and &lt;Files&gt; sections work</a> for an explanation of how these
a7f40ca49262952d6dd69d021cf5b0c2b452ae4cnd different sections are combined when a request is received</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</ul>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</div>
ef8e89e090461194ecadd31e8796a2c51e0531a2kess</div>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<div class="bottomlang">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<p><span>Available Languages: </span><a href="/de/mod/core.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<a href="/en/mod/core.html" title="English">&nbsp;en&nbsp;</a></p>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen</div><div id="footer">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<p class="apache">Maintained by the <a href="http://httpd.apache.org/docs-project/">Apache HTTP Server Documentation Project</a></p>
88d86cfadffe2275a3dfb67a4d7bdc018630b661rbowen<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>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</body></html>