</div>
<div id="quickview"><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#related">Related Modules and Directives</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#host">Access control by host</a></li>
-<li><img alt="" src="../images/down.gif" /> <a href="#env">Access control by environment variable</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#env">Access control by arbitrary variables</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#rewrite">Access control with mod_rewrite</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#moreinformation">More information</a></li>
</ul></div>
<div class="section">
<h2><a name="related" id="related">Related Modules and Directives</a></h2>
-<p>Access control can be done by several different modules. The most
-important of these are <code class="module"><a href="../mod/mod_authz_core.html">mod_authz_core</a></code> and
-<code class="module"><a href="../mod/mod_authz_host.html">mod_authz_host</a></code>. Also discussed in this document
-is access control using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
+ <p>Access control can be done by several different modules. The most
+ important of these are <code class="module"><a href="../mod/mod_authz_core.html">mod_authz_core</a></code> and
+ <code class="module"><a href="../mod/mod_authz_host.html">mod_authz_host</a></code>. Also discussed in this document
+ is access control using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="section">
<code class="module"><a href="../mod/mod_authz_host.html">mod_authz_host</a></code>.
</p>
- <p>The <code class="directive"><a href="../mod/mod_authz_host.html#allow">Allow</a></code> and
- <code class="directive"><a href="../mod/mod_authz_host.html#deny">Deny</a></code> directives let
- you allow and deny access based on the host name, or host
- address, of the machine requesting a document. The
- <code class="directive"><a href="../mod/mod_authz_host.html#order">Order</a></code> directive goes
- hand-in-hand with these two, and tells Apache in which order to
- apply the filters.</p>
+ <p>The <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>
+ provides a variety of different ways to allow or deny access to
+ resources. In conjunction with the <code class="directive"><a href="../mod/mod_authz_core.html#requireall">RequireAll</a></code>, <code class="directive"><a href="../mod/mod_authz_core.html#requireany">RequireAny</a></code>, and <code class="directive"><a href="../mod/mod_authz_core.html#requirenone">RequireNone</a></code> directives, these
+ requirements may be combined in arbitrarily complex ways, to enforce
+ whatever your access policy happens to be.</p>
+
+ <div class="warning"><p>
+ The <code class="directive"><a href="../mod/mod_access_compat.html#allow">Allow</a></code>,
+ <code class="directive"><a href="../mod/mod_access_compat.html#deny">Deny</a></code>, and
+ <code class="directive"><a href="../mod/mod_access_compat.html#order">Order</a></code> directives,
+ provided by <code class="module"><a href="../mod/mod_access_compat.html">mod_access_compat</a></code>, are deprecated and
+ will go away in a future version. You should avoid using them, and
+ avoid outdated tutorials recommending their use.
+ </p></div>
<p>The usage of these directives is:</p>
partial IP address, a network/netmask pair, or a network/nnn CIDR
specification. Either IPv4 or IPv6 addresses may be used.</p>
- <p>For example, if you have someone spamming your message
+ <p>See <a href="../mod/mod_authz_host.html#requiredirectives">the
+ mod_authz_host documentation</a> for further examples of this
+ syntax.</p>
+
+ <p>You can insert <code>not</code> to negate a particular requirement.
+ For example, if you have someone spamming your message
board, and you want to keep them out, you could do the
following:</p>
</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="section">
-<h2><a name="env" id="env">Access control by environment variable</a></h2>
+<h2><a name="env" id="env">Access control by arbitrary variables</a></h2>
<p>Using the <code class="directive"><a href="../mod/core.html#if"><If></a></code>,
you can allow or deny access based on arbitrary environment
<div class="section">
<h2><a name="rewrite" id="rewrite">Access control with mod_rewrite</a></h2>
-<p>The <code>[F]</code> <code class="directive"><a href="../mod/mod_rewrite.html#rewriterule">RewriteRule</a></code> flag causes a 403 Forbidden
-response to be sent. Using this, you can deny access to a resource based
-on arbitrary criteria.</p>
-
-<p>For example, if you wish to block access to a resource between 8pm
-and 6am, you can do this using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
-
-<div class="example"><p><code>
-RewriteEngine On<br />
-RewriteCond %{TIME_HOUR} >20 [OR]<br />
-RewriteCond %{TIME_HOUR} <07<br />
-RewriteRule ^/fridge - [F]
-</code></p></div>
-
-<p>This will return a 403 Forbidden response for any request after 8pm
-or before 7am. This technique can be used for any criteria that you wish
-to check. You can also redirect, or otherwise rewrite these requests, if
-that approach is preferred.</p>
-
-<p>The <code class="directive"><a href="../mod/core.html#if"><If></a></code> directive,
-added in 2.4, replaces many things that <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code> has
-traditionally been used to do, and you should probably look there first
-before resorting to mod_rewrite.</p>
+ <p>The <code>[F]</code> <code class="directive"><a href="../mod/mod_rewrite.html#rewriterule">RewriteRule</a></code> flag causes a 403 Forbidden
+ response to be sent. Using this, you can deny access to a resource based
+ on arbitrary criteria.</p>
+
+ <p>For example, if you wish to block access to a resource between 8pm
+ and 6am, you can do this using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
+
+ <div class="example"><p><code>
+ RewriteEngine On<br />
+ RewriteCond %{TIME_HOUR} >20 [OR]<br />
+ RewriteCond %{TIME_HOUR} <07<br />
+ RewriteRule ^/fridge - [F]
+ </code></p></div>
+
+ <p>This will return a 403 Forbidden response for any request after 8pm
+ or before 7am. This technique can be used for any criteria that you wish
+ to check. You can also redirect, or otherwise rewrite these requests, if
+ that approach is preferred.</p>
+
+ <p>The <code class="directive"><a href="../mod/core.html#if"><If></a></code> directive,
+ added in 2.4, replaces many things that <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code> has
+ traditionally been used to do, and you should probably look there first
+ before resorting to mod_rewrite.</p>
</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="section">