You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Ricardo Bayley <ri...@gmail.com> on 2011/09/13 19:58:31 UTC
Valves
Hi folks,
I am new to tomcat.
I use a webapp which runs in tomcat. I would like tomcat to filter requests
according to remote host / address.
I understand I need to set "Remote Address Filter" and the "Remote Host
Filter" in the Valve component.
I read this articles but I don't understand where or which xml file to
edit.
http://tomcat.apache.org/tomcat-6.0-doc/config/valve.html
http://www.oxxus.net/tutorials/tomcat/tomcat-valve
Can anyone tell me where should I configure it ?
Any pointers are appreciated.
Warm regards,
Ricardo
RE: Valves
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Ricardo Bayley [mailto:ricardo.bayley@gmail.com]
> Subject: Valves
> I read this articles but I don't understand where or which
> xml file to edit.
> Can anyone tell me where should I configure it ?
You configure the <Valve> at the desired scope. If you want it to affect only the one webapp, place it in the <Context> element for that webapp. If you want it for a specific <Host>, place it there. If you want it to operate on everything, configure it in the <Engine>.
- Chuck
THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.
Re: Valves
Posted by David Bernard <Da...@intact.net>.
Here the search result in tomcat 6.0 installation:
F:\Tomcat 6.0\conf
Searching for: valves
context.xml(32): <Valve
className="org.apache.catalina.valves.CometConnectionManagerValve" />
server.xml(19): define subcomponents such as "Valves" at this level.
server.xml(50): so you may not define subcomponents such as "Valves" at
this level.
server.xml(115): <Valve
className="org.apache.catalina.valves.RequestDumperValve"/>
server.xml(141): <Valve
className="org.apache.catalina.valves.AccessLogValve" directory="logs"
Found 5 occurrence(s) in 2 file(s)
Also,
look with your url below
http://www.oxxus.net/tutorials/tomcat/tomcat-valve
you will find the file name you looking for /conf/server.xml
<Valve className="org.apache.catalina.valves.RequestDumperValve"/>
To use the RequestDumperValve, you simply need to add this entry to the
Tomcat container that you would like to monitor. To see this valve in
action, open the current <TOMCAT_HOME>/conf/server.xml, uncomment the
previously listed line found in the Standalone engine, and restart Tomcat.
Now make a request to any of the applications found at
http://localhost:8080.
/DB
From: Ricardo Bayley <ri...@gmail.com>
To: users@tomcat.apache.org
Date: 2011-09-13 02:37 PM
Subject: Valves
Hi folks,
I am new to tomcat.
I use a webapp which runs in tomcat. I would like tomcat to filter requests
according to remote host / address.
I understand I need to set "Remote Address Filter" and the "Remote Host
Filter" in the Valve component.
I read this articles but I don't understand where or which xml file to
edit.
http://tomcat.apache.org/tomcat-6.0-doc/config/valve.html
http://www.oxxus.net/tutorials/tomcat/tomcat-valve
Can anyone tell me where should I configure it ?
Any pointers are appreciated.
Warm regards,
Ricardo
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org