Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: How do I get around mod_security precondition failed the way Txp does?
Hi Els
this is what I have in the htaccess
ErrorDocument 404 http://www.neme.org/oops.php
#general 404 redirection
RedirectMatch 301 /forum(.*) http://forum.neme.org/$1
#redirects from directory to subdomain
SecFilterEngine On
SecFilterSelective "REQUEST_URI" "http://forum.neme.org/post.php" "allow,nolog"
# helps forum to function
SecFilterSelective REMOTE_ADDR ^xxx.xxx.xxx.xxx$ nolog,allow
#Allows my ip to bypass security
#SecFilterEngine Off
# Uncomment in case of trouble:)
#DirectoryIndex index.php index.html
#Options +FollowSymLinks
#RewriteBase /relative/web/path/
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^neme\.org$
RewriteRule (.*) http://www.neme.org/$1 [R=301,L]
# rewrite to include www
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^(.+) - [PT,L]
RewriteRule ^(.*) index.php
</IfModule>
#php_value register_globals 0
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
#14 2007-05-14 18:17:15
- els
- Moderator
- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: How do I get around mod_security precondition failed the way Txp does?
colak
Forgot to thank you :) It just didn’t seem to work for me, and today I decided to try once more, copied your line SecFilterSelective REMOTE_ADDR ^xxx.xxx.xxx.xxx$ nolog,allow
to my .htaccess, put my IP in it, and guess what? It just worked. Though I honestly multiple-checked at the time, I can’t think of anything else keeping it from working than that I overlooked a typo…
And your way of commenting your .htaccess is very helpful. I am going to follow your example.
Offline
#15 2012-12-20 22:50:44
- kr37
- Member
- From: Colorado
- Registered: 2011-11-06
- Posts: 28
Re: How do I get around mod_security precondition failed the way Txp does?
I was getting similar 404 errors when clicking Save on various pages, such as SMD Plugin Composer, and contacted my host provider. They turned of mod_security and now everything works again.
Offline