« AspectJ launches campaign for world peace ;) | Main | Even more AspectJ goodies... »

January 21, 2005

The war against blog spam

Like many others running blogs on movabletype I've been hit by a huge increase in spam commenters recently. I had to switch on comment moderating a long time ago to stop unsavoury comments appearing on the site. Now all comments are moderated but I've been getting hundreds of spam comments to moderate (on-line poker seems especially popular for some reason - could be worse I guess). The result is that i'm sure I've deleted a few genuine comments in amongst all the noise - if that's happened to you please accept my apologies.

Today I've taken a few more steps in the war against spam and upgraded my MovableType installation, and installed the nofollow and MTBlacklist plugins. If only it was as simple as deploying an aspect into the system:

aspect SpamRemoval { after(Comment c) returning : spamCommentArrival(c) { c.delete(); } }

Maybe one day I'll be able to script this easily....

Posted by adrian at January 21, 2005 06:31 PM [permalink]


MTBlacklist is a waste of time.
You need to install scode (http://james.seng.cc/archives/000145.html) and turn moderation off :)

Posted by: RefuX at January 21, 2005 08:56 PM

SixApart posted a good summary of anti-spam techniques for MT recently: http://sixapart.com/pronet/comment_spam.html. I'm working my way through it, trying to balance accessibility against manageability. I'll keep adding in more lines of defense until the problem is under control, so you may yet see scode on this site soon...

Posted by: Adrian at January 22, 2005 06:58 AM

I was thinking about that SpamRemoval aspect. Why allow comments to hit the database and then delete them afterwards. This version is much better:

aspect SpamRemoval {

pointcut commentArrival(Comment c) :
execution(void addComment(Comment)) && this(c);

void around(Comment c) : commentArrival(c) {
if (isSpam(c)) return;


That's the nice thing about aspects, if I want to change the way I do spam removal, I just have to change the spam removal module.

Back to the real world...

Posted by: Adrian at January 22, 2005 08:16 AM

Post a comment

Thanks for signing in, . Now you can comment. (sign out)

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)

Remember me?