Hi all,
I'm using the Roundcube plugin "MarkAsJunk2" (
Roundcube Plugins & Patches) in order to enable my clients to self-train SpamAssasin. I'm using Roundcube and SpamAssassin in connection with ISPConfig 3.
Unfortunately, the "Mark as Junk" function doesn't work as expected. Below is the corresponding snippet from my MarkAsJunk2 configuration file:
/**
* MarkAsJunk2 configuration file
*/
// Learning driver
// Use an external process such as sa-learn to learn from spam/ham messages. Default: null.
// Please see the README for more information
$rcmail_config['markasjunk2_learning_driver'] = 'cmd_learn';
// Mark messages as read when reporting them as spam
$rcmail_config['markasjunk2_read_spam'] = true;
// Mark messages as unread when reporting them as ham
$rcmail_config['markasjunk2_unread_ham'] = false;
// When reporting a message as ham, if the orginial message is attached (like with SpamAssassin reports),
// detach the orginial message and move that to the INBOX, deleteing the spam report
$rcmail_config['markasjunk2_detach_ham'] = true;
// Add flag to messages marked as spam (flag will be removed when marking as ham)
// If you do not want to use message flags set this to null
$rcmail_config['markasjunk2_spam_flag'] = 'Junk';
// Add flag to messages marked as ham (flag will be removed when marking as spam)
// If you do not want to use message flags set this to null
$rcmail_config['markasjunk2_ham_flag'] = null;
// Write output from spam/ham commands to the log for debug
$rcmail_config['markasjunk2_debug'] = true;
// Show icon on mailbox toolbar
// The mark as spam/ham icon can either be displayed on the toolbar or as part of the mark messages menu
$rcmail_config['markasjunk2_mb_toolbar'] = true;
// cmd_learn Driver options
// ------------------------
// The command used to learn that a message is spam
// The command can contain the following macros that will be expanded as follows:
// %u is replaced with the username (from the session info)
// %l is replaced with the local part of the username (if the username is an email address)
// %d is replaced with the domain part of the username (if the username is an email address or default mail domain if not)
// %f is replaced with the path to the message file (THIS SHOULD ALWAYS BE PRESENT)
// If you do not want run the command set this to null
$rcmail_config['markasjunk2_spam_cmd'] = 'sa-learn --spam %f';
// The command used to learn that a message is ham
// The command can contain the following macros that will be expanded as follows:
// %u is replaced with the username (from the session info)
// %l is replaced with the local part of the username (if the username is an email address)
// %d is replaced with the domain part of the username (if the username is an email address or default mail domain if not)
// %f is replaced with the path to the message file (THIS SHOULD ALWAYS BE PRESENT)
// If you do not want run the command set this to null
$rcmail_config['markasjunk2_ham_cmd'] = 'sa-learn --ham %f';
The debug log shows the following entries:
[23-Nov-2010 08:05:36 +0100]: sa-learn --spam /var/www/webmail/temp/rcmSALearn2cBzEI
[23-Nov-2010 08:05:36 +0100]: array (
0 => 'Learned tokens from 0 message(s) (1 message(s) examined)',
)
So the message location seems to be allright but SpamAssassin doesn't seem to learn from the messages because even though I mark them as Junk, they are moved to the Junk folder and the sa-learn command is executed, when a similar email message arrives later the day, it is again not tagged as Junk.
Could somebody please help me with this? I'm really clueless at the moment ...
Could this be an issue with ISPConfig 3?
Any help is greatly appreciated!
Thank you very much in advance!
Cheers,
Eric