This week's book giveaway is in the JavaFX forum.
We're giving away four copies of Introducing JavaFX 8 Programming and have Herbert Schildt on-line!
See this thread for details.
The moose likes Tomcat and the fly likes Disable dir listing in tomcat Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Introducing JavaFX 8 Programming this week in the JavaFX forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Disable dir listing in tomcat" Watch "Disable dir listing in tomcat" New topic
Author

Disable dir listing in tomcat

Brian Daniel
Greenhorn

Joined: Oct 30, 2001
Posts: 11
If I point a browser at the root of my webapp
http://host/mywebapp/
I get a directory listing. Also works for all subdirs. How do I disable this?
Brian Daniel
Greenhorn

Joined: Oct 30, 2001
Posts: 11
N/m, finally found it myself. In tomcat 4.0+ in $CATALINA_HOME/conf/web.xml, change the listings parameter in the default servlet declaration to false.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Disable dir listing in tomcat
 
It's not a secret anymore!