Toggle navigation
Dashboard
Dashboard Tracker
Add / Edit My Forums
System Announcements
Discussion
Active Thread Feed
Top Threads Today
Top Threads This Week
Top Threads Library
Go!
View All
View All
Login
Logout
Home
Forums Index
Server Side
/
Apache Web Server
9:07 pm May 21, 2026
This page requires javascript.
Forum Moderators:
phranque
Message Too Old, No Replies
"Protecting" the htaccess file.
Is this suitable code?
Broadway
Msg#:4184475
9:44 pm on Aug 9, 2010
(gmt 0)
While reading about .htaccess files I saw mention of this code as a way of "protecting" the htaccess file itself.
<Files .htaccess>
Order Allow,Deny
Deny from all
</Files>
Any reason not to do this?
mack
Msg#:4184482
9:57 pm on Aug 9, 2010
(gmt 0)
The htaccess should be protected by the apache configuration file. The following will generaly be found within the apache2.conf or httpd.conf
<Files ~ "^\.ht">
Order allow,deny
Deny from all
Satisfy all
</Files>
What this does is prevent a browser or client from being able to see or read the .htaccess or .htpasswd files.
Mack.
Broadway
Msg#:4184537
12:36 am on Aug 10, 2010
(gmt 0)
thanks
Join The Conversation
Register
For Free! -
Become a
Pro Member
!
See forum categories
-
Enter the Forum
Moderators and Top Contributors
Moderator List
| Top Contributors:
This Week
,
This Month
,
Apr
,
Mar
,
Archive
,
Top 100 All Time
,
Top Voted Members
Hot Threads This Week
May 2026 Google Search Observations
AdSense Earnings and Observations - May 2026
AI visibility audit
Adsense / Personal Manager / Support
Hacker spoofing as GoogleBot
Page indexed but live url test gets 500 error
Link collaboration strategies
in case you missed it .
Microsoft, AS8075. Google, AS396982.
Bad actor claiming to be OpenAi
Home
Forums Index
Server Side
/
Apache Web Server
9:07 pm May 21, 2026