|
Akismet could help, a PHP lib is available too.
Add sesskey to protect it a bit.
(just guessing if we could start storing somewhere a table of big hashes detected as spam in order to provide one webservice with that. nothing "intelligent" for now, just hash-check). I the future this could be evolved to anything more complex (own heuristic checker, gateway to "ask" other spam detectors...). But the ws should remain the same. Ciao Attached is a patch to add sesskey, though some YUI magic seems to be interfering when I try it. Dongsheng or Eloy, can you please look into it and update CVS?
A further feature idea would be to examine config settings at the start of this script and offer to fix forceloginforprofiles etc for the admin. I do not exactly know how to attach related tracker issues, but here are some things that bear on this discussion:
Admin approval of email account creation/course enroll: Completely remove user profiles (I can't see this one): Preventing spam in user proviles: Thanks atw.
(For future reference, you can add related issues by using the 'Link' link on the left of the page.) Hi,
I changed the above script: 1- removed the rs_fetch_next_record($users) because it cause this error: Call to a member function FetchRow() on a non-object in C:\xampp\htdocs\vle\lib\dmllib.php on line 827 2- added image search, because some spammers add images such as Ads and p0rn0 3- enhanced sql queries, joining all conditions rather than making an query in loop 4- removing all redundunt queries and make them in one function to avoid any future mess if you want work on this script 5- showing one record for the user who meets more than 1 keyword.. the previous script was showing more than 1 record for any user who has more than 1 keyword in his profile. hope this helps.. please upload it to CVS. Cheers Thanks your improvement, Amr.
I modified your code to use get_recordset_sql, this will help to deal with large record sets. I reviewed the code today and made quite a lot of cleanups. Please upgrade if you are using this script!
The new script doesnt include image search.
Hi, Amr, image searching is included in "Autodetect common spam patterns"
thanks Dongsheng, i noticed it
Error message in 1.9.2 2080711
require_js: yui_json - file not found. and The entry "<img" has as consequence that all emoticons in profiles are declared as spam. 'cialis' finds specialist as term in profile.
The Bad Behavior script can prevent spam accounts from ever even being created in the first place... this is an extremely effective script!!
Thanks Jeff, that's a very interesting development for spambot detection, I'll add it to the main bug MDL-17107.
We still need a good clean up script, because of old sites already affected as well as those affected by human spammers. TODO:
TODOs are fixed, please review.
Hi Dongsheng
ver 1.12. finds smilies furthermore for me. Hi, Ralf, what's your search keyword, is it "<img"?
I tested, and no smilies for me. Hi, can this be considered resolved?
I'm using Moodle 1.9.2+ (Build: 20080723).
When I go to run spamcleaner.php, I get error: require_js: yui_json - file not found. Martin, are you updating via CVS? If so, make sure you use the create new directories option. On command-line CVS that is -d, for example:
cvs -q update -dP You might need to upgrade to Moodle 1.9.4 anyway. Dongsheng, thanks for fixing, and thanks for everyone's comments.
We now have a documentation page: http://docs.moodle.org/en/Spam_cleaner |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
http://cvs.moodle.org/contrib/tools/spamcleaner/spamcleaner.php?view=co
Your improvements are very welcome! Please improve the script if you have write access already, or post ideas and patches here in the tracker.
The main thing I think we could add next would be a built-in list of phrases to search for, or perhaps a way to process all the texts with an external spam-checking engine.