tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Rumney <jrum...@att.com>
Subject Re: How to make mod_rewrite works with Tomcat ?
Date Tue, 15 Aug 2000 14:02:00 GMT
"Kwan, Kenneth Y" <kenneth.y.kwan@cwhkt.com> writes:

> I have gone through many docs in tomcat FAQ / user guide /etc, Apache web
> config, JServ mailing list achieve, !K However, I still can't make
> "mod_rewrite" and "mod_jserv" (tomcat) work together. 
> 
> My target is to config Apache and Tomcat so that when users access
> /protected/*.html, the accesses are verified by an authentication servlet
> say / servlet/SnoopServlet. I have configured Apache Web server with the
> rewrite rules below:
> 
> <Location /protected>
> RewriteEngine on
> RewriteRule     (.*)            /servlet/SnoopServlet?target=$1 [L]
> </Location>

Try the following:

RewriteRule     (.*)        /servlet/SnoopServlet?target=$1 [L,T=jserv-servlet]


This will force the type of the request to "jserv-servlet", which is
associated with mod_jserv.

In my experience, it does not matter what order the mod_jserv and
mod_rewrite directives are in, the rewritten URL does not pick up the
"jserv-servlet" type unless you explicitly force it.



-- 
Jason Rumney <jrumney@att.com>
AT&T Labs (Redditch, UK)


Mime
View raw message