As noted in my prior post, adjusting the cutoff seems to have dramatically reduced the incidence of published spam, which is a good thing! But, there are a couple of points on which I am not sure what we should be doing.

1. We are using the option to put the spam into a special queue. I can't seem to find any such queue. It seems like it would be good to review what was being done but there is no obvious way that I see to do that other than to tediously wade through the logs. I did up the logging level to verbose, which seems excessive. It seems like there should be something between Important and Verbose that was one line per message or something.

2. While it is unpublishing the spam, it doesn't delete it. This seems safer, but will it ever go away on its own or de we have to run around finding it and deleting it ourselves.

3. Once in a while it unpublishes a new comment, but the post still shows up at the top of recent comments. Anything to do about that except delete the post?

4. In the report statistics, it says:
prevented comment spam 73 14 min 43 sec ago
marked comment as spam 85 14 min 43 sec ago
What is the difference and what does each mean?

CommentFileSizeAuthor
#8 spam.zip19.56 KBtamhas

Comments

naught101’s picture

1. and 2: do you have a "spam" tab in admin/content/comment? This is where you find what you want

3. probably because "recent comments" isn't very sophisticated... you could try replacing it with a view.

tamhas’s picture

There is an Approval queue tab, but no spam tab.

naught101’s picture

Then you have this bug, and need to apply the patch in it: http://drupal.org/node/351280

tamhas’s picture

Guess I need a pointer to how to install the patch. I downloaded it and guessed that one might source it, but that got me:

[cintegrity][~/site/www/bin/drupal-6.10/sites/all/modules]$ patch < $DOWN/diff_20.patch
can't find file to patch at input line 4
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|diff -upr spam/modules/spam_comment.inc spam/modules/spam_comment.inc
|--- spam/modules/spam_comment.inc 2008-12-24 23:42:11.000000000 -0600
|+++ spam/modules/spam_comment.inc 2008-12-26 03:25:38.467300000 -0600
--------------------------
File to patch:
Skip this patch? [y]

I don't know that I have ever used patch before, so there is a bit of guesswork here. What am I doing wrong? $DOWN is the directory into which I initially place downloads. I did check and spam/modules/spam_comment.inc does exist

[cintegrity][~/site/www/bin/drupal-6.10/sites/all/modules]$ ll spam/modules
total 32
-rw-r--r-- 1 cintegrity vuser 12846 Feb 13 09:36 spam_comment.inc
-rw-r--r-- 1 cintegrity vuser 4326 Dec 24 22:42 spam_node.inc
-rw-r--r-- 1 cintegrity vuser 6414 Dec 24 22:42 spam_user.inc

But, I notice that the top of the file is

<?php
// $Id: spam_comment.inc,v 1.1.2.1.2.11.2.2 2009/02/13 16:36:05 jeremy Exp $

So, is that telling me that the patch is for a different version?

naught101’s picture

Can't find file to patch at input line 4 << it can't find the patch file you're using

Stick your patch in the base directory of your module, cd to your module directory, then run
patch -u < patchfile
(-u for unified patch format)

It'll probably screw up, and ask you which file you're talking about, just copy the one it suggests and paste it back in.

tamhas’s picture

> It'll probably screw up,

Reassuring ....

What about the apparent difference in version?

naught101’s picture

Doesn't matter. It'll still work. The joys of patch.

if you're worried you can always do it manually, or run it and check that the changes have been made:

1)--- spam/modules/spam_comment.inc	2008-12-24 23:42:11.000000000 -0600
2)+++ spam/modules/spam_comment.inc	2008-12-26 03:25:38.467300000 -0600
3)@@ -181,9 +181,10 @@ function comment_spamapi($op, $arg1 = NU
...
-        'callback' => 'spam_comment_admin',
-        'callback arguments' => array('spam'),
-        'access' => user_access('administer spam'),
+        'page callback' => 'spam_comment_admin',
+        'access arguments' => array('administer spam'),
+        'file' => 'comment.admin.inc',

1) old file
2) new file
3) from line 181, replace nine lines with ten lines.
lines with a minus are to be removed, lines with a plus are to be added.

tamhas’s picture

StatusFileSize
new19.56 KB

Well .... since spam_comment.inc is in the modules subdirectory and spam.module in the main directory, I ended up having to cut the script into two files and applying them separately. This *appeared* to work, maybe, since I got:
patching file spam_comment.inc
Hunk #1 succeeded at 179 (offset -2 lines).
Hunk #3 succeeded at 372 (offset -2 lines).
on the spam_comment.inc patch and just
patching file spam.module
on the second one. I'm guessing patch doesn't report anything if the change has already been made. I looked at spam.module and the change appeared to be there and a quick look at spam_comment.inc seems to show that the middle "hunk" had already been patched as intended. I am attaching copies of each as they stand now.

However, there is no new spam tab on the Admin -> Content -> Contents page, just the Published and Approval that were there before, so I am no more forwarder than I was.

naught101’s picture

admin>content>comments

tamhas’s picture

Yes, that was a typo. I meant http://www.bstw.com/admin/content/comment

naught101’s picture

did you run update.php?

tamhas’s picture

Curiously, update.php shows zero updates to run, but I ran it anyway and now the tab is there.

tamhas’s picture

So this shows the new spam, which is good. I tried deleting one of the comments and it does seem to have disappeared, at least from this list, which is good. But, on completion and return to the main Comments page I got:

user warning: Duplicate entry 'node/66' for key 2 query: INSERT INTO xmlsitemap (type, id, status, loc, lastmod, priority, changefreq, changecount) VALUES ('node', 66, 1, 'node/66', 1240703612, NULL, 0, 0) in /var/www/bin/drupal-6.11/sites/all/modules/xmlsitemap/xmlsitemap.module on line 782.

but, I suppose that is an xmlsitemap issue, not a spam issue.

However, I tried marking one and marking it as not spam, but that seemed to have no impact. It was still spam(99) and still on the list.

naught101’s picture

There are lots of other patches in the issues queue for version 6.x, have a search through, and you'll probably find a fix.

gnassar’s picture

Status: Active » Closed (duplicate)

As noted previously, and also #352179: bad "Not Spam" link.