Update examples for RemoveAddrValve, RemoteHostValve in the docs
authorkkolinko <kkolinko@13f79535-47bb-0310-9956-ffa450edef68>
Sat, 15 Jan 2011 18:54:46 +0000 (18:54 +0000)
committerkkolinko <kkolinko@13f79535-47bb-0310-9956-ffa450edef68>
Sat, 15 Jan 2011 18:54:46 +0000 (18:54 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@1059390 13f79535-47bb-0310-9956-ffa450edef68

webapps/docs/config/context.xml
webapps/docs/config/engine.xml
webapps/docs/config/filter.xml
webapps/docs/config/host.xml
webapps/docs/config/valve.xml

index ab3bf17..5f25a77 100644 (file)
     incoming request directed to the surrounding
     <a href="engine.html">Engine</a>, <a href="host.html">Host</a>, or
     <a href="context.html">Context</a> element.  The remote address or name
-    will be checked against a configured list of "accept" and/or "deny"
-    filters, which are defined using the Regular Expression syntax supported
-    by the <a href="http://jakarta.apache.org/regexp/">Jakarta Regexp</a>
-    regular expression library.  Requests that come from locations that are
+    will be checked against configured "accept" and/or "deny"
+    filters, which are defined using <code>java.util.regex</code> Regular
+    Expression syntax.  Requests that come from locations that are
     not accepted will be rejected with an HTTP "Forbidden" error.
     Example filter declarations:</p>
 
 &lt;Context path="/examples" ...&gt;
   ...
   &lt;Valve className="org.apache.catalina.valves.RemoteHostValve"
-         allow="*.mycompany.com,www.yourcompany.com"/&gt;
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/&gt;
   &lt;Valve className="org.apache.catalina.valves.RemoteAddrValve"
-         deny="192.168.1.*"/&gt;
+         deny="192\.168\.1\.\d+"/&gt;
   ...
 &lt;/Context&gt;
 </source>
index 687006c..07ddec4 100644 (file)
     incoming request directed to the surrounding
     <a href="engine.html">Engine</a>, <a href="host.html">Host</a>, or
     <a href="context.html">Context</a> element.  The remote address or name
-    will be checked against a configured list of "accept" and/or "deny"
-    filters, which are defined using the Regular Expression syntax supported
-    by the <a href="http://jakarta.apache.org/regexp/">Jakarta Regexp</a>
-    regular expression library.  Requests that come from locations that are
+    will be checked against configured "accept" and/or "deny"
+    filters, which are defined using <code>java.util.regex</code> Regular
+    Expression syntax.  Requests that come from locations that are
     not accepted will be rejected with an HTTP "Forbidden" error.
     Example filter declarations:</p>
 
 &lt;Engine name="Standalone" ...&gt;
   ...
   &lt;Valve className="org.apache.catalina.valves.RemoteHostValve"
-         allow="*.mycompany.com,www.yourcompany.com"/&gt;
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/&gt;
   &lt;Valve className="org.apache.catalina.valves.RemoteAddrValve"
-         deny="192.168.1.*"/&gt;
+         deny="192\.168\.1\.\d+"/&gt;
   ...
 &lt;/Engine&gt;
 </source>
index a0373bb..e54c005 100644 (file)
@@ -549,7 +549,7 @@ FINE: Request "/docs/config/manager.html" with response status "200" content-typ
     <attributes>
 
       <attribute name="allow" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client&apos;s IP address is compared to.  If this attribute
         is specified, the remote address MUST match for this request to be
         accepted.  If this attribute is not specified, all requests will be
@@ -558,7 +558,7 @@ FINE: Request "/docs/config/manager.html" with response status "200" content-typ
       </attribute>
 
       <attribute name="deny" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client's IP address is compared to.  If this attribute
         is specified, the remote address MUST NOT match for this request to be
         accepted.  If this attribute is not specified, request acceptance is
@@ -604,7 +604,7 @@ FINE: Request "/docs/config/manager.html" with response status "200" content-typ
     <attributes>
 
       <attribute name="allow" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client&apos;s hostname is compared to.  If this attribute
         is specified, the remote hostname MUST match for this request to be
         accepted.  If this attribute is not specified, all requests will be
@@ -613,7 +613,7 @@ FINE: Request "/docs/config/manager.html" with response status "200" content-typ
       </attribute>
 
       <attribute name="deny" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client's hostname is compared to.  If this attribute
         is specified, the remote hostname MUST NOT match for this request to be
         accepted.  If this attribute is not specified, request acceptance is
index 36069fb..fc54c73 100644 (file)
     incoming request directed to the surrounding
     <a href="engine.html">Engine</a>, <a href="host.html">Host</a>, or
     <a href="context.html">Context</a> element.  The remote address or name
-    will be checked against a configured list of "accept" and/or "deny"
-    filters, which are defined using the Regular Expression syntax supported
-    by the <a href="http://jakarta.apache.org/regexp/">Jakarta Regexp</a>
-    regular expression library.  Requests that come from locations that are
+    will be checked against configured "accept" and/or "deny"
+    filters, which are defined using <code>java.util.regex</code> Regular
+    Expression syntax.  Requests that come from locations that are
     not accepted will be rejected with an HTTP "Forbidden" error.
     Example filter declarations:</p>
 
 &lt;Host name="localhost" ...&gt;
   ...
   &lt;Valve className="org.apache.catalina.valves.RemoteHostValve"
-         allow="*.mycompany.com,www.yourcompany.com"/&gt;
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/&gt;
   &lt;Valve className="org.apache.catalina.valves.RemoteAddrValve"
-         deny="192.168.1.*"/&gt;
+         deny="192\.168\.1\.\d+"/&gt;
   ...
 &lt;/Host&gt;
 </source>
index a1e43c7..52319a7 100644 (file)
       </attribute>
 
       <attribute name="allow" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client&apos;s IP address is compared to.  If this attribute
         is specified, the remote address MUST match for this request to be
         accepted.  If this attribute is not specified, all requests will be
       </attribute>
 
       <attribute name="deny" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client's IP address is compared to.  If this attribute
         is specified, the remote address MUST NOT match for this request to be
         accepted.  If this attribute is not specified, request acceptance is
       </attribute>
 
       <attribute name="allow" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client&apos;s hostname is compared to.  If this attribute
         is specified, the remote hostname MUST match for this request to be
         accepted.  If this attribute is not specified, all requests will be
       </attribute>
 
       <attribute name="deny" required="false">
-        <p>A regular expression (using <code>java.util.Regex</code>) that the
+        <p>A regular expression (using <code>java.util.regex</code>) that the
         remote client's hostname is compared to.  If this attribute
         is specified, the remote hostname MUST NOT match for this request to be
         accepted.  If this attribute is not specified, request acceptance is