tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martin Jericho" <marti...@jabmail.com>
Subject Deployment on a specific port
Date Fri, 12 Sep 2003 00:45:59 GMT
I would like to set up a single standalone instance of tomcat with connectors on two ports,
and deploy one servlet to work only on one port and a different servlet to work only on the
other port.  Is this possible?

If not, the only way I can get around it that I can see is to use the ServletRequest.getServerPort()
method to check which port the request came in on an reject it if it was on the wrong port.
 I suspect however that this is not secure as the value returned by getServerPort() comes
from the request header, which can easily be spoofed.  Will the ServletRequest.getLocalPort()
method in the proposed 2.4 spec be more secure?

How are other people doing this?
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message