Anyone know of a simple way to add a whitelist to work together with the spam blacklist? I'd like to block all domains except my own and a couple of others from being posted while still allowing the blacklist work for generic terms. I guess it would mostly be an exception list or whitelist to go with some regex blocking domain combinations in the blacklist.
I'm using Wakaba.
I'm not really sure how you expect this to work -- you are hopefully aware that the spam list isn't a list of URLs, it's just a list of bits of text to reject. I don't think it is feasible to have a whitelist on top of such a filter.
Suppose you configure the spam filter to block only "http" (right here, you already have a problem, if something's not identified as a URL because they wrote hxxp then it still "works". But let's ignore that for now.) Your theoretical whitelist has the single entry "http://wakaba.c3.cx", presumably to allow posting links to this website.
Now suppose someone tries to post the following text:
blah blah blah I am a stupid spammer
http://www.stupidspamwebsite.com/spam/spam/
oh and by the way http://wakaba.c3.cx/
Your blacklist would find that http in the message and try to reject it. A simple text-matching whitelist would find wakaba.c3.cx and say "it's fine" and now someone just completely evaded your spam list.
I don't know of any sane way to do what I think you're asking for.
>>2
i think what he wants is something like /http:\/\/(?!wakaba\.c3\.cx\/)/
...