Certified Application Security Engineer – Java (CASE-Java) — Question 13

Oliver is a web server admin and wants to configure the Tomcat server in such a way that it should not serve index pages in the absence of welcome files. Which of the following settings in CATALINA_HOME/conf/ in web.xml will solve his problem?

Answer options

Correct answer: A

Explanation

The correct setting is option A, which configures the 'listings' parameter to 'false', preventing the server from displaying directory listings when no welcome files are present. Options B, C, and D either incorrectly use 'disable', 'enable', or 'true' for the listings parameter, which would allow the server to serve index pages or directory listings, contradicting Oliver's requirement.