You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by RichKi <ri...@blueyonder.co.uk> on 2009/07/30 19:10:47 UTC

ISAPI Redirect and uriworkers.properties

Does anyone know if it's possible to filter by port number?

I have an application running on port 3030 in Apache that also runs securely
on port 8443.

Incoming connections come to IIS on ports 80 and 443 respectively and are
picked up by the ISAPI redirect filter (URL is /ufs). 

What I want to do is map the 80 connections 3030 and the 443 to 8443. At the
moment, all /ufs requests go to 3030 as I can't seem to differentiate.

Can anyone help?

Thanks
-- 
View this message in context: http://www.nabble.com/ISAPI-Redirect-and-uriworkers.properties-tp24742761p24742761.html
Sent from the Tomcat - Dev mailing list archive at Nabble.com.


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


Re: ISAPI Redirect and uriworkers.properties

Posted by Rainer Jung <ra...@kippdata.de>.
What I forgot: The question belongs on the users list
users@tomcat.apache.org.

Please continue the discussion there.

Regards,

Rainer

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


Re: ISAPI Redirect and uriworkers.properties

Posted by Rainer Jung <ra...@kippdata.de>.
On 30.07.2009 19:10, RichKi wrote:
> Does anyone know if it's possible to filter by port number?
> 
> I have an application running on port 3030 in Apache that also runs securely
> on port 8443.
> 
> Incoming connections come to IIS on ports 80 and 443 respectively and are
> picked up by the ISAPI redirect filter (URL is /ufs). 
> 
> What I want to do is map the 80 connections 3030 and the 443 to 8443. At the
> moment, all /ufs requests go to 3030 as I can't seem to differentiate.
> 
> Can anyone help?

It doesn't look good. If the ports were non-standard, the answer would
be yes. The ISAPI plugin does two checks against
uriworkermap.properties, it searches for a match using the URI path of
the request, but also for a match using /HOST/path. This match is done
first. So if your requests go to different HOSTs, then you can define
different forwarding rules in uriworkermap.properties.

So what do we use as a value for HOST?

It is the SERVER_NAME, and if the port is neither 80 nor 443 we also add
":PORT" add the end. In your case, since they are the default ports, you
can't distinguish using the ports.

What is SERVER_NAME? You can find out the SERVER_NAME your configuration
uses by setting the JK log level to debug (do not do this on a high
trafic production site). Then you'll get lots of logging, and one line
you can look for has the format:

Service protocol=... name=...

The value occuring directly behind "name=" is the SERVER_NAME we are
looking for in uriworkermap.properties. Now have a look, where this name
appears in your IIS configuration.

You might be able to split the definition of the port 80 and port 443
web sites from each other in IIS using different SERVER_NAMEs.

It would be better if we did three runs through uriworkermap.properties,

- first match against host+port+path even for default ports
- then match against host+path
- then match against path

but that's not how it works at the moment.

Regards,

Rainer

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