core.html revision 32ed30210ab8f16d81e27f751121e6939d11ce25
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
ab023a65562e62b85a824509d829b6fad87e00b1Rob Austein BGCOLOR="#FFFFFF"
47058d17266420179fa294de6b82d8fb5b918df4Michael Sawyer TEXT="#000000"
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer LINK="#0000FF"
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews VLINK="#000080"
0819ae2ca51571d205df061b52d8468889f3a0dfMichael Sawyer ALINK="#FF0000"
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews<!--#include virtual="header.html" -->
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark AndrewsThese configuration parameters control the core Apache features, and are
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrewsalways available.
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews<LI><A HREF="#accessfilename">AccessFileName</A>
c9defbf4b968e8a61f391246431ac63d0d6a39abMichael Sawyer<LI><A HREF="#allowoverride">AllowOverride</A>
c9defbf4b968e8a61f391246431ac63d0d6a39abMichael Sawyer<LI><A HREF="#bs2000account">BS2000Account</A>
1893b56ef9f5f2bc2a0fbe80d3c6b69df1bdc7c2Michael Sawyer<LI><A HREF="#clearmodulelist">ClearModuleList</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#coredumpdirectory">CoreDumpDirectory</A>
6d3f954c572db02159deedd444373161fda47a88Brian Wellington<LI><A HREF="#directory"><Directory></A>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafsson<LI><A HREF="#directorymatch"><DirectoryMatch></A>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafsson<LI><A HREF="#documentroot">DocumentRoot</A>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafsson<LI><A HREF="#errordocument">ErrorDocument</A>
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer<LI><A HREF="#filesmatch"><FilesMatch></A>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafsson<LI><A HREF="#hostnamelookups">HostNameLookups</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#identitycheck">IdentityCheck</A>
0e0e575ec135a983a53c501cf48734b823361ab4Brian Wellington<LI><A HREF="#ifmodule"><IfModule></A>
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<LI><A HREF="#keepalivetimeout">KeepAliveTimeout</A>
8d18fc189ff99f37544b1a0763e8931a7305a7f8Mark Andrews<LI><A HREF="#limitrequestbody">LimitRequestBody</A>
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrews<LI><A HREF="#limitrequestfields">LimitRequestFields</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#limitrequestfieldsize">LimitRequestFieldsize</A>
7efc8c3f692fc3226c00ce8bdc1b90eb06562352David Lawrence<LI><A HREF="#limitrequestline">LimitRequestLine</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#listenbacklog">ListenBacklog</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#locationmatch"><LocationMatch></A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#maxkeepaliverequests">MaxKeepAliveRequests</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#maxrequestsperchild">MaxRequestsPerChild</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#maxspareservers">MaxSpareServers</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#minspareservers">MinSpareServers</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#namevirtualhost">NameVirtualHost</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#resourceconfig">ResourceConfig</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#scoreboardfile">ScoreBoardFile</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#scriptinterpretersource">ScriptInterpreterSource</A>
da5d1cf1b1aa29ae53a0427be49291b04bd60549Mark Andrews<LI><A HREF="#sendbuffersize">SendBufferSize</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#serversignature">ServerSignature</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#threadsperchild">ThreadsPerChild</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#usecanonicalname">UseCanonicalName</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI><A HREF="#virtualhost"><VirtualHost></A>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<H2><A NAME="accessconfig">AccessConfig directive</A></H2>
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer<!--%plaintext <?INDEX {\tt AccessConfig} directive> -->
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson><STRONG>Syntax:</STRONG></A> AccessConfig <EM>filename</EM><BR>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson><STRONG>Default:</STRONG></A> <CODE>AccessConfig conf/access.conf</CODE><BR>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson><STRONG>Context:</STRONG></A> server config, virtual host<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerThe server will read this file for more directives after reading the
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont<A HREF="#resourceconfig">ResourceConfig</A> file. <EM>Filename</EM> is
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupontrelative to the <A HREF="#serverroot">ServerRoot</A>.
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis DupontThis feature can be disabled using:
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont<BLOCKQUOTE><CODE>AccessConfig /dev/null</CODE></BLOCKQUOTE>
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis DupontHistorically, this file only contained
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont<A HREF="#directory"><Directory></A> sections; in fact it can now
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupontcontain any server directive allowed in the <EM>server config</EM> context.
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont<H2><A NAME="accessfilename">AccessFileName directive</A></H2>
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont<!--%plaintext <?INDEX {\tt AccessFileName} directive> -->
d302a620e0d49811874b9555ac2e4c6e05861a6bFrancis Dupont><STRONG>Syntax:</STRONG></A> AccessFileName <EM>filename filename ...</EM><BR>
debd489a44363870f96f75818e89ec27d3cab736Francis Dupont><STRONG>Default:</STRONG></A> <CODE>AccessFileName .htaccess</CODE><BR>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafsson><STRONG>Context:</STRONG></A> server config, virtual host<BR>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer HREF="directive-dict.html#Compatibility"
555469af35c12189525921abbc3de3cefb5f9f0fMark Andrews><STRONG>Compatibility:</STRONG></A> AccessFileName can accept more than
555469af35c12189525921abbc3de3cefb5f9f0fMark Andrewsone filename only in Apache 1.3 and later<P>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael SawyerWhen returning a document to the client the server looks for the first existing
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyeraccess control file from this list of names in every directory of the path to
3d711f2f75cb9a9ddcbf1fca9b2de192e75340e6Mark Andrewsthe document, if access control files are enabled for that directory.
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer<BLOCKQUOTE><CODE>AccessFileName .acl</CODE></BLOCKQUOTE>
555469af35c12189525921abbc3de3cefb5f9f0fMark Andrewsbefore returning the document /usr/local/web/index.html, the
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyerserver will read /.acl, /usr/.acl, /usr/local/.acl and /usr/local/web/.acl
ea17e969771f19485dc7ab2f731d641128a9ee3bMark Andrewsfor directives, unless they have been disabled with
555469af35c12189525921abbc3de3cefb5f9f0fMark Andrews<Directory /><BR>
19c8df90f1f23c3df870c1771c89c1acdb15020eMichael SawyerAllowOverride None<BR>
6fe03d6c83ec02d4494edc870f5e892d419b6885Michael Sawyer<H2><A NAME="addmodule">AddModule directive</A></H2>
6fe03d6c83ec02d4494edc870f5e892d419b6885Michael Sawyer<!--%plaintext <?INDEX {\tt AddModule} directive> -->
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer><STRONG>Syntax:</STRONG></A> AddModule <EM>module module ...</EM><BR>
c4ae16b2aa93f6983695f4a5debeb7c53ef111bbMichael Sawyer><STRONG>Context:</STRONG></A> server config <BR>
b4876b6ddf706977153954507b498baf79a23442Andreas Gustafsson HREF="directive-dict.html#Compatibility"
c4ae16b2aa93f6983695f4a5debeb7c53ef111bbMichael Sawyer><STRONG>Compatibility:</STRONG></A> AddModule is only available in
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael SawyerApache 1.2 and later<P>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael SawyerThe server can have modules compiled in which are not actively in use.
f9521c63ea42fee93f7ae67512e4330ab13081c8Brian WellingtonThis directive can be used to enable the use of those modules. The
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafssonserver comes with a pre-loaded list of active modules; this list can
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyerbe cleared with the <A HREF="#clearmodulelist">ClearModuleList</A>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer<H2><A NAME="allowoverride">AllowOverride directive</A></H2>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer<!--%plaintext <?INDEX {\tt AllowOverride} directive> -->
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyer><STRONG>Syntax:</STRONG></A> AllowOverride <EM>override override ...</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Default:</STRONG></A> <CODE>AllowOverride All</CODE><BR>
187bf10eb566d407d54e66b42b468c6c33f2591cAndreas Gustafsson><STRONG>Context:</STRONG></A> directory<BR>
187bf10eb566d407d54e66b42b468c6c33f2591cAndreas GustafssonWhen the server finds an .htaccess file (as specified by
187bf10eb566d407d54e66b42b468c6c33f2591cAndreas Gustafsson<A HREF="#accessfilename">AccessFileName</A>) it needs to know which
187bf10eb566d407d54e66b42b468c6c33f2591cAndreas Gustafssondirectives declared in that file can override earlier access information.<P>
46e349e515e0b992ecafdc9597f9d5ee0cf81b2aBrian Wellington<EM>Override</EM> can be set to <CODE>None</CODE>, in which case the server
354f4f1ab20ba521818a4bff9ffdbf9e00142b91Ben Cottrellwill not read the file, <CODE>All</CODE> in which case the server will
d8dde7c9fb66407ebe3263859f75e3d64164de82Ben Cottrellallow all the directives, or one or more of the following:
354f4f1ab20ba521818a4bff9ffdbf9e00142b91Ben Cottrell<DT>AuthConfig
46e349e515e0b992ecafdc9597f9d5ee0cf81b2aBrian Wellington<!--%plaintext <?INDEX {\tt AuthConfig} override> -->
df5503799f5d2609cc759a7a1f3274daeb728236Michael SawyerAllow use of the authorization directives
b4876b6ddf706977153954507b498baf79a23442Andreas Gustafsson(<A HREF="mod_auth_dbm.html#authdbmgroupfile">AuthDBMGroupFile</A>,
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyer<A HREF="mod_auth_dbm.html#authdbmuserfile">AuthDBMUserFile</A>,
b4876b6ddf706977153954507b498baf79a23442Andreas Gustafsson<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A>,
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer<A HREF="#authname">AuthName</A>, <A HREF="#authtype">AuthType</A>,
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer<A HREF="mod_auth.html#authuserfile">AuthUserFile</A>,
1ae75c1024eb0475c2be352b8707772e16332ad0Mark Andrews<!--%plaintext <?INDEX {\tt FileInfo} override> -->
1ae75c1024eb0475c2be352b8707772e16332ad0Mark AndrewsAllow use of the directives controlling document types
1ae75c1024eb0475c2be352b8707772e16332ad0Mark Andrews(<A HREF="mod_mime.html#addencoding">AddEncoding</A>,
1ae75c1024eb0475c2be352b8707772e16332ad0Mark Andrews<A HREF="mod_mime.html#addlanguage">AddLanguage</A>,
1ae75c1024eb0475c2be352b8707772e16332ad0Mark Andrews<A HREF="mod_negotiation.html#languagepriority">LanguagePriority</A>, <EM>etc.</EM>).
7efc8c3f692fc3226c00ce8bdc1b90eb06562352David Lawrence<!--%plaintext <?INDEX {\tt Indexes} override> -->
7efc8c3f692fc3226c00ce8bdc1b90eb06562352David LawrenceAllow use of the directives controlling directory indexing
7efc8c3f692fc3226c00ce8bdc1b90eb06562352David Lawrence(<A HREF="mod_autoindex.html#adddescription">AddDescription</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#addicon">AddIcon</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#addiconbyencoding">AddIconByEncoding</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#addiconbytype">AddIconByType</A>,
c03bb27f0675a6e60ceea66b451548e8481bc05cMark Andrews<A HREF="mod_autoindex.html#defaulticon">DefaultIcon</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_dir.html#directoryindex">DirectoryIndex</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#fancyindexing">FancyIndexing</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#headername">HeaderName</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#indexignore">IndexIgnore</A>,
11463c0ac24692e229ec87f307f5e7df3c0a7e10Evan Hunt<A HREF="mod_autoindex.html#indexoptions">IndexOptions</A>,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_autoindex.html#readmename">ReadmeName</A>, <EM>etc.</EM>).
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt Limit} override> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerAllow use of the directives controlling host access (allow, deny and order).
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt Options} override> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerAllow use of the directives controlling specific directory features
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="mod_include.html#xbithack">XBitHack</A>).
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<H2><A NAME="authname">AuthName directive</A></H2>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt AuthName} directive> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Syntax:</STRONG></A> AuthName <EM>auth-domain</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Override:</STRONG></A> AuthConfig<BR>
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉This directive sets the name of the authorization realm for a directory.
7a272c6b0de3b8c0ad018b9896e287da19c43befAutomatic UpdaterThis realm is given to the client so that the user knows which username and
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉password to send. <SAMP>AuthName</SAMP> takes a single argument;
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉if the realm name contains spaces, it must be enclosed in quotation marks.
7a272c6b0de3b8c0ad018b9896e287da19c43befAutomatic UpdaterIt must be accompanied by <A HREF="#authtype">AuthType</A> and
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<A HREF="#require">require</A> directives, and directives such as
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<H2><A NAME="authtype">AuthType directive</A></H2>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt AuthType} directive> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Syntax:</STRONG></A> AuthType <EM>type</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
d0ad6ddcdd20c637477e12d757090cb0b5ff81cbDavid Lawrence><STRONG>Override:</STRONG></A> AuthConfig<BR>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas GustafssonThis directive selects the type of user authentication for a directory.
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas GustafssonOnly <CODE>Basic</CODE> and <CODE>Digest</CODE> are currently implemented.
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<!--%plaintext <?INDEX {\tt Basic} authentication scheme> -->
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas GustafssonIt must be accompanied by <A HREF="#authname">AuthName</A> and
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="#require">require</A> directives, and directives such as
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<H2><A NAME="bindaddress">BindAddress directive</A></H2>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson<!--%plaintext <?INDEX {\tt BindAddress} directive> -->
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson><STRONG>Syntax:</STRONG></A> BindAddress <EM>saddr</EM><BR>
9ecb35e7d4ec2384d5426f41e90dad1eb9891898Andreas Gustafsson><STRONG>Default:</STRONG></A> <CODE>BindAddress *</CODE><BR>
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyer><STRONG>Context:</STRONG></A> server config<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerA Unix® http server can either listen for connections to every
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerIP address of the server machine, or just one IP address of the server
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI>An IP address
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI>A fully-qualified Internet domain name
40f53fa8d9c6a4fc38c0014495e7a42b08f52481David LawrenceIf the value is *, then the server will listen for connections on
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerevery IP address, otherwise it will only listen on the IP address
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerspecified. <P>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerOnly one <CODE>BindAddress</CODE> directive can be used. For more
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyercontrol over which address and ports Apache listens to, use the
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<CODE><A HREF="#listen">Listen</A></CODE> directive instead of
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<CODE>BindAddress</CODE> can be used as an alternative method for
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyersupporting <A HREF="/vhosts/index.html">virtual hosts</A> using
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyermultiple independent servers, instead of using <CODE><A
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerHREF="#virtualhost"><VirtualHost></A></CODE> sections.
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="/dns-caveats.html">DNS Issues</A><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<A HREF="/bind.html">Setting which addresses and ports Apache uses</A></P>
40f53fa8d9c6a4fc38c0014495e7a42b08f52481David Lawrence<H2><A NAME="bs2000account">BS2000Account directive</A></H2>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt BS2000Account} directive> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Syntax:</STRONG></A> BS2000Account <EM>account</EM><BR>
6e49e91bd08778d7eae45a2229dcf41ed97cc636David Lawrence><STRONG>Default:</STRONG></A> <EM>none</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> server config<BR>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews HREF="directive-dict.html#Compatibility"
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews><STRONG>Compatibility:</STRONG></A> BS2000Account is only available for
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsBS2000 machines, as of Apache 1.3 and later.<P>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsThe <CODE>BS2000Account</CODE> directive is available for BS2000 hosts
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrewsonly. It must be used to define the account number for the non-privileged
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrewsapache server user (which was configured using the
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsThis is required by the BS2000 POSIX subsystem (to change the underlying
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsBS2000 task environment by performing a sub-LOGON) to prevent CGI scripts
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrewsfrom accessing resources of the privileged account which started the
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsOnly one <CODE>BS2000Account</CODE> directive can be used. <P>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews<A HREF="/ebcdic.html">Apache EBCDIC port</A></P>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews<H2><A NAME="clearmodulelist">ClearModuleList directive</A></H2>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews<!--%plaintext <?INDEX {\tt ClearModuleList} directive> -->
6e49e91bd08778d7eae45a2229dcf41ed97cc636David Lawrence><STRONG>Syntax:</STRONG></A> ClearModuleList<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> server config<BR>
e9b85f0309c6bb6eebc2d6a0acf6a8f3bcc376acTatuya JINMEI 神明達哉 HREF="directive-dict.html#Compatibility"
e9b85f0309c6bb6eebc2d6a0acf6a8f3bcc376acTatuya JINMEI 神明達哉><STRONG>Compatibility:</STRONG></A> ClearModuleList is only available in
e22bd3c4bc0de0b96531fab5c2c944251e02e975Mark AndrewsApache 1.2 and later<P>
46e349e515e0b992ecafdc9597f9d5ee0cf81b2aBrian WellingtonThe server comes with a built-in list of active modules. This
97beb7237b6383cf518d79cee08e23c8aa2bae3fMichael Sawyerdirective clears the list. It is assumed that the list will then be
3f79a8b6f1b50f8e1bc2f274bcfe91d6af74f161Mark Andrewsre-populated using the <A HREF="#addmodule">AddModule</A> directive.<P><HR>
46e349e515e0b992ecafdc9597f9d5ee0cf81b2aBrian Wellington<H2><A NAME="contentdigest">ContentDigest directive</A></H2>
46e349e515e0b992ecafdc9597f9d5ee0cf81b2aBrian Wellington<!--%plaintext <?INDEX {\tt ContentDigest} directive> -->
97beb7237b6383cf518d79cee08e23c8aa2bae3fMichael Sawyer><STRONG>Syntax:</STRONG></A> ContentDigest <EM>on|off</EM><BR>
7786d6542bb800be7d8c56793985d510626806b2Mark Andrews><STRONG>Default:</STRONG></A> <CODE>ContentDigest off</CODE><BR>
7786d6542bb800be7d8c56793985d510626806b2Mark Andrews><STRONG>Context:</STRONG></A> server config, virtual host, directory,
7786d6542bb800be7d8c56793985d510626806b2Mark Andrews.htaccess<BR>
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer><STRONG>Status:</STRONG></A> experimental<BR>
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff HREF="directive-dict.html#Compatibility"
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff><STRONG>Compatibility:</STRONG></A> ContentDigest is only available in
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsApache 1.1 and later<P>
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffThis directive enables the generation of <CODE>Content-MD5</CODE> headers
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffas defined in RFC1864 respectively RFC2068.<P>
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark AndrewsMD5 is an algorithm for computing a "message digest" (sometimes called
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrews"fingerprint") of arbitrary-length data, with a high degree of confidence
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrewsthat any alterations in the data will be reflected in alterations in the
9a8cec4995c1586d27e95f13d421e4de61a97eb5Mark Andrewsmessage digest.<P>
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffThe <CODE>Content-MD5</CODE> header provides an end-to-end message
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffintegrity check (MIC) of the entity-body. A proxy or client may check this
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffheader for detecting accidental modification of the entity-body
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffExample header:
7a272c6b0de3b8c0ad018b9896e287da19c43befAutomatic Updater<PRE> Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==</PRE><P>
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffNote that this can cause performance problems on your server
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffsince the message digest is computed on every request
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff(the values are not cached).<P>
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<CODE>Content-MD5</CODE> is only sent for documents served by the
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffcore, and not by any module. For example, SSI documents, output from
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffCGI scripts, and byte range responses do not have this header.
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<H2><A NAME="coredumpdirectory">CoreDumpDirectory directive</A></H2>
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<!--%plaintext <?INDEX {\tt CoreDumpDirectory} directive> -->
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff><STRONG>Syntax:</STRONG></A> CoreDumpDirectory <EM>directory</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Default:</STRONG></A> the same location as ServerRoot<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> server config<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerThis controls the directory to which Apache attempts to switch before
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerdumping core. The default is in the <A HREF="#serverroot">ServerRoot</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerdirectory, however since this should not be writable by the user
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerthe server runs as, core dumps won't normally get written. If you
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerwant a core dump for debugging, you can use this directive to place
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<H2><A NAME="defaulttype">DefaultType directive</A></H2>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt DefaultType} directive> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Syntax:</STRONG></A> DefaultType <EM>MIME-type</EM><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Default:</STRONG></A> <CODE>DefaultType text/html</CODE><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host, directory,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerThere will be times when the server is asked to provide a document
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerwhose type cannot be determined by its MIME types mappings.<P>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerThe server must inform the client of the content-type of the document, so in
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerthe event of an unknown type it uses the <CODE>DefaultType</CODE>. For
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<BLOCKQUOTE><CODE>DefaultType image/gif</CODE></BLOCKQUOTE>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafssonwould be appropriate for a directory which contained many gif images
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerwith filenames missing the .gif extension.<P><HR>
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyer<H2><A NAME="directory"><Directory> directive</A></H2>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<!--%plaintext <?INDEX {\tt Directory} section directive> -->
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Syntax:</STRONG></A> <Directory <EM>directory</EM>>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer ... </Directory> <BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<Directory> and </Directory> are used to enclose a group of
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyerdirectives which will apply only to the named directory and sub-directories
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerof that directory. Any directive which is allowed in a directory
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyercontext may be used. <EM>Directory</EM> is either the full path to a directory,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyeror a wild-card string. In a wild-card string, `?' matches any single character,
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerand `*' matches any sequences of characters. As of Apache 1.3, you
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafssonmay also use `[]' character ranges like in the shell. Also as of Apache 1.3
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyernone of the wildcards match a `/' character, which more closely mimics the
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerbehaviour of Unix shells.
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer Options Indexes FollowSymLinks
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer </Directory>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerExtended regular expressions can also be used, with the addition of the
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer <Directory ~ "^/www/.*/[0-9]{3}">
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffwould match directories in /www/ that consisted of three numbers.
06a949d2ce8d4b4cbfbf4e7a0335316520aafa46Andreas Gustafsson<P>If multiple (non-regular expression) directory sections match the
06a949d2ce8d4b4cbfbf4e7a0335316520aafa46Andreas Gustafssondirectory (or its parents) containing
06a949d2ce8d4b4cbfbf4e7a0335316520aafa46Andreas Gustafssona document, then the directives are applied in the order of shortest match
06a949d2ce8d4b4cbfbf4e7a0335316520aafa46Andreas Gustafssonfirst, interspersed with the directives from the
06a949d2ce8d4b4cbfbf4e7a0335316520aafa46Andreas Gustafsson<A HREF="#accessfilename">.htaccess</A> files. For example, with
e9b85f0309c6bb6eebc2d6a0acf6a8f3bcc376acTatuya JINMEI 神明達哉<Directory /><BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerAllowOverride None<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<Directory /home/*><BR>
3001a1b4e6298466882a4147307b4c28a3b08f91Mark AndrewsAllowOverride FileInfo<BR>
67d01dcacb2051a03377c8ec5c0e36604c17aea5Evan Huntfor access to the document <CODE>/home/web/dir/doc.html</CODE> the
67d01dcacb2051a03377c8ec5c0e36604c17aea5Evan Hunt<LI>Apply directive <CODE>AllowOverride None</CODE> (disabling
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews<LI>Apply directive <CODE>AllowOverride FileInfo</CODE> (for directory
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews<LI>Apply any FileInfo directives in <CODE>/home/web/.htaccess</CODE>
4d86cda3d7eb31578c9088c51a26643d43799533Mark AndrewsRegular expression directory sections are handled slightly differently
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsby Apache 1.2 and 1.3. In Apache 1.2 they are interspersed with the normal
2f5baf12a411b29ac693f82b1ee8457b749d515cMark Andrewsdirectory sections and applied in the order they appear in the configuration
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsfile. They are applied only once, and apply when the shortest match
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewspossible occurs. In Apache 1.3 regular expressions are not considered
3933e5c7639ce930ab58366e8f6e544926784ea6Francis Dupontuntil after all of the normal sections have been applied. Then all of
3933e5c7639ce930ab58366e8f6e544926784ea6Francis Dupontthe regular expressions are tested in the order they appeared in the
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsconfiguration file. For example, with
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews<Directory ~ abc$><BR>
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews... directives here ...<BR>
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews</Directory><BR>
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark AndrewsSuppose that the filename being accessed is
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrews<CODE>/home/abc/public_html/abc/index.html</CODE>. The server
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsconsiders each of <CODE>/</CODE>, <CODE>/home</CODE>, <CODE>/home/abc</CODE>,
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrews<CODE>/home/abc/public_html</CODE>, and <CODE>/home/abc/public_html/abc</CODE>
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsin that order. In Apache 1.2, when
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrews<CODE>/home/abc</CODE> is considered, the regular expression will match
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsand be applied. In Apache 1.3 the regular expression isn't considered
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsat all at that point in the tree. It won't be considered until after
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsall normal <Directory>s and <CODE>.htaccess</CODE> files have
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsbeen applied. Then the regular expression will
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsmatch on <CODE>/home/abc/public_html/abc</CODE> and be applied.
4d86cda3d7eb31578c9088c51a26643d43799533Mark AndrewsNote that the default Apache access for <Directory /> is
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews<SAMP>Allow from All</SAMP>. This means that Apache will serve any file
3d711f2f75cb9a9ddcbf1fca9b2de192e75340e6Mark Andrewsmapped from an URL. It is recommended that you change this with a block
67d01dcacb2051a03377c8ec5c0e36604c17aea5Evan Hunt <Directory />
67d01dcacb2051a03377c8ec5c0e36604c17aea5Evan Hunt Order Deny,Allow
67d01dcacb2051a03377c8ec5c0e36604c17aea5Evan Hunt Deny from All
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews </Directory>
6100b1769956200b2815803ab7b35556396ce0d1Mark Andrewsand then override this for directories you <EM>want</EM> accessible.
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews>Security Tips</A>
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewspage for more details.
4d86cda3d7eb31578c9088c51a26643d43799533Mark AndrewsThe directory sections typically occur in the access.conf file, but they
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsmay appear in any configuration file. <Directory> directives cannot
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsnest, and cannot appear in a <A HREF="#limit"><Limit></A> section.
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
6fe03d6c83ec02d4494edc870f5e892d419b6885Michael SawyerLocation and Files sections work</A> for an explanation of how these
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerdifferent sections are combined when a request is received
f17b62a64bec4690f7ef0263efee1fa727b66fd5Michael Sawyer<H2><A NAME="directorymatch"><DirectoryMatch></A></H2>
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer><STRONG>Syntax:</STRONG></A> <DirectoryMatch <EM>regex</EM>>
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrews ... </DirectoryMatch> <BR>
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host<BR>
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews HREF="directive-dict.html#Compatibility"
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer><STRONG>Compatibility:</STRONG></A> Available in Apache 1.3 and later
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer<P><DirectoryMatch> and </DirectoryMatch> are used to enclose a
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉directives which will apply only to the named directory and sub-directories
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerof that directory, the same as <A
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerHREF="#directory"><Directory></A>. However, it takes as an
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyerargument a regular expression. For example:</P>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer <DirectoryMatch "^/www/.*/[0-9]{3}">
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<P>would match directories in /www/ that consisted of three numbers.</P>
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrews<A HREF="#directory"><Directory></A> for a description of how
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrewsregular expressions are mixed in with normal <Directory>s.
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrews<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark AndrewsLocation and Files sections work</A> for an explanation of how these
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrewsdifferent sections are combined when a request is received
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer<H2><A NAME="documentroot">DocumentRoot directive</A></H2>
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrews<!--%plaintext <?INDEX {\tt DocumentRoot} directive> -->
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉><STRONG>Syntax:</STRONG></A> DocumentRoot <EM>directory-filename</EM><BR>
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉><STRONG>Default:</STRONG></A> <CODE>DocumentRoot
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews><STRONG>Context:</STRONG></A> server config, virtual host<BR>
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark AndrewsThis directive sets the directory from which httpd will serve files.
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark AndrewsUnless matched by a directive like Alias, the server appends the path
9e4b25fc3eb5777202147634d789345d893b4539Mark Andrewsfrom the requested URL to the document root to make the path to the
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrewsdocument. Example:
3001a1b4e6298466882a4147307b4c28a3b08f91Mark Andrews<BLOCKQUOTE><CODE>DocumentRoot /usr/web</CODE></BLOCKQUOTE>
3001a1b4e6298466882a4147307b4c28a3b08f91Mark Andrewsthen an access to <CODE>http://www.my.host.com/index.html</CODE> refers
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews<P>There appears to be a bug in mod_dir which causes problems when the
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark AndrewsDocumentRoot has a trailing slash (<EM>i.e.</EM>, "DocumentRoot /usr/web/") so
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrewsplease avoid that.
b8fff4f0d70bb9c5e53023ad0dae0acda67b5cdaMark Andrews<H2><A NAME="errordocument">ErrorDocument directive</A></H2>
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<!--%plaintext <?INDEX {\tt ErrorDocument} directive> -->
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer><STRONG>Syntax:</STRONG></A> ErrorDocument <EM>error-code document</EM><BR>
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host, directory,
1d2f2d7c9ab1c38a80f38dbbde26fe1d65a26144Michael Sawyer HREF="directive-dict.html#Compatibility"
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉><STRONG>Compatibility:</STRONG></A> The directory and .htaccess contexts
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉are only available in Apache 1.1 and later.<P>
905ba39e10a8f483d167b992ec31f4c0bf34326eMark AndrewsIn the event of a problem or error, Apache can be configured to do
905ba39e10a8f483d167b992ec31f4c0bf34326eMark Andrewsone of four things,
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉<LI>output a simple hardcoded error message
cc7732e1299042bff430dfdfbc2624fb340047b2Michael Sawyer<LI>output a customized message
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<LI>redirect to a local URL to handle the problem/error
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<LI>redirect to an external URL to handle the problem/error
ec3984e9df6fd9b7811daa0dacb1b3dd1423ebf3Mark Andrews<P>The first option is the default, while options 2-4 are configured
ec3984e9df6fd9b7811daa0dacb1b3dd1423ebf3Mark Andrewsusing the <CODE>ErrorDocument</CODE> directive, which is followed by
6d3f954c572db02159deedd444373161fda47a88Brian Wellingtonthe HTTP response code and a message or URL.
6d3f954c572db02159deedd444373161fda47a88Brian Wellington<P><EM>Messages</EM> in this context begin with a single quote
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrews(<CODE>"</CODE>), which does not form part of the message itself.
4d86cda3d7eb31578c9088c51a26643d43799533Mark AndrewsApache will sometimes offer additional information regarding the
38cf6e52ce4b33795713388824b69d78e430b115Michael Sawyer<P>URLs can begin with a slash (/) for local URLs, or be a full
38cf6e52ce4b33795713388824b69d78e430b115Michael SawyerURL which the client can resolve. Examples:
38cf6e52ce4b33795713388824b69d78e430b115Michael SawyerErrorDocument 500 http://foo.example.com/cgi-bin/tester<BR>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael SawyerErrorDocument 403 "Sorry can't allow you access today
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer<P>Note that when you specify an <CODE>ErrorDocument</CODE> that
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyerpoints to a remote URL (ie. anything with a method such as "http" in
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyerfront of it) Apache will send a redirect to the client to tell it
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffwhere to find the document, even if the document ends up being
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffon the same server.. This has several implications, the
2706bea98ef713e844670b85274af9502f87d7bcMichael Graffmost important being that <STRONG>if you use an "ErrorDocument 401"
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyerdirective then it must refer to a local document.</STRONG> This results
df5503799f5d2609cc759a7a1f3274daeb728236Michael Sawyerfrom the nature of the HTTP basic authentication scheme.
3001a1b4e6298466882a4147307b4c28a3b08f91Mark Andrews<P>See Also: <A HREF="/custom-error.html">documentation of customizable
3001a1b4e6298466882a4147307b4c28a3b08f91Mark Andrews<H2><A NAME="errorlog">ErrorLog directive</A></H2>
3001a1b4e6298466882a4147307b4c28a3b08f91Mark Andrews<!--%plaintext <?INDEX {\tt ErrorLog} directive> -->
3806886c281873e563420a86a024bd09e57fd90eBrian Wellington><STRONG>Syntax:</STRONG></A> ErrorLog <EM>filename</EM>|<CODE>syslog[:facility]</CODE>
aa6054ec74819f754bcf19442ca9b39d948171adMichael Sawyer><STRONG>Default:</STRONG></A> <CODE>ErrorLog logs/error_log</CODE> (Unix)<BR>
7949dbdae1db33e6263d754e5940daa1dfba59f9Michael Sawyer><STRONG>Default:</STRONG></A> <CODE>ErrorLog logs/error.log</CODE>
40f53fa8d9c6a4fc38c0014495e7a42b08f52481David Lawrence (Windows and OS/2)<BR>
d821f1cd7e97552401296e880e7518c98c9ebea1Michael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host<BR>
ea17e969771f19485dc7ab2f731d641128a9ee3bMark AndrewsThe error log directive sets the name of the file to which the server will log
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewsany errors it encounters. If the filename does not begin with a slash (/)
ea17e969771f19485dc7ab2f731d641128a9ee3bMark Andrewsthen it is assumed to be relative to the <A HREF="#serverroot">ServerRoot</A>.
3d711f2f75cb9a9ddcbf1fca9b2de192e75340e6Mark AndrewsIf the filename begins with a pipe (|) then it is assumed to be a command to
3d711f2f75cb9a9ddcbf1fca9b2de192e75340e6Mark Andrewsspawn to handle the error log.
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael SawyerUsing <CODE>syslog</CODE> instead of a filename enables logging via syslogd(8)
acf6bcebf95a699789e75d58674f0f2d04b9e7eeAndreas Gustafssonif the system supports it. The default is to use syslog facility
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<CODE>local7</CODE>, but you can override this by using the
2706bea98ef713e844670b85274af9502f87d7bcMichael Graff<CODE>syslog:</CODE><EM>facility</EM> syntax where <EM>facility</EM> can be
acf6bcebf95a699789e75d58674f0f2d04b9e7eeAndreas Gustafssonone of the names usually documented in syslog(1).
c12904ec531fb210066bafc33bde74d43889caacMark AndrewsSECURITY: See the
c12904ec531fb210066bafc33bde74d43889caacMark Andrews<A HREF="/misc/security_tips.html#serverroot">security tips</A>
24139527f3d0d3fe743bd867329a2edd529728a6Andreas Gustafssondocument for details on why your security could be compromised if
b31e7ab8857a62eb94d4a6a681243739f158374dDanny Mayerthe directory where logfiles are stored is writable by anyone other
b31e7ab8857a62eb94d4a6a681243739f158374dDanny Mayerthan the user that starts the server.
715361d0c3800e5ad886e5df971936ce6cd1ca89Mark Andrews<P><STRONG>See also:</STRONG> <A HREF="#loglevel">LogLevel</A>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer<H2><A NAME="files"><Files> directive</A></H2>
5d20773abcdf9ff3afe14a349413174f94594188Michael Sawyer><STRONG>Syntax:</STRONG></A> <Files <EM>filename</EM>>
771218f9cacfbade2fcf3ab65520e8c473a12a3aBrian Wellington... </Files><BR>
d7a2e0511222811b96f2e8757272ee383ec7b5e6Michael Sawyer><STRONG>Context:</STRONG></A> server config, virtual host, .htaccess<BR>
3fbc17b5e380bcdcc882dc35015676b2cf1a06aeMichael Sawyer HREF="directive-dict.html#Compatibility"
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyer><STRONG>Compatibility:</STRONG></A> only available in Apache
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyer1.2 and above.<P>
3ce3305278210aa6c931ea338e8c71c83a55d028Brian Wellington<P>The <Files> directive provides for access control by
2706bea98ef713e844670b85274af9502f87d7bcMichael Grafffilename. It is comparable to the <A
2706bea98ef713e844670b85274af9502f87d7bcMichael GraffHREF="#directory"><Directory></A> directive and
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyer<A HREF="#location"><Location></A> directives. It
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyershould be matched with a </Files> directive. The
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyerdirectives given within this section will be applied to any
7a272c6b0de3b8c0ad018b9896e287da19c43befAutomatic Updaterobject with a basename (last component of filename) matching
3ac2a9987875e947e0d0a09702b5a9b4dd745b75Tatuya JINMEI 神明達哉the specified filename.
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews<CODE><Files></CODE> sections are processed in the
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrewsorder they appear in the configuration file, after the
5dcc67a0fff89e7ebf051f64b6b987862c331a04Mark Andrews<Directory> sections and <CODE>.htaccess</CODE> files are
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyerread, but before <Location> sections. Note that
38cf6e52ce4b33795713388824b69d78e430b115Michael Sawyer<Files> can be nested inside <Directory>
38cf6e52ce4b33795713388824b69d78e430b115Michael Sawyersections to restrict the portion of the filesystem they
4d86cda3d7eb31578c9088c51a26643d43799533Mark Andrewsapply to.</P>
bdf0739d6e1d042355123931ba44d7f3bc9066b9Mark Andrews<P>The <EM>filename</EM> argument should include a filename, or a
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyerwild-card string, where `?' matches any single character, and `*' matches any
b8a04d50a361eb5e6a6b098d530daa0c56c6fdd9Mark Andrewssequences of characters. Extended regular expressions can also be used,
4e7973990c2aaec391cf307a7e60583331568e01Evan Huntwith the addition of
58e291cb8dd77656048d6d7727f2bc2388110785Evan Hunt <Files ~ "\.(gif|jpe?g|png)$">
cefd68008fbba3488a077052ae62aa12b6de502bMichael Sawyerwould match most common Internet graphics formats. In Apache 1.3 and
8cd54a7461ad183f9e839d96cedb7b7ad03fb244Michael Sawyerlater, <A HREF="#filesmatch"><FilesMatch></A> is preferred,
cefd68008fbba3488a077052ae62aa12b6de502bMichael SawyerHREF="#directory"><CODE><Directory></CODE></A> and <A
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
from browsers at foo.com, you might use:
allow from .foo.com
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
edit the HARD_SERVER_LIMIT entry in httpd.h and recompile.
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Override"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Override"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
Linux 1.x users might be able to add
might work with some 1.x installations, but won't work with all of
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
Windows Registry to be searched using the script file extension (e.g., .pl) as a search key.
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Default"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Syntax"
HREF="directive-dict.html#Context"
HREF="directive-dict.html#Status"
HREF="directive-dict.html#Compatibility"
HREF="directive-dict.html#Compatibility"
<!--#include virtual="footer.html" -->