Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Security - Other
Author Message
TAd
Worker
Worker


Joined: Oct 11, 2004
Posts: 123
Location: Oregon, USA

PostPosted: Fri Mar 25, 2011 4:23 pm Reply with quote

Is there a site that can check syntax of an .htaccess file that you use and trust? I am trying to verify that my .htaccess file is working correctly and one site shows many errors... However the errors it reports are ones that appear to work... Try another site, and well, lets just say there is much inconsistency between the .htaccess syntax checkers. Very Happy
 
View user's profile Send private message Yahoo Messenger
Guardian2003
Site Admin


Joined: Aug 28, 2003
Posts: 6793
Location: Ha Noi, Viet Nam

PostPosted: Fri Mar 25, 2011 9:59 pm Reply with quote

To be honest, I don't think there is such a beast.
A lot of the directives should always be wrapped in the appropriate ifMdodule, in an effort to stop directives being executed if it isn't supported by the server. The Catch22 is that some servers do allow a specific directive but actually not allow the 'test' to see if the directive can be used - go figure!
So from that stand point, you cannot really test if an htaccess file is good or bad.

The only thing I I can say is that htaccess directives are executed in the order they are written (top to bottom). I order mine like this;
ban IP's
ban referrers
ban strings
ban exploits
error handling
shortlinks

I know NS puts IP's at the bottom but periodically I move them to the top because I don't see why I should be processing all those re-writes for Shortlinks if the IP/Domain should already be banned from getting that far.
 
View user's profile Send private message Send e-mail
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 17086

PostPosted: Fri Mar 25, 2011 10:14 pm Reply with quote

TAd wrote:
Is there a site that can check syntax of an .htaccess file that you use and trust? I am trying to verify that my .htaccess file is working correctly and one site shows many errors... However the errors it reports are ones that appear to work... Try another site, and well, lets just say there is much inconsistency between the .htaccess syntax checkers. Very Happy


Have you Googled for .htaccess syntax checker?
 
View user's profile Send private message
TAd
PostPosted: Sat Mar 26, 2011 3:15 am Reply with quote

Thank you Guardian, I will have to mull that information over. I had thought about cleaning up the htaccess a bit as it is getting a bit messy.

Raven, Yes I have, and ran my htaccess file through several of them. And therein is the problem. Never having used them before I am not sure which one to "trust" and they are all providing very different results. In a nutshell, that is what brought me here, to ask for opinions and or user experiences.

Thank you,
TAd
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Security - Other

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©