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