Apache-based Comment Spam Fix for Word Press and other software — works!
-
I blogged this at https://www.dvorak.org —
Marc Perkel at ctyme.com a€“ my host a€?? was floored, he said, when he realized a simple command to the Apache software would kill most of it a€?? and it does indeed work!
Here is the short code running on the ctyme server for my dvorak.org using WordPress-based blogging software. Altering it for other blog software and other blogs should be simple for anyone running Apache.
<Location /blog/wp-comments-newpost.php>
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^.*dvorak.org/.*
RewriteRule ^.* https://www.ctyme.com/comment-spam.html
</Location>(this may not render correctly in this comment box — go to the blog to see it)
Essentially it makes the basic condition for any post rigid: it has to be coming from a link within the blog itself, the a€?commenta€? link. Most spam does not.
My spam count on the blog has dropped from 50-100 to 2 per day without any other tricks.
- The topic ‘Apache-based Comment Spam Fix for Word Press and other software — works!’ is closed to new replies.