How to disable the listing in a non-cPanel CentOS server?

1. Locate your httpd.conf file. Normally it is located at /usr/local/apache/conf or /etc/httpd/conf/httpd.conf

2. Open the httpd.conf file in text editor and search for the following line

#  Options Includes Indexes FollowSymLinks MultiViews

3.Remove the word Indexes

#  Options Includes FollowSymLinks MultiViews

4. Save modified httpd.conf and restart Apache

#  service httpd restart


You have successfully disabled the directory listing.

Was this answer helpful? 0 Users Found This Useful (0 Votes)