• The Facebook Platform

Results 1 to 1 of 1
  1. #1
    Join Date
    Jan 2010
    Location
    Lahore, Pakistan
    Age
    25
    Posts
    3,818
    Points
    6,772.51
    Rep Power
    10000

    Default How to prevent or allow directory listing? With .htaccess

    How to prevent or allow directory listing?

    Having a listable directories on your site sometimes is useful. However, some times it can be considered a security issue. No, matter which option you prefer you can control this behavior of your site using 1 simple line:

    Code:
    Options +Indexes
    The above line enables Directory listing.
    Code:
    Options –Indexes
    The above disables directory listing for your web site.
    The .htaccess file gives more then simply enabling and disabling of a directory listing.
    With .htaccess file you can control which files to be ignored when creating a directory list.
    For example:


    Code:
    IndexIgnore *.gif *.zip *.txt
    Will make the apache server to skip all gif, zip and txt files from the directory list.
    Convenient, isn’t it.

    Code:
    IndexIgnore *
    Will just create an empty directory list.







    Find Me On Social Networks

    Facebook | Twitter | Google+



 

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Tags for this Thread

Posting Permissions

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