上QQ阅读APP看书,第一时间看更新
Enabling and disabling the file listing
It's generally not advisable to enable directory listing in your application. By default directory listing will be disabled on JBoss.
If it is enabled, go to your JBoss installation folder.
How to do it...
The following steps will help to disable and enable file listing in the application server:
- Browse to the path
\server\default\deployers\jbossweb.deployer
. - Open
web.xml
in theWEB-INF
folder. - Set the listing to
false
.<servlet> <servlet-name>default</servlet-name> <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class> <init-param> <param-name>debug</param-name> <param-value>0</param-value> </init-param> <init-param> <param-name>listings</param-name> <param-value>false</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet>
See also
- The Spring Security with Struts2 recipe