core.html revision 26f9d93a2b80cc42b45fbefa149895d444397c5a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <meta name="generator" content="HTML Tidy, see www.w3.org" />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <!-- Background white, links blue (unvisited), navy (visited), red (active) -->
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <body bgcolor="#FFFFFF" text="#000000" link="#0000FF"
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <!--#include virtual="header.html" -->
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>These configuration parameters control the core Apache
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock features, and are always available.</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#acceptpathinfo">AcceptPathInfo</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#accessfilename">AccessFileName</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#adddefaultcharset">AddDefaultCharset</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#allowoverride">AllowOverride</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#clearmodulelist">ClearModuleList</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#contentdigest">ContentDigest</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#coredumpdirectory">CoreDumpDirectory</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#directory"><Directory></a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#directorymatch"><DirectoryMatch></a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#errordocument">ErrorDocument</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#filesmatch"><FilesMatch></a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#hostnamelookups">HostnameLookups</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#identitycheck">IdentityCheck</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#keepalivetimeout">KeepAliveTimeout</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#limitexcept"><LimitExcept></a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#limitrequestbody">LimitRequestBody</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#limitrequestfields">LimitRequestFields</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock href="#limitrequestfieldsize">LimitRequestFieldsize</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#limitrequestline">LimitRequestLine</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="#limitxmlrequestbody">LimitXMLRequestBody</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#locationmatch"><LocationMatch></a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="#maxkeepaliverequests">MaxKeepAliveRequests</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#namevirtualhost">NameVirtualHost</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="#scriptinterpretersource">ScriptInterpreterSource</a></li>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li><a href="#serversignature">ServerSignature</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#setinputfilter">SetInputFilter</a></li>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li><a href="#setoutputfilter">SetOutputFilter</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#usecanonicalname">UseCanonicalName</a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li><a href="#virtualhost"><VirtualHost></a></li>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock name="adddefaultcharset">AcceptPathInfo directive</a></h2>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> AcceptPathInfo On|Off|Default<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Context:</strong></a> server config, virtual host,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock directory, .htaccess<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock AcceptPathInfo is only available in Apache 2.0.30 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>This directive controls whether requests that contain trailing
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock pathname information that follows an actual filename (or
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock non-existent file in an existing directory) will be accepted or
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rejected. The trailing pathname information can be made
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock available to scripts in the PATH_INFO environment variable.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>For example, assume the location <code>/test/</code> points to
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock a directory that contains only the single file
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock <p>The three possible arguments for the
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock <dt><code>off</code></dt><dd>A request will only be accepted if it
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock maps to a literal path that exists. Therefore a request with
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock trailing pathname information after the true filename such as
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock <code>/test/here.html/more</code> in the above example will return
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock a 404 NOT FOUND error.</dd>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <dt><code>on</code></dt><dd>A request will be accepted if a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock leading path component maps to a file that exists. The above
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock example <code>/test/here.html/more</code> will be accepted if
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <code>/test/here.html</code> maps to a valid file.</dt>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <dt><code>default</code><dd>The treatment of requests with
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock trailing pathname information is determined by the <a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="/handler.html">handler</a> responsible for the request.
990b4856d0eaada6f8140335733a1b1771ed2746lling The core handler for normal files defaults to rejecting PATH_INFO.
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Handlers that serve scripts, such as <a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="mod_isapi.html">isapi-isa</a>, generally accept PATH_INFO by
990b4856d0eaada6f8140335733a1b1771ed2746lling default.</dd>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>The primary purpose of the <code>AcceptPathInfo</code>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock directive is to allow you to override the handler's choice of
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock accepting or rejecting PATH_INFO. This override is required, for
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock example, when you use a <a href="/filter.html">filter</a>, such
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock as <a href="mod_include.html">INCLUDES</a>, to generate content
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock based on PATH_INFO. The core handler would usually reject the
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock request, so you can use the following configuration to enable
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock such a script:</p>
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock<Files "mypaths.shtml">
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Options +Includes
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock SetOutputFilter INCLUDES
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock AcceptPathInfo on
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock</Files>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <h2><a id="accessfilename" name="accessfilename">AccessFileName
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> AccessFileName
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Default:</strong></a> <code>AccessFileName
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Compatibility:</strong></a> AccessFileName
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock can accept more than one filename only in Apache 1.3 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>When returning a document to the client the server looks for
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock the first existing access control file from this list of names
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock in every directory of the path to the document, if access
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock control files are enabled for that directory. For example:</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <blockquote>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock </blockquote>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock before returning the document /usr/local/web/index.html, the
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock server will read /.acl, /usr/.acl, /usr/local/.acl and
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock /usr/local/web/.acl for directives, unless they have been
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock disabled with
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <blockquote>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock AllowOverride None<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock </Directory></code>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock </blockquote>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock name="adddefaultcharset">AddDefaultCharset directive</a></h2>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> AddDefaultCharset
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock AddDefaultCharset is only available in Apache 1.3.12 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>This directive specifies the name of the character set that
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock will be added to any response that does not have any parameter
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock on the content type in the HTTP headers. This will override any
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock character set specified in the body of the document via a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <code>META</code> tag. A setting of <code>AddDefaultCharset
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Off</code> disables this functionality. <code>AddDefaultCharset
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock On</code> enables Apache's internal default charset of
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <code>iso-8859-1</code> as required by the directive. You can
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock also specify an alternate <em>charset</em> to be used; e.g.
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Context:</strong></a> server config <br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Compatibility:</strong></a> AddModule is
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock only available in Apache 1.2 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>The server can have modules compiled in which are not
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock actively in use. This directive can be used to enable the use
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock of those modules. The server comes with a pre-loaded list of
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock active modules; this list can be cleared with the <a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="#clearmodulelist">ClearModuleList</a> directive.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <h2><a id="allowoverride" name="allowoverride">AllowOverride
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> AllowOverride
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock All|None|<em>directive-type</em> [<em>directive-type</em>]
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Default:</strong></a> <code>AllowOverride
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Context:</strong></a> directory<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>When the server finds an .htaccess file (as specified by <a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="#accessfilename">AccessFileName</a>) it needs to know
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock which directives declared in that file can override earlier
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock access information.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>When this directive is set to <code>None</code>, then
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock .htaccess files are completely ignored. In this case, the
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock server will not even attempt to read .htaccess files in the
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock filesystem.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>When this directive is set to <code>All</code>, then any
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock directive which has the .htaccess <a
51ece83525fa18f5e72627610f480dffc7e492fdeschrock href="directive-dict.html#Context">Context</a> is allowed in
51ece83525fa18f5e72627610f480dffc7e492fdeschrock .htaccess files.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>The <em>directive-type</em> can be one of the following
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock groupings of directives.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Allow use of the authorization directives (<a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="mod_auth_dbm.html#authdbmgroupfile">AuthDBMGroupFile</a>,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="mod_auth_dbm.html#authdbmuserfile">AuthDBMUserFile</a>,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <a href="mod_auth.html#authgroupfile">AuthGroupFile</a>, <a
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock href="mod_auth.html#authuserfile">AuthUserFile</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Allow use of the directives controlling document types (<a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_negotiation.html#languagepriority">LanguagePriority</a>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="#setoutputfilter">SetOutputFilter</a>, and <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_mime.html">mod_mime Add* and Remove*
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Allow use of the directives controlling directory indexing
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#adddescription">AddDescription</a>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <a href="mod_autoindex.html#addicon">AddIcon</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#addiconbyencoding">AddIconByEncoding</a>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <a href="mod_autoindex.html#addiconbytype">AddIconByType</a>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <a href="mod_autoindex.html#defaulticon">DefaultIcon</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_dir.html#directoryindex">DirectoryIndex</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#fancyindexing">FancyIndexing</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#headername">HeaderName</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#indexignore">IndexIgnore</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#indexoptions">IndexOptions</a>, <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_autoindex.html#readmename">ReadmeName</a>,
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock Allow use of the directives controlling host access (Allow,
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock Deny and Order).</dd>
0430f8daa551890e0788d3fd28aef3be44cf8730eschrock Allow use of the directives controlling specific directory
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock href="mod_include.html#xbithack">XBitHack</a>).</dd>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> directory,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock .htaccess<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Override:</strong></a> AuthConfig<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>This directive sets the name of the authorization realm for
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock a directory. This realm is given to the client so that the user
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock knows which username and password to send.
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <samp>AuthName</samp> takes a single argument; if the realm
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock name contains spaces, it must be enclosed in quotation marks.
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock It must be accompanied by <a href="#authtype">AuthType</a> and
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <a href="#require">Require</a> directives, and directives such
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock as <a href="mod_auth.html#authuserfile">AuthUserFile</a> and <a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock href="mod_auth.html#authgroupfile">AuthGroupFile</a> to
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Basic|Digest<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> directory,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock .htaccess<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Override:</strong></a> AuthConfig<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>This directive selects the type of user authentication for a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock directory. Only <code>Basic</code> and <code>Digest</code> are
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock currently implemented.
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock It must be accompanied by <a href="#authname">AuthName</a> and
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <a href="#require">Require</a> directives, and directives such
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock as <a href="mod_auth.html#authuserfile">AuthUserFile</a> and <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="mod_auth.html#authgroupfile">AuthGroupFile</a> to
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock name="clearmodulelist">ClearModuleList directive</a></h2>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Syntax:</strong></a> ClearModuleList<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> server config<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Compatibility:</strong></a> ClearModuleList
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock is only available in Apache 1.2 and later
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>The server comes with a built-in list of active modules.
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock This directive clears the list. It is assumed that the list
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock will then be re-populated using the <a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <h2><a id="contentdigest" name="contentdigest">ContentDigest
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Syntax:</strong></a> ContentDigest
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock on|off<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Default:</strong></a> <code>ContentDigest
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock host, directory, .htaccess<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Override:</strong></a> Options<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Status:</strong></a> experimental<br />
51ece83525fa18f5e72627610f480dffc7e492fdeschrock rel="Help"><strong>Compatibility:</strong></a> ContentDigest is
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock only available in Apache 1.1 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>This directive enables the generation of
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <code>Content-MD5</code> headers as defined in RFC1864
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock respectively RFC2068.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>MD5 is an algorithm for computing a "message digest"
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock (sometimes called "fingerprint") of arbitrary-length data, with
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock a high degree of confidence that any alterations in the data
51ece83525fa18f5e72627610f480dffc7e492fdeschrock will be reflected in alterations in the message digest.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>The <code>Content-MD5</code> header provides an end-to-end
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock message integrity check (MIC) of the entity-body. A proxy or
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock client may check this header for detecting accidental
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock modification of the entity-body in transit. Example header:</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <p>Note that this can cause performance problems on your server
51ece83525fa18f5e72627610f480dffc7e492fdeschrock since the message digest is computed on every request (the
51ece83525fa18f5e72627610f480dffc7e492fdeschrock values are not cached).</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p><code>Content-MD5</code> is only sent for documents served
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock by the core, and not by any module. For example, SSI documents,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock output from CGI scripts, and byte range responses do not have
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock this header.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <h2><a id="defaulttype" name="defaulttype">DefaultType
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Syntax:</strong></a> DefaultType
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Default:</strong></a> <code>DefaultType
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock host, directory, .htaccess<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Override:</strong></a> FileInfo<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>There will be times when the server is asked to provide a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock document whose type cannot be determined by its MIME types
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock mappings.</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>The server must inform the client of the content-type of the
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock document, so in the event of an unknown type it uses the
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <blockquote>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock </blockquote>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock would be appropriate for a directory which contained many gif
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock images with filenames missing the .gif extension.
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <p>Note that unlike <a href="#forcetype">ForceType</a>, this
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock directive is only provides the default mime-type. All other
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock mime-type definitions, including filename extensions, that
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock might identify the media type will override this default.</p>
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock <h2><a id="directory" name="directory"><Directory>
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock rel="Help"><strong>Syntax:</strong></a> <Directory
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock <em>directory-path</em>> ... </Directory> <br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
b87f3af36bb994656da117319f5129ddfd05ed21perrin <p><Directory> and </Directory> are used to enclose
b87f3af36bb994656da117319f5129ddfd05ed21perrin a group of directives which will apply only to the named
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock directory and sub-directories of that directory. Any directive
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock which is allowed in a directory context may be used.
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock <em>Directory-path</em> is either the full path to a directory,
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock or a wild-card string. In a wild-card string, `?' matches any
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock single character, and `*' matches any sequences of characters.
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock As of Apache 1.3, you may also use `[]' character ranges like
c5904d138f3bdf0762dbf452a43d5a5c387ea6a8eschrock in the shell. Also as of Apache 1.3 none of the wildcards match
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock a `/' character, which more closely mimics the behavior of Unix
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock shells. Example:</p>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock Options Indexes FollowSymLinks
51ece83525fa18f5e72627610f480dffc7e492fdeschrock </Directory>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <p><strong>Apache 1.2 and above:</strong> Extended regular
51ece83525fa18f5e72627610f480dffc7e492fdeschrock expressions can also be used, with the addition of the
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek <Directory ~ "^/www/.*/[0-9]{3}">
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock would match directories in /www/ that consisted of three
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>If multiple (non-regular expression) directory sections
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock match the directory (or its parents) containing a document,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock then the directives are applied in the order of shortest match
51ece83525fa18f5e72627610f480dffc7e492fdeschrock first, interspersed with the directives from the <a
51ece83525fa18f5e72627610f480dffc7e492fdeschrock href="#accessfilename">.htaccess</a> files. For example,
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <blockquote>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock AllowOverride None<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock </Directory><br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <Directory /home/*><br />
51ece83525fa18f5e72627610f480dffc7e492fdeschrock AllowOverride FileInfo<br />
51ece83525fa18f5e72627610f480dffc7e492fdeschrock </Directory></code>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock </blockquote>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock for access to the document <code>/home/web/dir/doc.html</code>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock the steps are:
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li>Apply directive <code>AllowOverride None</code>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <li>Apply directive <code>AllowOverride FileInfo</code> (for
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <li>Apply any FileInfo directives in
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <p>Regular expression directory sections are handled slightly
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek differently by Apache 1.2 and 1.3. In Apache 1.2 they are
51ece83525fa18f5e72627610f480dffc7e492fdeschrock interspersed with the normal directory sections and applied in
51ece83525fa18f5e72627610f480dffc7e492fdeschrock the order they appear in the configuration file. They are
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek applied only once, and apply when the shortest match possible
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek occurs. In Apache 1.3 regular expressions are not considered
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek until after all of the normal sections have been applied. Then
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek all of the regular expressions are tested in the order they
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek appeared in the configuration file. For example, with</p>
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek <blockquote>
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek ... directives here ...<br />
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek </Directory><br />
32b87932f3ef0887d873b7f6d2d1943799b2afc0ek </blockquote>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock Suppose that the filename being accessed is
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <code>/home/abc/public_html/abc/index.html</code>. The server
51ece83525fa18f5e72627610f480dffc7e492fdeschrock considers each of <code>/</code>, <code>/home</code>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <code>/home/abc</code>, <code>/home/abc/public_html</code>, and
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <code>/home/abc/public_html/abc</code> in that order. In Apache
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock 1.2, when <code>/home/abc</code> is considered, the regular
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock expression will match and be applied. In Apache 1.3 the regular
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock expression isn't considered at all at that point in the tree.
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock It won't be considered until after all normal
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <Directory>s and <code>.htaccess</code> files have been
51ece83525fa18f5e72627610f480dffc7e492fdeschrock applied. Then the regular expression will match on
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <code>/home/abc/public_html/abc</code> and be applied.
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <Directory /> is <samp>Allow from All</samp>. This means
51ece83525fa18f5e72627610f480dffc7e492fdeschrock that Apache will serve any file mapped from an URL. It is
51ece83525fa18f5e72627610f480dffc7e492fdeschrock recommended that you change this with a block such
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <Directory />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Order Deny,Allow
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Deny from All
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock </Directory>
51ece83525fa18f5e72627610f480dffc7e492fdeschrock <p><strong>and then override this for directories you
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="/misc/security_tips.html">Security Tips</a> page for
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock The directory sections typically occur in the access.conf file,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock but they may appear in any configuration file.
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <Directory> directives cannot nest, and cannot appear in
51ece83525fa18f5e72627610f480dffc7e492fdeschrock href="#limitexcept"><LimitExcept></a> section.
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p><strong>See also</strong>: <a href="/sections.html">How
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock Directory, Location and Files sections work</a> for an
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock explanation of how these different sections are combined when a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock request is received</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock name="directorymatch"><DirectoryMatch></a></h2>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> <DirectoryMatch
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <em>regex</em>> ... </DirectoryMatch> <br />
51ece83525fa18f5e72627610f480dffc7e492fdeschrock rel="Help"><strong>Context:</strong></a> server config, virtual
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Status:</strong></a> Core.<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Compatibility:</strong></a> Available in
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Apache 1.3 and later
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p><DirectoryMatch> and </DirectoryMatch> are used
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock to enclose a group of directives which will apply only to the
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock named directory and sub-directories of that directory, the same
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock as <a href="#directory"><Directory></a>. However, it
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock takes as an argument a regular expression. For example:</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <DirectoryMatch "^/www/.*/[0-9]{3}">
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>would match directories in /www/ that consisted of three
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock numbers.</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock href="#directory"><Directory></a> for a description of
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock how regular expressions are mixed in with normal
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <Directory>s.<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <strong>See also</strong>: <a href="/sections.html">How
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock Directory, Location and Files sections work</a> for an
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock explanation of how these different sections are combined when a
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock request is received</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <h2><a id="documentroot" name="documentroot">DocumentRoot
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Syntax:</strong></a> DocumentRoot
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Default:</strong></a> <code>DocumentRoot
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>This directive sets the directory from which httpd will
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock serve files. Unless matched by a directive like Alias, the
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock server appends the path from the requested URL to the document
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock root to make the path to the document. Example:</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <blockquote>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock </blockquote>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock then an access to
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <code>http://www.my.host.com/index.html</code> refers to
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>There appears to be a bug in mod_dir which causes problems
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock when the DocumentRoot has a trailing slash (<em>i.e.</em>,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock "DocumentRoot /usr/web/") so please avoid that.</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <h2><a id="errordocument" name="errordocument">ErrorDocument
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Syntax:</strong></a> ErrorDocument
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Context:</strong></a> server config, virtual
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock host, directory, .htaccess<br />
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock rel="Help"><strong>Override:</strong></a> FileInfo<br />
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock rel="Help"><strong>Compatibility:</strong></a> The directory
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock and .htaccess contexts are only available in Apache 1.1 and
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock later. The quoting syntax prior to Apache 2.0 was different.
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <p>In the event of a problem or error, Apache can be configured
51ece83525fa18f5e72627610f480dffc7e492fdeschrock to do one of four things,</p>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li>redirect to a local <em>URL-path</em> to handle the
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <li>redirect to an external <em>URL</em> to handle the
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>The first option is the default, while options 2-4 are
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock configured using the <code>ErrorDocument</code> directive,
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock which is followed by the HTTP response code and a URL or a
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock message. Apache will sometimes offer additional information
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <p>URLs can begin with a slash (/) for local URLs, or be a full
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock URL which the client can resolve. Alternatively, a message can
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock be provided to be displayed by the browser. Examples:</p>
3d7072f8bd27709dba14f6fe336f149d25d9e207eschrock <blockquote>
ea8dc4b6d2251b437950c0056bc626b311c73c27eschrock <code>ErrorDocument 500
Allow from .foo.com
href="/vhosts/name-based.html">name-based virtual
settings which determine whether self-referential URL's (e.g., by the
href="/dns-caveats.html">Warnings about DNS and
<!--#include virtual="footer.html" -->