users@jersey.java.net

Re: [Jersey] Escaping a PathParam slash

From: dloy <david.loy_at_ucop.edu>
Date: Tue, 18 Aug 2009 14:39:57 -0700

Hi Paul
Many thanks - that did the trick:

tomcat/bin/setenv.bat
set
CATALINA_OPTS="-Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true"

Also, another thanks on the logger - very useful.
David

Paul Sandoz wrote:
> On Aug 18, 2009, at 8:00 PM, dloy wrote:
>> URL: http://localhost:28080/jjersey/testIt/test/first/second%2fthird
>>
>> Jersey Log: NONE
>>
>> Firefox:
>> HTTP/1.x 400 Bad Request
>> Server: Apache-Coyote/1.1
>> Content-Length: 0
>> Date: Tue, 18 Aug 2009 17:53:57 GMT
>> Connection: close
>>
>>
>> -------------------------------------------------------------------------------
>>
>>
>> I'm not sure where the 400 is being create - tomcat?
>>
>
> Yes. It is a Tomcat thing. IMHO i think it is a bug, but it seems to
> be positioned as some security feature, probably because of legacy
> code issues of stuff not working correctly in URL encoded space.
>
>
>> I hope you have an idea on this.
>>
>
> See here:
>
> http://tomcat.apache.org/tomcat-5.5-doc/config/systemprops.html
>
> org.apache.tomcat.util.buf. UDecoder.ALLOW_ENCODED_SLASH
>
> Paul.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>