Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2008
    Location
    Chicago, Illinois
    Posts
    648

    Disable directory browsing

    Hi Guys

    Please tel me how to disable directory browsing on centOS? Please tel me step by step.

    Thank you

    Alex

  2. #2
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    8,910
    Create a .htaccess file in the directory and add the following line:

    Options -Indexes

    Are you looking to disable them server-wide or only for a specific directory / account?
    Patrick William | RACK911 Labs | Software Security Auditing
    400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com

    www.HostingSecList.com - Security notices for the hosting community.

  3. #3
    Join Date
    Sep 2008
    Location
    Chicago, Illinois
    Posts
    648
    Thank you for your quick reply. I need to apply for whole server. ( For all domains ) Please let me know.


    Quote Originally Posted by Patrick View Post
    Create a .htaccess file in the directory and add the following line:

    Options -Indexes

    Are you looking to disable them server-wide or only for a specific directory / account?

  4. #4
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    8,910
    Quote Originally Posted by ALEXEI_M View Post
    Thank you for your quick reply. I need to apply for whole server. ( For all domains ) Please let me know.
    Edit /usr/local/apache/conf/httpd.conf and look for the following directive:

    <Directory "/">
    Options ExecCGI FollowSymLinks Includes IncludesNOEXEC Indexes -MultiViews SymLinksIfOwnerMatch
    AllowOverride All
    </Directory>

    Change Indexes to -Indexes and then restart Apache. If Indexes are not present then you can add -Indexes instead. The directive will probably look a little bit different then what I have above but the <Directory "/"> line should still be there to help you find the right section.

  5. #5
    Join Date
    Sep 2008
    Location
    Chicago, Illinois
    Posts
    648
    Wow .. Now its working.. Thank you very much for your support. Many many thanks.

    Alex

Similar Threads

  1. globally disable direcory browsing on WHM server
    By Zaggs in forum Hosting Security and Technology
    Replies: 8
    Last Post: 03-01-2011, 10:53 AM
  2. how to disable directory browsing ?
    By goolex in forum Hosting Security and Technology
    Replies: 1
    Last Post: 01-25-2005, 06:01 PM
  3. how do I disable "directory browsing"
    By kipasa in forum Hosting Security and Technology
    Replies: 13
    Last Post: 10-11-2003, 06:17 PM
  4. Directory Browsing
    By Shepski in forum Dedicated Server
    Replies: 2
    Last Post: 12-21-2001, 09:35 AM
  5. Directory Browsing?
    By sigsys in forum Dedicated Server
    Replies: 3
    Last Post: 12-13-2000, 10:38 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •