Summary: | java.io.FileNotFoundException while deploying web application with white space in the context root | ||
---|---|---|---|
Product: | Tomcat 7 | Reporter: | polina.genova |
Component: | Catalina | Assignee: | Tomcat Developers Mailing List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | trunk | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | All | ||
Attachments: |
Test web application.
Patch proposal. |
Description
polina.genova
2013-01-03 17:29:11 UTC
Created attachment 29810 [details]
Patch proposal.
For the record, Tomcat 8 is not affected by this bug as it uses a new resources implementation. Thanks for the patch. The patch has been applied to 7.0.x and will be included in 7.0.35 onwards. Hi, Thanks for approving the patch. However I accidently noticed that the fix is not correctly working if the context root contains any of the characters: ‘~’,’&’, ‘;’, ‘+’. This is because these characters are not encoded in the string returned by getURL().getFile() (unlike white space for example) while they get encoded by the URL_ENCODER.encodeURL() method. I’m currently thinking how to overcome this inconformity. Thanks and regards, Polina |