tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: request.getPathInfo() gets truncated when ";" is present
Date Fri, 24 Jul 2009 19:23:43 GMT
Hash: SHA1


On 7/24/2009 3:58 AM, Peter J. Farrell wrote:
> @Bill, thanks for mentioning the specific RFC referencing the encoding
> of ";".  That's what the team here figured out as well and it's nice to
> have an independent person verify our assumptions after reading the RFC
> sections.  Is it safe to assume that Tomcat code base assumes that
> anything after the ";" has to be the jsessionid?  That's our assumption
> at the moment.  Yes, there is a work around by using the
> request.getRequestURI()  instead as that has the whole URI and manually
> remove the "absolute" path to get the complete path info.
> Since our framework is deployed on several different CFML servlets --
> their implementation to get at the original http request wrapper differs
> a bit (three different vendors).  We'll probably stick to use the poor
> man's encoding using a modified unicode representation of ";" in the
> end.  Another solution is to write a filter and use the getRequestURI()
> and replace the bad path info in the request with the full length version.

You could implement a Filter that wraps the request for these servlets.
The wrapped request would override the getPathInfo method and perform
the reverse-engineering of the path info you describe above.

This would allow you to "patch" your servlets all at once without
actually modifying their code, and without going through the backflips
of an alternate URI encoding.

You could also log a bug and see what happens. As Bill points out,
nobody has been motivated to fix this issue. If you log a bug and get
some feedback, perhaps you could fix it yourself and submit a patch (if
you're motivated). Or, maybe some other kind soul will submit a patch
for it. Since you are motivated to have it work for your application,
you are a good candidate to fix it :)

- -chris
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla -


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message