core.xml revision 80c4526970a11f37c0f8e3b82afdf03902dac3f3
e942c741056732f50da2074b36fe59805d370650slive<?xml-stylesheet type="text/xsl" href="/style/manual.xsl"?>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<modulesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Core Apache HTTP Server features that are always
530eba85dbd41b8a0fa5255d3648d1440199a661sliveavailable</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
003f0c9fda6664daf5092a0e42f65ede20098153slive<description>Controls whether requests can contain trailing pathname information</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>virtual host</context><context>directory</context>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<compatibility>Available in Apache 2.0.30 and later</compatibility>
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive available to scripts in the PATH_INFO environment variable.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For example, assume the location <code>/test/</code> points to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a directory that contains only the single file
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The three possible arguments for the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive>AcceptPathInfo</directive> directive are:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>off</code></dt><dd>A request will only be accepted if it
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive maps to a literal path that exists. Therefore a request with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive trailing pathname information after the true filename such as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/test/here.html/more</code> in the above example will return
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a 404 NOT FOUND error.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>on</code></dt><dd>A request will be accepted if a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive leading path component maps to a file that exists. The above
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive example <code>/test/here.html/more</code> will be accepted if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/test/here.html</code> maps to a valid file.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>default</code></dt><dd>The treatment of requests with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive trailing pathname information is determined by the <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/handler.html">handler</a> responsible for the request.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The core handler for normal files defaults to rejecting PATH_INFO.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Handlers that serve scripts, such as <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="mod_isapi.html">isapi-isa</a>, generally accept PATH_INFO by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive default.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The primary purpose of the <code>AcceptPathInfo</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive is to allow you to override the handler's choice of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accepting or rejecting PATH_INFO. This override is required, for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive example, when you use a <a href="/filter.html">filter</a>, such
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive as <a href="mod_include.html">INCLUDES</a>, to generate content
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive based on PATH_INFO. The core handler would usually reject the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request, so you can use the following configuration to enable
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive such a script:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Options +Includes<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive SetOutputFilter INCLUDES<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AcceptPathInfo on<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</Files>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the name of the .htaccess file</description>
003f0c9fda6664daf5092a0e42f65ede20098153slive<syntax>AccessFileName <em>filename</em> [<em>filename</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When returning a document to the client the server looks for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the first existing access control file from this list of names
003f0c9fda6664daf5092a0e42f65ede20098153slive in every directory of the path to the document, if access
003f0c9fda6664daf5092a0e42f65ede20098153slive control files are enabled for that directory. For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveAccessFileName .acl
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>before returning the document
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/usr/local/web/index.html</code>, the server will read
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/usr/local/.acl</code> and <code>/usr/local/web/.acl</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for directives, unless they have been disabled with</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<Directory /><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AllowOverride None<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</Directory>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">AllowOverride</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/configuring.html">Configuration Files</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Specifies the default character set to be added for a
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveresponse without an explicit character set</description>
003f0c9fda6664daf5092a0e42f65ede20098153slive<syntax>AddDefaultCharset On|Off|<em>charset</em></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>virtual host</context><context>directory</context>
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive required by the directive. You can also specify an alternate
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AddDefaultCharset utf-8
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>AddModule <em>module</em> [<em>module</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The server can have modules compiled in which are not
003f0c9fda6664daf5092a0e42f65ede20098153slive actively in use. This directive can be used to enable the use
003f0c9fda6664daf5092a0e42f65ede20098153slive of those modules. The server comes with a pre-loaded list of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive active modules; this list can be cleared with the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">ClearModuleList</directive> directive.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveAddDefaultCharset utf-8
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the types of directives that are allowed in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive.htaccess files</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>AllowOverride All|None|<em>directive-type</em> [<em>directive-type</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When the server finds an .htaccess file (as specified by <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">AccessFileName</directive>) it needs to know
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive which directives declared in that file can override earlier
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive access information.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When this directive is set to <code>None</code>, then
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive .htaccess files are completely ignored. In this case, the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server will not even attempt to read .htaccess files in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive filesystem.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When this directive is set to <code>All</code>, then any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive which has the .htaccess <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="directive-dict.html#Context">Context</a> is allowed in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive .htaccess files.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <em>directive-type</em> can be one of the following
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive groupings of directives.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the authorization directives (<directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_auth_dbm">AuthDBMUserFile</directive>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_auth">AuthGroupFile</directive>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core">AuthType</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_auth">AuthUserFile</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">Require</directive>, <em>etc.</em>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling document types (<directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_negotiation">LanguagePriority</directive>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core">SetHandler</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling directory indexing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (<directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_autoindex">AddIcon</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_autoindex">AddIconByType</directive>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_autoindex">DefaultIcon</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_dir">DirectoryIndex</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_autoindex">FancyIndexing</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_autoindex">HeaderName</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_autoindex">IndexIgnore</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="mod_autoindex">IndexOptions</directive>, <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling host access (<directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Allow use of the directives controlling specific directory
003f0c9fda6664daf5092a0e42f65ede20098153slive features (<directive module="core">Options</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_include">XBitHack</directive>).</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">AccessFileName</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/configuring.html">Configuration Files</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the authorization realm for use in HTTP
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveauthentication</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the name of the authorization realm for a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory. This realm is given to the client so that the user
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive marks. It must be accompanied by <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">Require</directive> directives, and directives such
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive as <directive module="mod_auth">AuthUserFile</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_auth">AuthGroupFile</directive> to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The string provided for the <code>AuthRealm</code> is what will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive appear in the password dialog provided by most browsers.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/howto/auth.html">Authentication, Authorization, and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Selects the type of user authentication</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive selects the type of user authentication for a
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes directory. Only <code>Basic</code> and <code>Digest</code> are
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes currently implemented.
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes It must be accompanied by <directive
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes module="core">Require</directive> directives, and directives such
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes as <directive module="mod_auth">AuthUserFile</directive> and
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes <directive module="mod_auth">AuthGroupFile</directive> to
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes<seealso><a href="/howto/auth.html">Authentication, Authorization,
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes</directivesynopsis>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes<directivesynopsis>
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholes<description>Enables the generation of Content-MD5 HTTP Response
4c7bdb15764021d39e486adb7bc2166d3f683773bnicholesheaders</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>Available in Apache 1.1 and later</compatibility>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive enables the generation of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Content-MD5</code> headers as defined in RFC1864
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive respectively RFC2068.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>MD5 is an algorithm for computing a "message digest"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (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 <p>The <code>Content-MD5</code> header provides an end-to-end
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note that this can cause performance problems on your server
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive since the message digest is computed on every request (the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive values are not cached).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><code>Content-MD5</code> is only sent for documents served
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive by the core, and not by any module. For example, SSI documents,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive output from CGI scripts, and byte range responses do not have
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive this header.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the MIME content-type that will be sent if the
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveserver cannot determine a type in any other way</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
76f2a3125fb6aca59d43b02220dabac91175a281slive</contextlist>
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 <p>The server must inform the client of the content-type of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document, so in the event of an unknown type it uses the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive would be appropriate for a directory which contained many gif
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive images with filenames missing the .gif extension.
530eba85dbd41b8a0fa5255d3648d1440199a661slive module="core">ForceType</directive>, this directive is only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive provides the default mime-type. All other mime-type definitions,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive including filename extensions, that might identify the media type
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive will override this default.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Enclose a group of directives that apply only to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivenamed file-system directory and sub-directories</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive... </Directory></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">Directory</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code></Directory></code> are used to enclose a group of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives which will apply only to the named directory and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive sub-directories of that directory. Any directive which is allowed
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive in a directory context may be used. <em>Directory-path</em> is
003f0c9fda6664daf5092a0e42f65ede20098153slive either the full path to a directory, or a wild-card string. In a
003f0c9fda6664daf5092a0e42f65ede20098153slive wild-card string, `?' matches any single character, and `*'
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive matches any sequences of characters. You may
003f0c9fda6664daf5092a0e42f65ede20098153slive also use `[]' character ranges like in the shell. Also as of
003f0c9fda6664daf5092a0e42f65ede20098153slive Apache 1.3 none of the wildcards match a `/' character, which more
003f0c9fda6664daf5092a0e42f65ede20098153slive closely mimics the behavior of Unix shells. Example:</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive Options Indexes FollowSymLinks<br />
003f0c9fda6664daf5092a0e42f65ede20098153slive </Directory><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Extended regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expressions can also be used, with the addition of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Directory ~ "^/www/.*/[0-9]{3}">
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen would match directories in /www/ that consisted of three
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen <p>If multiple (non-regular expression) directory sections
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen match the directory (or its parents) containing a document,
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen then the directives are applied in the order of shortest match
b06660a3ed3d885e15d99c0209a46c4657df33fbrbowen first, interspersed with the directives from the <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="#accessfilename">.htaccess</a> files. For example,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Directory /><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AllowOverride None<br />
530eba85dbd41b8a0fa5255d3648d1440199a661slive </Directory><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Directory /home/*><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AllowOverride FileInfo<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Directory>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>for access to the document <code>/home/web/dir/doc.html</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the steps are:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>Apply directive <code>AllowOverride FileInfo</code> (for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>Apply any FileInfo directives in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Regular expressions are not considered until after all of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive normal sections have been applied. Then all of the regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expressions are tested in the order they appeared in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive configuration file. For example, with</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ... directives here ...<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Directory><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The regular expression section won't be considered until after
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive all normal <Directory>s and <code>.htaccess</code> files
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive have been applied. Then the regular expression will match on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>/home/abc/public_html/abc</code> and be applied.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Directory /> is <samp>Allow from All</samp>. This means
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that Apache will serve any file mapped from an URL. It is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive recommended that you change this with a block such
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Directory /><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Order Deny,Allow<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Deny from All<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Directory>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/misc/security_tips.html">Security Tips</a> page for more
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The directory sections typically occur in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the access.conf file, but they may appear in any configuration
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive file. <directive type="section">Directory</directive> directives
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive cannot nest, and cannot appear in a <directive module="core"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">Limit</directive> or <directive module="core"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive explanation of how these different sections are combined when a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request is received</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Enclose a group of directives that apply only to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefile-system directories that match a regular expression and their
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivesubdirectories</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive... </Directory></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">DirectoryMatch</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code></DirectoryMatch></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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core" type="section">Directory</directive>. However, it
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive takes as an argument a regular expression. For example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <DirectoryMatch "^/www/.*/[0-9]{3}">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>would match directories in <code>/www/</code> that consisted of three
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive numbers.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive type="section" module="core">Directory</directive> for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivea description of how regular expressions are mixed in with normal
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivehref="/sections.html">How Directory, Location and Files sections
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivework</a> for an explanation of how these different sections are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivecombined when a request is received</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the directory that forms the main document tree visible
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefrom the web</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<default>DocumentRoot /usr/local/apache/htdocs</default>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the directory from which httpd will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive serve files. Unless matched by a directive like Alias, the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server appends the path from the requested URL to the document
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive root to make the path to the document. Example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>then an access to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>http://www.my.host.com/index.html</code> refers to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>DocumentRoot</directive> should be specified without
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a trailing slash.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/urlmapping.html">Mapping URLs to Filesystem
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Specifies what the server will return to the client
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivein case of an error</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>ErrorDocument <em>error-code document</em></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>Quoting syntax for text messages is different in Apache
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive2.0</compatibility>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp <p>In the event of a problem or error, Apache can be configured
af18698b10b429b270551ca3a5d51a75e1c9db22brianp to do one of four things,</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive <li>redirect to a local <em>URL-path</em> to handle the
003f0c9fda6664daf5092a0e42f65ede20098153slive <li>redirect to an external <em>URL</em> to handle the
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>The first option is the default, while options 2-4 are
003f0c9fda6664daf5092a0e42f65ede20098153slive configured using the <directive>ErrorDocument</directive>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp directive, which is followed by the HTTP response code and a URL
af18698b10b429b270551ca3a5d51a75e1c9db22brianp or a message. Apache will sometimes offer additional information
af18698b10b429b270551ca3a5d51a75e1c9db22brianp <p>URLs can begin with a slash (/) for local URLs, or be a full
af18698b10b429b270551ca3a5d51a75e1c9db22brianp URL which the client can resolve. Alternatively, a message can
af18698b10b429b270551ca3a5d51a75e1c9db22brianp be provided to be displayed by the browser. Examples:</p>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp ErrorDocument 500
af18698b10b429b270551ca3a5d51a75e1c9db22brianp ErrorDocument 403 "Sorry can't allow you access
af18698b10b429b270551ca3a5d51a75e1c9db22brianp <p>Note that when you specify an <directive>ErrorDocument</directive>
af18698b10b429b270551ca3a5d51a75e1c9db22brianp that points to a remote URL (ie. anything with a method such as
af18698b10b429b270551ca3a5d51a75e1c9db22brianp "http" in front of it), Apache will send a redirect to the
af18698b10b429b270551ca3a5d51a75e1c9db22brianp client to tell it where to find the document, even if the
af18698b10b429b270551ca3a5d51a75e1c9db22brianp document ends up being on the same server. This has several
af18698b10b429b270551ca3a5d51a75e1c9db22brianp implications, the most important being that the client will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive the original error status code, but instead will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive a redirect status code. This in turn can confuse web
003f0c9fda6664daf5092a0e42f65ede20098153slive robots and other clients which try to determine if a URL is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive valid using the status code. In addition, if you use a remote
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive URL in an <code>ErrorDocument 401</code>, the client will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive know to prompt the user for a password since it will not
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive receive the 401 status code. Therefore, <strong>if you use an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive "ErrorDocument 401" directive then it must refer to a local
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Prior to version 2.0, messages were indicated by prefixing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive them with a single unmatched double quote character.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the name of the file to which the server
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivewill log errors</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax> ErrorLog <em>file-path</em>|syslog[:<em>facility</em>]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>ErrorLog</directive> directive sets the name of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the file to which the server will log any errors it encounters. If
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the <em>file-path</em> does not begin with a slash (/) then it is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive assumed to be relative to the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">ServerRoot</directive>. If the <em>file-path</em>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive begins with a pipe (|) then it is assumed to be a command to spawn
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to handle the error log.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Using <code>syslog</code> instead of a filename enables logging
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive via syslogd(8) if the system supports it. The default is to use
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive syslog facility <code>local7</code>, but you can override this by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive using the <code>syslog:</code><em>facility</em> syntax where
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>facility</em> can be one of the names usually documented in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive syslog(1).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive anyone other than the user that starts the server.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">LogLevel</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/logs.html">Apache Log Files</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures the file attributes used to create the ETag
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveHTTP response header</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive The <directive>FileETag</directive> directive configures the file
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive attributes that are used to create the ETag (entity tag) response
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive header field when the document is based on a file. (The ETag
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive value is used in cache management to save network bandwidth.) In
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive Apache 1.3.22 and earlier, the ETag value was <em>always</em> formed
4f854c24127e28f7ad72ce9a39d4448aaf910fc1slive from the file's inode, size, and last-modified time (mtime). The
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive FileETag directive allows you to choose which of these -- if any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive -- should be used. The recognized keywords are:
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>The file's i-node number will be included in the calculation</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>The date and time the file was last modified will be included</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>The number of bytes in the file will be included</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>All available fields will be used (equivalent to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive '<code>FileETag INode MTime Size</code>')</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>If a document is file-based, no ETag field will be included in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive response</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The INode, MTime, and Size keywords may be prefixed with either '+'
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or '-', which allow changes to be made to the default setting
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive inherited from a broader scope. Any keyword appearing without
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive such a prefix immediately and completely cancels the inherited
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive If a directory's configuration includes
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive '<code>FileETag INode MTime Size</code>', and a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive subdirectory's includes '<code>FileETag -INode</code>',
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the setting for that subdirectory (which will be inherited by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive any sub-subdirectories that don't override it) will be equivalent to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Contains that directives that apply to matched
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefilenames</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><Files <em>filename</em>> ... </Files></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>The <directive type="section">Files</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive provides for access control by filename. It is comparable to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core" type="directive">Directory</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="directive">Location</directive> directives. It should be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive matched with a <code></Files></code> directive. The
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives given within this section will be applied to any object
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive with a basename (last component of filename) matching the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specified filename. <directive type="section">Files</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive sections are processed in the order they appear in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive configuration file, after the <directive module="core"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>.htaccess</code> files are read, but before <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section" module="core">Location</directive> sections. Note
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that <directive type="section">Files</directive> can be nested
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">Directory</directive> sections to restrict the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive portion of the filesystem they apply to.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <em>filename</em> argument should include a filename, or
530eba85dbd41b8a0fa5255d3648d1440199a661slive a wild-card string, where `?' matches any single character, and
530eba85dbd41b8a0fa5255d3648d1440199a661slive `*' matches any sequences of characters. Extended regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expressions can also be used, with the addition of the
530eba85dbd41b8a0fa5255d3648d1440199a661slive <Files ~ "\.(gif|jpe?g|png)$">
530eba85dbd41b8a0fa5255d3648d1440199a661slive <p>would match most common Internet graphics formats. In Apache 1.3
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">FilesMatch</directive> is preferred, however.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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 .htaccess files. This allows users to control access to their own
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive files, at a file-by-file level.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive explanation of how these different sections are combined when a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request is received</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Contains that directives that apply to regular-expression matched
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefilenames</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><FilesMatch <em>regex</em>> ... </FilesMatch></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive type="section">FilesMatch</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive provides for access control by filename, just as the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core" type="section">Files</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive does. However, it accepts a regular expression. For example:</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive <FilesMatch "\.(gif|jpe?g|png)$">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>would match most common Internet graphics formats.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive explanation of how these different sections are combined when a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request is received</seealso>
003f0c9fda6664daf5092a0e42f65ede20098153slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Forces all matching files to be served with the specified
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveMIME content-type</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>Moved to the core in Apache 2.0</compatibility>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When placed into an <code>.htaccess</code> file or a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Directory</directive>, or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Location</directive> or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Files</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section, this directive forces all matching files to be served
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive with the content type identification given by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>mime-type</em>. For example, if you had a directory full of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive GIF files, but did not want to label them all with ".gif", you
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive might want to use:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note that unlike <directive module="core">DefaultType</directive>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive this directive overrides all mime-type associations, including
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive filename extensions, that might identify the media type.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Enables DNS lookups on client IP addresses</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>This directive enables DNS lookups so that host names can be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive logged (and passed to CGIs/SSIs in <code>REMOTE_HOST</code>).
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The value <code>double</code> refers to doing double-reverse
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive DNS. That is, after a reverse lookup is performed, a forward
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive lookup is then performed on that result. At least one of the ip
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive addresses in the forward lookup must match the original
003f0c9fda6664daf5092a0e42f65ede20098153slive address. (In "tcpwrappers" terminology this is called
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Regardless of the setting, when <module>mod_access</module> is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive used for controlling access by hostname, a double reverse lookup
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive will be performed. This is necessary for security. Note that the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive result of this double-reverse isn't generally available unless you
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive set <code>HostnameLookups double</code>. For example, if only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>HostnameLookups on</code> and a request is made to an object
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that is protected by hostname restrictions, regardless of whether
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the double-reverse fails or not, CGIs will still be passed the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive single-reverse result in <code>REMOTE_HOST</code>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The default is off in order to save the network
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive traffic for those sites that don't truly need the reverse
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive lookups done. It is also better for the end users because they
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive don't have to suffer the extra latency that a lookup entails.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Heavily loaded sites should leave this directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>off</code>, since DNS lookups can take considerable
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive amounts of time. The utility <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/programs/logresolve.html">logresolve</a>, provided in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the <em>/support</em> directory, can be used to look up host
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive names from logged IP addresses offline.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Enables logging of the RFC1413 identity of the remote
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveuser</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive enables RFC1413-compliant logging of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive remote user name for each connection, where the client machine
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive runs identd or something similar. This information is logged in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the access log.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The information should not be trusted in any way except for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive rudimentary usage tracking.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note that this can cause serious latency problems accessing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive your server since every request requires one of these lookups
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to be performed. When firewalls are involved each lookup might
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive possibly fail and add 30 seconds of latency to each hit. So in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive general this is not very useful on public servers accessible
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive from the Internet.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Encloses directives that will be processed only
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveif a test is true at startup</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><IfDefine [!]<em>parameter-name</em>> <em>...</em>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </IfDefine></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>test</em>>...</IfDefine></code> section is used to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive mark directives that are conditional. The directives within an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section">IfDefine</directive> section are only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive processed if the <em>test</em> is true. If <em>test</em> is false,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive everything between the start and end markers is ignored.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">IfDefine</directive> section directive can be one
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive of two forms:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>In the former case, the directives between the start and end
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive markers are only processed if the parameter named
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>parameter-name</em> is defined. The second format reverses
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the test, and only processes the directives if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>parameter-name</em> is <strong>not</strong> defined.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <em>parameter-name</em> argument is a define as given on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>-D</code><em>parameter-</em>, at the time the server was
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive started.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">IfDefine</directive> sections are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive nest-able, which can be used to implement simple
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive multiple-parameter tests. Example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive $ httpd -DReverseProxy ...
003f0c9fda6664daf5092a0e42f65ede20098153slive <IfDefine ReverseProxy>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </IfDefine>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Encloses directives that are processed conditional on the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivepresence of absence of a specific module</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><IfModule [!]<em>module-name</em>> <em>...</em>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </IfModule></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>test</em>>...</IfModule></code> section is used to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive mark directives that are conditional. The directives within an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section">IfModule</directive> section are only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive processed if the <em>test</em> is true. If <em>test</em> is false,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive everything between the start and end markers is ignored.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">IfModule</directive> section directive can be one
003f0c9fda6664daf5092a0e42f65ede20098153slive of two forms:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>In the former case, the directives between the start and end
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive markers are only processed if the module named <em>module
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive name</em> is included in Apache -- either compiled in or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive >LoadModule</directive>. The second format
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive reverses the test, and only processes the directives if <em>module
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <em>module name</em> argument is the file name of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module, at the time it was compiled.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">IfModule</directive> sections are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive nest-able, which can be used to implement simple multiple-module
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Includes other configuration files from within
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivethe server configuration files</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>Include <em>file-path</em>|<em>directory-path</em></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive allows inclusion of other configuration files
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive from within the server configuration files.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If <directive>Include</directive> points to a directory, rather than a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive file, Apache will read all files in that directory, and any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive subdirectory, and parse those as configuration files.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The file path specified may be a fully qualified path (i.e.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive starting with a slash), or may be relative to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core">ServerRoot</directive> directory.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Or, providing paths relative to your <code>ServerRoot</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Make sure that an included directory does not contain any stray
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive files, such as editor temporary files, for example, as Apache will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive attempt to read them in and use the contents as configuration
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives, which may cause the server to fail on start up.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Running <code>apachectl configtest</code> will give you a list of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the files that are being processed during the configuration
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive root@host# apachectl configtest
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Processing config directory: /usr/local/apache/conf/vhosts
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Processing config file: /usr/local/apache/conf/vhosts/vhost1
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Processing config file: /usr/local/apache/conf/vhosts/vhost2
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This will help in verifying that you are getting only the files
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that you intended as part of your configuration.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/programs/apachectl.html">apachectl</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Turns on or off HTTP persistent connections.</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The Keep-Alive extension to HTTP/1.0 and the persistent
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive connection feature of HTTP/1.1 provide long-lived HTTP sessions
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive which allow multiple requests to be sent over the same TCP
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive connection. In some cases this has been shown to result in an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive almost 50% speedup in latency times for HTML documents with
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive many images. To enable Keep-Alive connections in Apache 1.2 and
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>For HTTP/1.0 clients, Keep-Alive connections will only be
003f0c9fda6664daf5092a0e42f65ede20098153slive used if they are specifically requested by a client. In
003f0c9fda6664daf5092a0e42f65ede20098153slive 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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive unless otherwise specified. If the client requests it, chunked
945f56c1362fcca53d0cc661986eaf219ea7e49dslive encoding will be used in order to send content of unknown
945f56c1362fcca53d0cc661986eaf219ea7e49dslive length over persistent connections.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">MaxKeepAliveRequests</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the amount of time the server will wait for subsequent
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliverequests on a persistent connection</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The number of seconds Apache will wait for a subsequent
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request before closing the connection. Once a request has been
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive received, the timeout value specified by the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core">Timeout</directive> directive applies.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Setting <directive>KeepAliveTimeout</directive> to a high value
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive may cause performance problems in heavily loaded servers. The
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive higher the timeout, the more server processes will be kept
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive occupied waiting on connections with idle clients.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Restrict access controls to only certain HTTP
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivemethods</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><Limit <em>method</em> [<em>method</em>] ... > ...
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Limit></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives should not be placed within a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section">limit</directive> section.</strong></p>
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
003f0c9fda6664daf5092a0e42f65ede20098153slive restrictions that are enclosed in the <code><Limit></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive bracket <strong>will have no effect</strong>. The following
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive example applies the access control only to the methods POST, PUT,
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele and DELETE, leaving all other methods unprotected:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require valid-user<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Limit></code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The method names listed can be one or more of: GET, POST, PUT,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive DELETE, CONNECT, OPTIONS, TRACE, PATCH, PROPFIND, PROPPATCH,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive MKCOL, COPY, MOVE, LOCK, and UNLOCK. <strong>The method name is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive case-sensitive.</strong> If GET is used it will also restrict
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive HEAD requests.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Restrict access controls to all HTTP methods
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveexcept the named ones</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><LimitExcept <em>method</em> [<em>method</em>] ... > ...
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </LimitExcept></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">LimitExcept</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code></LimitExcept></code> are used to enclose a group of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive access control directives which will then apply to any HTTP access
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive method <strong>not</strong> listed in the arguments; i.e., it is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">Limit</directive> section and can be used to control
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive both standard and nonstandard/unrecognized methods. See the
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele type="section">Limit</directive> for more details.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Restricts the total size of the HTTP request body sent
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefrom the client</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive specifies the number of <em>bytes</em> 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
003f0c9fda6664daf5092a0e42f65ede20098153slive constant <code>DEFAULT_LIMIT_REQUEST_BODY</code> (0 as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive distributed).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>LimitRequestBody</directive> directive allows
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the user to set a limit on the allowed size of an HTTP request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive message body within the context in which the directive is given
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive (server, per-directory, per-file or per-location). If the client
003f0c9fda6664daf5092a0e42f65ede20098153slive request exceeds that limit, the server will return an error
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive response instead of servicing the request. The size of a normal
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request message body will vary greatly depending on the nature of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the resource and the methods allowed on that resource. CGI scripts
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive typically use the message body for passing form information to the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server. Implementations of the PUT method will require a value at
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive least as large as any representation that the server wishes to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accept for that resource.</p>
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive attacks.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limits the number of HTTP request header fields that
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivewill be accepted from the client</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><em>Number</em> is an integer from 0 (meaning unlimited) to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 32767. The default value is defined by the compile-time
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive constant <code>DEFAULT_LIMIT_REQUEST_FIELDS</code> (100 as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive distributed).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>LimitRequestFields</directive> directive allows
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the server administrator to modify the limit on the number of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request header fields allowed in an HTTP request. A server needs
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive this value to be larger than the number of fields that a normal
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive client request might include. The number of request header fields
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive used by a client rarely exceeds 20, but this may vary among
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
003f0c9fda6664daf5092a0e42f65ede20098153slive using request header fields.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive gives the server administrator greater
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive control over abnormal client request behavior, which may be
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen useful for avoiding some forms of denial-of-service attacks.
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen The value should be increased if normal clients see an error
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen response from the server that indicates too many fields were
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen sent in the request.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<description>Limits the size of the HTTP request header allowed from the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowenclient</description>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<contextlist><context>server config</context></contextlist>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>This directive specifies the number of <em>bytes</em> from 0
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to the value of the compile-time constant
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive distributed) that will be allowed in an HTTP request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive header.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive greatly among different client implementations, often depending
003f0c9fda6664daf5092a0e42f65ede20098153slive upon the extent to which a user has configured their browser to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive support detailed content negotiation.</p>
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.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Under normal conditions, the value should not be changed from
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limit the size of the HTTP request line that will be accepted
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivefrom the client</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive sets the number of <em>bytes</em> from 0 to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the value of the compile-time constant
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>DEFAULT_LIMIT_REQUEST_LINE</code> (8190 as distributed)
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that will be allowed on the HTTP request-line.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>LimitRequestLine</directive> directive allows
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen the server administrator to reduce the limit on the allowed size
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen of a client's HTTP request-line below the normal input buffer size
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen compiled with the server. Since the request-line consists of the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen HTTP method, URI, and protocol version, the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <directive>LimitRequestLine</directive> directive places a
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen restriction on the length of a request-URI allowed for a request
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen on the server. A server needs this value to be large enough to
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen hold any of its resource names, including any information that
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen might be passed in the query part of a GET request.</p>
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.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Under normal conditions, the value should not be changed from
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limits the size of an XML-based request body</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Limit (in bytes) on maximum size of an XML-based request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive body. A value of <code>0</code> will disable any checking.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Applies the enclosed directives only to matching
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveURLs</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><Location
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>URL-path</em>|<em>URL</em>> ... </Location></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive type="section">Location</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive provides for access control by URL. It is similar to the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <directive type="section" module="core">Directory</directive>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen directive, and starts a subsection which is terminated with a
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen type="section">Location</directive> sections are processed in the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen order they appear in the configuration file, after the <directive
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen type="section" module="core">Directory</directive> sections and
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <code>.htaccess</code> files are read, and after the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section" module="core">Files</directive> sections.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note that URLs do not have to line up with the filesystem at
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive all, it should be emphasized that <Location> operates
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive completely outside the filesystem.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>For all origin (non-proxy) requests, the URL to be matched
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive is of the form <code>/path/</code>, and you should not include
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive any <code>http://servername</code> prefix. For proxy requests,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the URL to be matched is of the form
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>scheme://servername/path</code>, and you must include the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive prefix.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The URL may use wildcards In a wild-card string, `?' matches
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive any single character, and `*' matches any sequences of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive characters.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Extended regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expressions can also be used, with the addition of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Location ~ "/(extra|special)/data">
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>would match URLs that contained the substring "/extra/data" or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive "/special/data". In Apache 1.3 and above, a new directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">LocationMatch</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive exists which behaves identical to the regex version of
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>The <directive type="section">Location</directive>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen functionality is especially useful when combined with the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen directive. For example, to enable status requests, but allow them
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <Location /status><br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen SetHandler server-status<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Order Deny,Allow<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Deny from all<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Location>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<note><title>Note about / (slash)</title> <p>The slash character has
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivespecial meaning depending on where in a URL it appears. People may be
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveused to its behavior in the filesystem where multiple adjacent slashes
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveare frequently collapsed to a single slash (<em>i.e.</em>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<code>/home///foo</code> is the same as <code>/home/foo</code>). In
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveURL-space this is not necessarily true. The <directive type="section"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivemodule="core">LocationMatch</directive> directive and the regex
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveversion of <directive type="section">Location</directive> require you
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveto explicitly specify multiple slashes if that is your intention. For
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveexample, <code><LocationMatch ^/abc></code> would match the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivetype="section">Location</directive> directive behaves similarly when
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveused for proxy requests. But when (non-regex) <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivetype="section">Location</directive> is used for non-proxy requests it
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivewill implicitly match multiple slashes with a single slash. For
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveexample, if you specify <code><Location /abc/def></code> and the
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliverequest is to <code>/abc//def</code> then it will match.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive explanation of how these different sections are combined when a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive request is received</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<description>Applies the enclosed directives only to regular-expression
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowenmatching URLs</description>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<syntax><LocationMatch
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<contextlist><context>server config</context><context>virtual host</context>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen</contextlist>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>The <directive type="section">LocationMatch</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive provides for access control by URL, in an identical manner to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">Location</directive>. However, it takes a regular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive expression as an argument instead of a simple string. For
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <LocationMatch "/(extra|special)/data">
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele <p>would match URLs that contained the substring "/extra/data"
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen explanation of how these different sections are combined when a
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen request is received</seealso>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen</directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<description>Controls the verbosity of the ErrorLog</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive>LogLevel</directive> adjusts the verbosity of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive messages recorded in the error logs (see <directive
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen module="core">ErrorLog</directive> directive). The following
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive significance:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"getpwuid: couldn't determine user name from uid"</td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"socket: Failed to get a socket, exiting child"</td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"child process 1234 did not exit, sending another
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive SIGHUP"</td>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"httpd: caught SIGBUS, attempting to dump core in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <td>"Server seems busy, (you may need to increase
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When a particular level is specified, messages from all
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive other levels of higher significance will be reported as well.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>E.g.</em>, when <code>LogLevel info</code> is specified,
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen then messages with log levels of <code>notice</code> and
530eba85dbd41b8a0fa5255d3648d1440199a661slive recommended.</p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the number of requests allowed on a persistent
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveconnection</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>MaxKeepAliveRequests</directive> directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive limits the number of requests allowed per connection when
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core" >KeepAlive</directive> is on. If it is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive set to "<code>0</code>", unlimited requests will be allowed. We
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive recommend that this setting be kept to a high value for maximum
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server performance.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures an IP address for name-virtual
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivehosting</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>NameVirtualHost <em>addr</em>[:<em>port</em>]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>NameVirtualHost</directive> directive is a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive required directive if you want to configure <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Although <em>addr</em> can be hostname it is recommended
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>With the <directive>NameVirtualHost</directive> directive you
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specify the IP address on which the server will receive requests
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for the name-based virtual hosts. This will usually be the address
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to which your name-based virtual host names resolve. In cases
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive where a firewall or other proxy receives the requests and forwards
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive them on a different IP address to the server, you must specify the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive IP address of the physical interface on the machine which will be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive servicing the requests. If you have multiple name-based hosts on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive multiple addresses, repeat the directive for each address.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note: the "main server" and any _default_ servers will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive>NameVirtualHost</directive> IP Address (unless for some
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive reason you specify <directive>NameVirtualHost</directive> but then
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive don't define any VirtualHosts for that address).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Optionally you can specify a port number on which the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive name-based virtual hosts should be used, <em>e.g.</em></p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>IPv6 addresses must be enclosed in square brackets, as shown
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive in the following example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<example>NameVirtualHost [fe80::a00:20ff:fea7:ccea]:8080</example>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures what features are available in a particular
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivedirectory</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>Options
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive [+|-]<em>option</em> [[+|-]<em>option</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p>The <directive>Options</directive> directive controls which
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen server features are available in a particular directory.</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <p><em>option</em> can be set to <code>None</code>, in which
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen case none of the extra features are enabled, or one or more of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the following:</p>
003f0c9fda6664daf5092a0e42f65ede20098153slive <dd>All options except for MultiViews. This is the default
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive setting.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Execution of CGI scripts is permitted.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive The server will follow symbolic links in this directory.<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <strong>Note</strong>: even though the server follows the
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen symlink it does <em>not</em> change the pathname used to match
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen <strong>Note</strong>: this option gets ignored if set inside a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Location</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Server-side includes are permitted.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Server-side includes are permitted, but the #exec command and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive #exec CGI are disabled. It is still possible to #include
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive virtual CGI scripts from ScriptAliase'd directories.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive If a URL which maps to a directory is requested, and the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive there is no DirectoryIndex (<em>e.g.</em>, index.html) in
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that directory, then the server will return a formatted
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive listing of the directory.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <a href="/content-negotiation.html">Content negotiated</a>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive MultiViews are allowed.</dd>
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a <directive module="core" type="section">Location</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section.</dd>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Normally, if multiple <directive>Options</directive> could apply to a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory, then the most specific one is taken complete; the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive options are not merged. However if <em>all</em> the options on
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the <directive>Options</directive> directive are preceded by a + or -
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive symbol, the options are merged. Any options preceded by a + are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive added to the options currently in force, and any options
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen preceded by a - are removed from the options currently in
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen force. </p>
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen Options Indexes FollowSymLinks<br />
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen </Directory><br />
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen Options Includes<br />
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen </Directory>
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen <p>then only <code>Includes</code> will be set for the
52bb691f8e13e9d0b55fcc214018ee85846fa87frbowen <directive>Options</directive> directive uses the + and - symbols:</p>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen Options Indexes FollowSymLinks<br />
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen </Directory><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Options +Includes -Indexes<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Directory>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Includes</code> are set for the /web/docs/spec directory.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><strong>Note:</strong> Using <code>-IncludesNOEXEC</code> or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>-Includes</code> disables server-side includes completely
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive regardless of the previous setting.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The default in the absence of any other settings is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Selects which authenticated users can access
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivea resource</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>Require <em>entity-name</em> [<em>entity-name</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This directive selects which authenticated users can access
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive a directory. The allowed syntaxes are:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require group <em>group-name</em> [<em>group-name</em>] ...
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Only users in the named groups can access the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require valid-user
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_auth">AuthUserFile</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive and <directive module="mod_auth">AuthGroupFile</directive> (to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive define users and groups) in order to work correctly. Example:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AuthType Basic<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive AuthName "Restricted Directory"<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Require group admin<br />
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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core" type="section">Limit</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">Satisfy</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limits the CPU consumption of processes launched
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveby Apache children</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>RLimitCPU <em>number</em>|max [<em>number</em>|max]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<default>Unset; uses operating system defaults</default>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist>><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>Moved in version 2.0 to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Takes 1 or 2 parameters. The first parameter sets the soft
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive resource limit for all processes and the second parameter sets
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the maximum resource limit. Either parameter can be a number,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or <em>max</em> to indicate to the server that the limit should
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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 root, or in the initial startup
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive processes forked off from the Apache parent such as piped
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>CPU resource limits are expressed in seconds per
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive process.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitMEM</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitNPROC</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limits the memory consumption of processes launched
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveby Apache children</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>RLimitMEM <em>number</em>|max [<em>number</em>|max]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<default>Unset; uses operating system defaults</default>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Takes 1 or 2 parameters. The first parameter sets the soft
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive resource limit for all processes and the second parameter sets
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the maximum resource limit. Either parameter can be a number,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or <em>max</em> to indicate to the server that the limit should
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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 root, or in the initial startup
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive processes forked off from the Apache parent such as piped
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Memory resource limits are expressed in bytes per
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive process.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitCPU</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitNPROC</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Limits the number of processes that can be launched by
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveprocesses launched by Apache children</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>RLimitNPROC <em>number</em>|max [<em>number</em>|max]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<default>Unset; uses operating system defaults</default>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Takes 1 or 2 parameters. The first parameter sets the soft
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive resource limit for all processes and the second parameter sets
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the maximum resource limit. Either parameter can be a number,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive or <code>max</code> to indicate to the server that the limit
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive 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 root, or in the initial startup
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive processes forked off from the Apache parent such as piped
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Process limits control the number of processes per user.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Note: If CGI processes are <strong>not</strong> running
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive under userids other than the web server userid, this directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive will limit the number of processes that the server itself can
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive create. Evidence of this situation will be indicated by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive error_log.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitMEM</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">RLimitCPU</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures how host-level access control and user authentication
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveinteract</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">Require</directive> used. The parameter can be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive either <em>'all'</em> or <em>'any'</em>. This directive is only
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive useful if access to a particular area is being restricted by both
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive username/password <em>and</em> client host address. In this case
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the default behavior ("all") is to require that the client passes
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the address access restriction <em>and</em> enters a valid
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive username and password. With the "any" option the client will be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive granted access if they either pass the host restriction or enter a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive valid username and password. This can be used to password restrict
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive an area, but to let clients from particular addresses in without
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive prompting for a password.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Controls how the interpreter for CGI scripts is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivelocated</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>ScriptInterpreterSource registry|script</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
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 #! line in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive script. Setting <code>ScriptInterpreterSource registry</code> will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive cause the Windows Registry to be searched using the script file
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the email address that the server includes in error
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivemessages sent to the client</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
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 <p>It may be worth setting up a dedicated address for this,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>as users do not always mention that they are talking about the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server!</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets alternate names for a host used when matching requests
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveto name-virtual hosts</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>ServerAlias <em>hostname</em> [<em>hostname</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>virtual host</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>ServerAlias</directive> directive sets the
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele alternate names for a host, for use with <a
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele href="/vhosts/name-based.html">name-based virtual hosts</a>.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <VirtualHost *><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </VirtualHost>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/vhosts/">Apache Virtual Host documentation</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the hostname and port that the server uses to identify
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveitself</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>ServerName <em>fully-qualified-domain-name[:port]</em></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>In version 2.0, this
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive supersedes the functionality of the <directive>Port</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive from version 1.3.</compatibility>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>ServerName</directive> directive sets the hostname and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive port that the server uses to identify itself. This is used when
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive creating redirection URLs. For example, if the name of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive machine hosting the webserver is <code>simple.example.com</code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive but the machine also has the DNS alias <code>www.example.com</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive and you wish the webserver to be so identified, the following
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive should be used:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If no <directive>ServerName</directive> is specified, then the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server attempts to deduce the hostname by performing a reverse
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive lookup on the IP address. If no port is specified in the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive servername, then the server will use the port from the incoming
003f0c9fda6664daf5092a0e42f65ede20098153slive request. For optimal reliability and predictability, you should
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specify an explicit hostname and port using the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/vhosts/name-based.html">name-based virtual hosts</a>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">VirtualHost</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section specifies what hostname must appear in the request's
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>Host:</code> header to match this virtual host.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>See the description of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="core">UseCanonicalName</directive> directive for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive settings which determine whether self-referential URL's (e.g., by the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive specified port, or to the port number given in the client's request.
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<seealso><a href="/dns-caveats.html">DNS Issues</a></seealso>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<seealso><directive module="core">UseCanonicalName</directive></seealso>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<seealso><directive module="core">NameVirtualHost</directive></seealso>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<seealso><directive module="core">ServerAlias</directive></seealso>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen</directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<directivesynopsis>
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowen<description>Sets the legacy URL pathname for a name-virtual host that
d3f27ec18dfa6283e852aa98253212edafaa0e2brbowenis accessed by an incompatible browser</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>virtual host</context></contextlist>
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>The <directive>ServerPath</directive> directive sets the legacy
003f0c9fda6664daf5092a0e42f65ede20098153slive URL pathname for a host, for use with <a
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele<seealso><a href="/vhosts/">Apache Virtual Host documentation</a></seealso>
18b4b0fd6056093002ddef488636bf5ebe415ef0erikabele</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the base directory for the server installation</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>ServerRoot</directive> directive sets the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory in which the server lives. Typically it will contain the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive subdirectories <code>conf/</code> and <code>logs/</code>. Relative
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive paths for other configuration files are taken as relative to this
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/misc/security_tips.html#serverroot">the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive security tips</a> for information on how to properly set
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive permissions on the ServerRoot</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures the footer on server-generated documents</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>ServerSignature</directive> directive allows the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive configuration of a trailing footer line under server-generated
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive documents (error messages, mod_proxy ftp directory listings,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive mod_info output, ...). The reason why you would want to enable
003f0c9fda6664daf5092a0e42f65ede20098153slive such a footer line is that in a chain of proxies, the user often
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive has no possibility to tell which of the chained servers actually
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive produced a returned error message.<br /> The <samp>Off</samp>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive setting, which is the default, suppresses the error line (and is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive therefore compatible with the behavior of Apache-1.2 and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive below). The <samp>On</samp> setting simply adds a line with the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive server version number and <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">ServerName</directive> of the serving virtual host,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive and the <samp>EMail</samp> setting additionally creates a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive "mailto:" reference to the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">ServerAdmin</directive> of the referenced
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive document.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Configures the Server HTTP response header</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>ServerTokens Minimal|ProductOnly|OS|Full</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
003f0c9fda6664daf5092a0e42f65ede20098153slive <p>This directive controls whether <samp>Server</samp> response
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive header field which is sent back to clients includes a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive description of the generic OS-type of the server as well as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive information about compiled-in modules.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>Server sends (<em>e.g.</em>): <samp>Server: Apache/1.3.0
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dt><code>ServerTokens Full</code> (or not specified)</dt>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <dd>Server sends (<em>e.g.</em>): <samp>Server: Apache/1.3.0
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>This setting applies to the entire server, and cannot be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive enabled or disabled on a virtualhost-by-virtualhost basis.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Forces all matching files to be processed by a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivehandler</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<compatibility>Moved into the core in Apache 2.0</compatibility>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>When placed into an <code>.htaccess</code> file or a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Directory</directive> or
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive type="section" module="core">Location</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section, this directive forces all matching files to be parsed
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive through the <a href="/handler.html">handler</a> given by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>handler-name</em>. For example, if you had a directory you
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive wanted to be parsed entirely as imagemap rule files, regardless
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive of extension, you might put the following into an
003f0c9fda6664daf5092a0e42f65ede20098153slive SetHandler imap-file
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Another example: if you wanted to have the server display a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive status report whenever a URL of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>http://servername/status</code> was called, you might put
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <Location /status><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive SetHandler server-status<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </Location>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
003f0c9fda6664daf5092a0e42f65ede20098153slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the filters that will process client requests and POST
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveinput</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>SetInputFilter <em>filter</em>[<em>;filter</em>...]</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>SetInputFilter</directive> directive sets the
58e56a1d61ae176cc5ecb7c4863881736947d8b8rbowen filter or filters which will process client requests and POST
58e56a1d61ae176cc5ecb7c4863881736947d8b8rbowen input when they are received by the server. This is in addition to
58e56a1d61ae176cc5ecb7c4863881736947d8b8rbowen any filters defined elsewhere, including the
58e56a1d61ae176cc5ecb7c4863881736947d8b8rbowen <directive module="mod_mime">AddInputFilter</directive>
58e56a1d61ae176cc5ecb7c4863881736947d8b8rbowen directive.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If more than one filter is specified, they must be separated
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive by semicolons in the order in which they should process the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive content.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/filter.html">Filters</a> documentation</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Sets the filters that will process responses from the
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveserver</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax>SetOutputFilter <em>filter</em> [<em>filter</em>] ...</syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>SetOutputFilter</directive> directive sets the filters
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive which will process responses from the server before they are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive sent to the client. This is in addition to any filters defined
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive elsewhere, including the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive module="mod_mime">AddOutputFilter</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive.</p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive <p>For example, the following configuration will process all files
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive in the <code>/www/data/</code> directory for server-side
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive includes.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive SetOutputFilter INCLUDES<br />
530eba85dbd41b8a0fa5255d3648d1440199a661slive</Directory>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>If more than one filter is specified, they must be separated
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive by semicolons in the order in which they should process the
f35c904c3b359610a46e94fbb4ba8495b2338521slive content.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/filter.html">Filters</a> documentation</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Defines the amount of time the server will wait for
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivecertain events before failing a request</description>
530eba85dbd41b8a0fa5255d3648d1440199a661slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The <directive>TimeOut</directive> directive currently defines
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the amount of time Apache will wait for three things:</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>The total amount of time it takes to receive a GET
530eba85dbd41b8a0fa5255d3648d1440199a661slive request.</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>The amount of time between receipt of TCP packets on a
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianh POST or PUT request.</li>
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianh <li>The amount of time between ACKs on transmissions of TCP
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianh packets in responses.</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>We plan on making these separately configurable at some point
530eba85dbd41b8a0fa5255d3648d1440199a661slive down the road. The timer used to default to 1200 before 1.2,
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianh but has been lowered to 300 which is still far more than
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive necessary in most situations. It is not set any lower by
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive default because there may still be odd places in the code where
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the timer is not reset when a packet is sent. </p>
530eba85dbd41b8a0fa5255d3648d1440199a661slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<directivesynopsis>
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianh<description>Configures how the server determines its own name and
1a1cf0ee9229ee29e5750b25dd94dbb9b04072cfianhport</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context><context>virtual host</context>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<context>directory</context><context>.htaccess</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>In many situations Apache has to construct a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>self-referential</em> URL. That is, a URL which refers back to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive the same server. With <code>UseCanonicalName on</code> Apache will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive use the hostname and port specified in the <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive module="core">ServerName</directive> directive to construct a canonical
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive name for the server. This name is used in all self-referential
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive URLs, and for the values of <code>SERVER_NAME</code> and
003f0c9fda6664daf5092a0e42f65ede20098153slive <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). These values are the same that are used to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive implement <a href="/vhosts/name-based.html">name based
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive virtual hosts</a>, and are available with the same clients. The
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>SERVER_PORT</code> will be constructed from the client
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive supplied values as well.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>An example where this may be useful is on an intranet server
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive where you have users connecting to the machine using short
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive names such as <code>www</code>. You'll notice that if the users
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type a shortname, and a URL which is a directory, such as
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>http://www/splat</code>, <em>without the trailing
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive slash</em> then Apache will redirect them to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>http://www.domain.com/splat/</code>. If you have
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive authentication enabled, this will cause the user to have to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive reauthenticate twice (once for <code>www</code> and once again
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <directive>UseCanonicalName</directive> is set off, then Apache will
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>There is a third option, <code>UseCanonicalName DNS</code>,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive which is intended for use with mass IP-based virtual hosting to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive support ancient clients that do not provide a
db1b819ff8966e3c6a5ca03c59a8ae06c2cecc9frbowen <code>Host:</code> header. With this option Apache does a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive reverse DNS lookup on the server IP address that the client
db1b819ff8966e3c6a5ca03c59a8ae06c2cecc9frbowen connected to in order to work out self-referential URLs.</p>
db1b819ff8966e3c6a5ca03c59a8ae06c2cecc9frbowen <p><strong>Warning:</strong> if CGIs make assumptions about the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive values of <code>SERVER_NAME</code> they may be broken by this
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive option. The client is essentially free to give whatever value
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive they want as a hostname. But if the CGI is only using
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code>SERVER_NAME</code> to construct self-referential URLs
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive then it should be just fine.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="core">ServerName</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><directive module="mpm_common">Listen</directive></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<description>Contains directives that apply only to a specific
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivehostname or IP address</description>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<syntax><VirtualHost
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <em>addr</em>[:<em>port</em>] [<em>addr</em>[:<em>port</em>]]
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ...> ... </VirtualHost></syntax>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<contextlist><context>server config</context></contextlist>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p><directive type="section">VirtualHost</directive> and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <code></VirtualHost></code> are used to enclose a group of
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directives which will apply only to a particular virtual host. Any
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directive which is allowed in a virtual host context may be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive used. When the server receives a request for a document on a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive particular virtual host, it uses the configuration directives
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive enclosed in the <directive type="section">VirtualHost</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <li>A fully qualified domain name for the IP address of the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive virtual host.</li>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ServerAdmin webmaster@host.foo.com<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </VirtualHost>
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<VirtualHost [fe80::a00:20ff:fea7:ccea]><br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive ServerAdmin webmaster@host.foo.com<br />
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive </VirtualHost>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>Each Virtual Host must correspond to a different IP address,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive different port number or a different host name for the server,
003f0c9fda6664daf5092a0e42f65ede20098153slive in the former case the server machine must be configured to
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accept IP packets for multiple addresses. (If the machine does
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive not have multiple network interfaces, then this can be
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive accomplished with the <code>ifconfig alias</code> command (if
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive your OS supports it), or with kernel patches like <a
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/misc/vif-info.html">VIF</a> (for SunOS(TM) 4.1.x)).</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>The special name <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
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive of any _default_ virtual host the "main" server config,
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive consisting of all those definitions outside any VirtualHost
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive section, is used when no match occurs.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive <p>You can specify a <code>:port</code> to change the port that is
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive matched. If unspecified then it defaults to the same port as the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive most recent <directive module="mpm_common">Listen</directive>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive statement of the main server. You may also specify <code>:*</code>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive to match all ports on that address. (This is recommended when used
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive href="/misc/security_tips.html">security tips</a> document
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive for details on why your security could be compromised if the
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive directory where logfiles are stored is writable by anyone other
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive than the user that starts the server.</p>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive type="section">VirtualHost</directive> does <strong>not</strong>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive affect what addresses Apache listens on. You may need to ensure
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive that Apache is listening on the correct addresses using <directive
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/vhosts/">Apache Virtual Host documentation</a></seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<seealso><a href="/dns-caveats.html">Warnings about DNS and
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Directory, Location and Files sections work</a> for an
a4f0a07c34d36900a90452e82ff3b4fd110a537bslive explanation of how these different sections are combined when a
a4f0a07c34d36900a90452e82ff3b4fd110a537bslive request is received</seealso>
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</directivesynopsis>
3c6c63407f1855ddfc45ac69b69a2a9bf15135e6rbowen</modulesynopsis>