Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 51570E090 for ; Tue, 4 Dec 2012 17:25:46 +0000 (UTC) Received: (qmail 45068 invoked by uid 500); 4 Dec 2012 17:25:42 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 45007 invoked by uid 500); 4 Dec 2012 17:25:42 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 44993 invoked by uid 99); 4 Dec 2012 17:25:42 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Dec 2012 17:25:42 +0000 X-ASF-Spam-Status: No, hits=0.7 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [76.96.62.80] (HELO qmta08.westchester.pa.mail.comcast.net) (76.96.62.80) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Dec 2012 17:25:35 +0000 Received: from omta03.westchester.pa.mail.comcast.net ([76.96.62.27]) by qmta08.westchester.pa.mail.comcast.net with comcast id XTFh1k0040bG4ec58VRDhp; Tue, 04 Dec 2012 17:25:13 +0000 Received: from Christophers-MacBook-Pro.local ([69.143.109.145]) by omta03.westchester.pa.mail.comcast.net with comcast id XVRC1k00U38FjT13PVRD6o; Tue, 04 Dec 2012 17:25:13 +0000 Message-ID: <50BE31F7.7030809@christopherschultz.net> Date: Tue, 04 Dec 2012 12:25:11 -0500 From: Christopher Schultz User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Context Path for a subdirectory References: <99C8B2929B39C24493377AC7A121E21FC4947E68A3@USEA-EXCH8.na.uis.unisys.com> <50B90E20.2000907@tmbsw.com> <99C8B2929B39C24493377AC7A121E21FC4948CD8EC@USEA-EXCH8.na.uis.unisys.com> <50B92DB1.3000201@christopherschultz.net> <99C8B2929B39C24493377AC7A121E21FC4948CDC2E@USEA-EXCH8.na.uis.unisys.com> <50B9359C.8060209@christopherschultz.net> ,<50B975C1.4060805@christopherschultz.net> <50BD3ABA.1040605@ice-sa.com> In-Reply-To: <50BD3ABA.1040605@ice-sa.com> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20121106; t=1354641913; bh=f+JMTLGtmCdYMqtBai8QYuFxc6Ref0jeRpaKqjkBdkg=; h=Received:Received:Message-ID:Date:From:MIME-Version:To:Subject: Content-Type; b=P0GfcLzY6UZl4DRf9oTqIwQG4woEjq3ICzlsVjJLhXT2V9c55wtUwiIHvvaZguCxc ZT1fHPVDwoa5EG0XZpIe7F2762iIxAwVXfTm3DR4Ve8jXNAaS2m7Yp50PcjT2PWTlG VADvQFMTXlANR6QI9qtZYjFpjlXJN3XN/fOXx23X3CptvMoYWMWMk1HGd91nYIL47z z5PMRJaJywVj3yfD6049msEaCnSjd25w9Oznl5gc2yuas+CYpRiJwnJLBYRJvyx1+w Ybav91u9wY9em1YfJx5p3NjYm85YE5IXCJdh+3B1rgaRZTf6qlg6smYSvxoK5Pv52/ MgdntcmegLzGw== X-Virus-Checked: Checked by ClamAV on apache.org -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 André, On 12/3/12 6:50 PM, André Warnier wrote: > P.S. If you decide to use UrlRewriteFilter, you should be looking > at the documentation > (http://urlrewritefilter.googlecode.com/svn/trunk/src/doc/manual/4.0/index.html), Cool, > there's a 4.0 version. And it supports mod_rewrite syntax? Very cool. > and at a rule using this in the part : > > remote-addr : The IP address of the host making the request, e.g. > 123.123.123.12 i.e. request.getRemoteAddr() (you probably want to > negate this, and check for "not (127.0.0.1 or ::1)") > > and probably this in the part : forward (default) : > > Requests matching the "conditions" for this "rule", and the URL in > the "from" element will be internally forwarded to the URL > specified in the "to" element. Note: In this case the "to" URL must > be in the same context as UrlRewriteFilter. This is the same as > doing: RequestDispatcher rq = request.getRequestDispatcher([to > value]); rq.forward(request, response); (to forward the miscreants > to a no-no page of your choice.) If you haven't used url-rewrite before, it may seem a bit daunting. Here's an example to get you started: 127.0.0.1 403 /forbidden.html Hope that helps, - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEARECAAYFAlC+MfcACgkQ9CaO5/Lv0PAMpQCcDD7oMUAzuTe1xKeuMpm665SR FjIAn0jE67iGpGMDH9HqjqXFBoa4JFdp =FdT5 -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org