[advanced search]
Results from the most recent live auction are here.
15 members in the live chat room. Join Chat!
Register Rules & FAQ NP$ Store Active Threads Mark Forums Read
Go Back   NamePros.Com > Design and Development > Programming > CODE
User Name
Password

Old 07-21-2005, 08:52 PM   · #1
i386
NamePros Member
 
Trader Rating: (3)
Join Date: Oct 2003
Posts: 126
NP$: 182.00 (Donate)
i386 is an unknown quantity at this point
.htaccess: Prevent users from seeing private directories!

This isn't really 'code,' but it's similar to code.

If you have include directories, template directories, or other private directories, why allow users to access them? Instead, use mod_rewrite!

If you have include/ and want to hide it, add this to your .htaccess file:

Code:
RewriteEngine On RewriteRule ^include$ /dev/null RewriteRule ^include/(.*)$ /dev/null


You can use that again, but just remove "RewriteEngine On" and change "include" to the directory you want to hide.

10,000,000 in 10,000,001 servers have mod_rewrite.

I would also like to note that all PHP scripts or Perl scripts can access the files, even with this.


Please register or log-in into NamePros to hide ads
i386 is offline   Reply With Quote
Old 07-27-2005, 01:13 AM   · #2
dpk87
Senior Member
 
Trader Rating: (23)
Join Date: Jun 2003
Posts: 821
NP$: 19.00 (Donate)
dpk87 is a jewel in the roughdpk87 is a jewel in the roughdpk87 is a jewel in the rough
Also, for people using cpanel, in he protect directories feature it will write an htaccess file for you.
dpk87 is offline   Reply With Quote
Closed Thread

NamePros is a revenue sharing forum.

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Resellers starting at $9.99/mo with Free ClientExec, RVSkin, Private NS, and more! Virpus Web Hosting Offers 0 07-12-2005 10:51 PM
Reseller - 9GB Space, 95GB BW, ClientExec, RVSkin, SubReselling, Private NS $24.99/mo Virpus Web Hosting Offers 2 07-11-2005 09:03 PM
RESELLER:4GB Space, 140GB BW, ClientExec, RVSkin, SubReselling, Private NS, $18.99/mo Virpus Web Hosting Offers 0 07-05-2005 10:13 AM
Resellers as low as $9.99/mo WITH ClientExec, Private NS, SubReselling and MORE Virpus Web Hosting Offers 0 05-22-2005 07:51 PM
Interesting reading From bobparsons.com slipondajimmy Industry News 0 03-05-2005 05:17 PM

Site Sponsors
Proof is in the Parking EscrowDNS Hunting Moon
Advertise your business at NamePros
All times are GMT -7. The time now is 12:22 PM.


Powered by: vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0