tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ivan Ivanov <rambiusparkisan...@yahoo.com>
Subject Tomcat/Apache web server communication
Date Fri, 28 Nov 2003 17:46:35 GMT
Dear colleagues,

Please help in the following situation.
We are cuurently developing a web application based on
Tomcat4.1. Thus web app allows a user to upload files
and folders in a subdirectory of its context, so that
the content of these folders be viewed or retrieved by
other users. The folders can contain static html
pages, jpgs, zip files, etc. However, a user has
uploaded some large video files, that create problems
when played through internet and place unnecessary
burden and the web app hangs or behaves badly.
As a solution, I decided to install Apache Web Server
and move these static files in Apache, so that Apache
will serve the static content. (Installation of Apache
and mod_jk2 connector is OK). 
However, the subdirectory in the webapp conext in
which reside the uploaded files and folders is a
"restricted " area. When an user wants to access a
file in it, a filter (extends javax.servlet.Filter) is
invoked and checks according to some rules if the user
has enough rights and if so gives him the requested
resource.
My question is, if I move the subdirectory with the
uploaded files in Apache Web Server, how should I
configure Apache so that it can be reached only from
Tomcat and only when the filter permits?

In short if we have 
1) the url of ourwebapp is
http://somehost:8080/ourwebapp, 
2)the directory with uploaded stuff is uploaddir and
is accessed by
http://somehost:8080/ourwebapp/uploaddir
3) every time a user tries to access
http://somehost:8080/ourwebapp/uploaddir/somefolder/somefile
the filter checks his rights,
and we move uploaddir and its contents in Apache, how
should I set up Apache and eventually the filter?

Thanks in advance for your help.
Kind Regards Ivan Ivanov

__________________________________
Do you Yahoo!?
Free Pop-Up Blocker - Get it now
http://companion.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message