You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2010/09/29 17:57:26 UTC

DO NOT REPLY [Bug 50026] DefaultServlet serves META-INF and WEB-INF from root when remapped on /folder/*

https://issues.apache.org/bugzilla/show_bug.cgi?id=50026

--- Comment #1 from Pid <pi...@apache.org> 2010-09-29 11:57:22 EDT ---
(In reply to comment #0)
> The following in web.xml
> 
>     <servlet>
>         <servlet-name>static</servlet-name>
>        
> <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
>     </servlet>
>     <servlet-mapping>
>         <servlet-name>static</servlet-name>
>         <url-pattern>/static/*</url-pattern>
>     </servlet-mapping>

URL patterns are application-relative.

> makes restricted folders accessible by e.g.
> 
> http://localhost:8080/context/static/WEB-INF/web.xml
> http://localhost:8080/context/static/META-INF/MANIFEST.MF

The directories you refer to aren't in use by the app called 'context', so
they're just ordinary directories which happen to duplicate the special name.
The actual special directories would be here:

 http://localhost:8080/context/WEB-INF/web.xml 
 http://localhost:8080/context/META-INF/MANIFEST.MF

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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