[Geoserver-devel] Online Resource URLs being valid through a proxy

Hi folks,

got an issue I can't locate any discussion or documentation for, but may be addressed already:

When you put geoserver in tomcat behind Apache, and rewrite the base URL (which you will need to do in many cases, for a variety of reasons) the capabilities document returns an incorrect OnlineResource attribute in the <capabilities> section.

Either explicit instructions on how to avoid this from a tomcat/apache guru, or a code fix to allow hard configuration, or a doc fix if this option is already there is required it seems

Any pointers?

Rob Atkinson

On Tue, 21 Jun 2005, Rob Atkinson wrote:

Hi folks,

got an issue I can't locate any discussion or documentation for, but may
be addressed already:

When you put geoserver in tomcat behind Apache, and rewrite the base URL
(which you will need to do in many cases, for a variety of reasons) the
capabilities document returns an incorrect OnlineResource attribute in
the <capabilities> section.

Either explicit instructions on how to avoid this from a tomcat/apache
guru, or a code fix to allow hard configuration, or a doc fix if this
option is already there is required it seems

Any pointers?

I feel like I've heard a fix for this in the tomcat/apache guru way in the
past, but I'm not one, so I don't know it. The code is in
org.vfny.geoserver.util.Requests, method is getBaseUrl(). I think it's
generally pretty good at figuring out where the request is coming from,
and I'm pretty sure people have had it through apache with no problems.
It uses the httpservletrequest stuff:
return "http://" + httpServletRequest.getServerName() + ":"
        + httpServletRequest.getServerPort() +
httpServletRequest.getContextPath() +"/";

So right there you could just hard code. If you find a fix through
apache/tomcat configuration do post it on the wiki.

Chris

Rob Atkinson

-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

--