Spam-check in Config.pm doens't seem to be working?

I put the following into my Config.pm based on what was in the defaults.pm: # Job Name: 5-Spam # (Move spam to spam queue $Self->{'PostMster::PreFilterModule'}->{'5-Spam'} = { Module => 'Kernel::System::PostMaster::Filter::CMD', CMD => '/opt/spamassassin-301/bin/spamassassin | grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, }; My understanding of this is that if spamassassin gives it the header of X-Spam-Status of yes it will add a X-OTRS-Queue header and set that to spam, so that OTRS sees that and puts it in the spam queue. Am I correct? I am having spam being forwarded to OTRS to test this out but it doens't even have any of the Spamassassin filters in it. When I looked at the headers through OTRS, copied them to a txt file and ran spamassassin on it with all the headers and it got a score of over 5.0. This looks like to me that it's not even running spamassassin at all. Did I do something wrong? --Matthew Shapiro

On Mon, 2004-11-15 at 22:06, kalldrex-otrs@yahoo.com wrote:
I put the following into my Config.pm based on what was in the defaults.pm:
# Job Name: 5-Spam # (Move spam to spam queue $Self->{'PostMster::PreFilterModule'}->{'5-Spam'} = { ^^^^^^^^^ The above typo may have something to do with this if it is in the original code.
BTW: I use procmail to pre-filter. You can then set up directories that can be made available for the bayesian training of spamassassin....
Module => 'Kernel::System::PostMaster::Filter::CMD', CMD => '/opt/spamassassin-301/bin/spamassassin | grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, };
My understanding of this is that if spamassassin gives it the header of X-Spam-Status of yes it will add a X-OTRS-Queue header and set that to spam, so that OTRS sees that and puts it in the spam queue. Am I correct? I am having spam being forwarded to OTRS to test this out but it doens't even have any of the Spamassassin filters in it. When I looked at the headers through OTRS, copied them to a txt file and ran spamassassin on it with all the headers and it got a score of over 5.0. This looks like to me that it's not even running spamassassin at all. Did I do something wrong?
--Matthew Shapiro _______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting fr Ihr OTRS System? => http://www.otrs.de/
--
Meum est propositum
In tabernum mori,
Graham Smith

Lol thanks, I missed that spelling error :D I"ll see
if that fixes it.
Whats the advantage of using procmail instead of the
postmaster::prefilter? I still want them to be
tickets just incase a false positive occurs.
--Matthew Shapiro
--- Graham Smith
On Mon, 2004-11-15 at 22:06, kalldrex-otrs@yahoo.com wrote:
I put the following into my Config.pm based on what was in the defaults.pm:
# Job Name: 5-Spam # (Move spam to spam queue $Self->{'PostMster::PreFilterModule'}->{'5-Spam'} = { ^^^^^^^^^ The above typo may have something to do with this if it is in the original code.
BTW: I use procmail to pre-filter. You can then set up directories that can be made available for the bayesian training of spamassassin....
Module => 'Kernel::System::PostMaster::Filter::CMD', CMD =>
'/opt/spamassassin-301/bin/spamassassin
| grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, };
My understanding of this is that if spamassassin gives it the header of X-Spam-Status of yes it will add a X-OTRS-Queue header and set that to spam, so that OTRS sees that and puts it in the spam queue. Am I correct? I am having spam being forwarded to OTRS to test this out but it doens't even have any of the Spamassassin filters in it. When I looked at the headers through OTRS, copied them to a txt file and ran spamassassin on it with all the headers and it got a score of over 5.0. This looks like to me that it's not even running spamassassin at all. Did I do something wrong?
--Matthew Shapiro _______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting fr Ihr OTRS System? => http://www.otrs.de/ -- Meum est propositum In tabernum mori,
Graham Smith
_______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting f�r Ihr OTRS System? => http://www.otrs.de/

Erm it's still isn't filtering at all. I changed the spelling error (now it's exactly what it shows below, copy/pasted) and I got a piece of spam 53 minutes ago that doesn't have any of the spamassassin headers in it. Why isn't otrs running spamassassin? The otrs logs don't tell me a thing. --Matthew Shapiro
# Job Name: 5-Spam # (Move spam to spam queue $Self->{'PostMaster::PreFilterModule'}->{'5-Spam'} = {
Module => 'Kernel::System::PostMaster::Filter::CMD', CMD => '/opt/spamassassin-301/bin/spamassassin | grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, };

Ok after doing some tests with spamassassin and looking at the configuration more closely I realize that the spamassassin headers shouldn't be in there anyways as it looks like the filter runs the text against spamassassin and when spamassassin prints out the modified email with spam headers to stdout, grep searches that output for the X-Spam-Status: header to see if it was spam, and if it was it injects the X-OTRS-Queue: spam header. However, that X-OTRS-Queue header isn't being put into the emails. How would I find out where the problem lies, as I don't know if it is giving the emails to spamassassin properly, or if the queue header isn't being injected properly or what? Anyone have any ideas on how to figure this out? --Matthew Shapiro --- kalldrex-otrs@yahoo.com wrote:
Erm it's still isn't filtering at all. I changed the spelling error (now it's exactly what it shows below, copy/pasted) and I got a piece of spam 53 minutes ago that doesn't have any of the spamassassin headers in it. Why isn't otrs running spamassassin? The otrs logs don't tell me a thing.
--Matthew Shapiro
# Job Name: 5-Spam # (Move spam to spam queue
$Self->{'PostMaster::PreFilterModule'}->{'5-Spam'} =
{
Module => 'Kernel::System::PostMaster::Filter::CMD', CMD => '/opt/spamassassin-301/bin/spamassassin | grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, };
_______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting f�r Ihr OTRS System? => http://www.otrs.de/

There are two ways of running spamassassin, the method in the PreFilterModule definition is for the server level configuration, with all mail accounts effectively getting the same anti-spam definition. I run the client(spamc)/server(spamd) variant in which account based definitions are used. I decided to use the latter after reading the spamassassin documentation, as the machine also acts as a mail server. This gives individual accounts some control of defining defining spam...., and to tune the otrs account in a different manner to others. With procmail it also give me the option to direct abuse and postmaster enquiries that include spam to otrs in a sensible manner. (Unfortunately dealing with I.T. related enquiries one can get legitimate spam related enquiries that could flagged as spam which may be undesirable...). I am using 2.64 and X-Spam-Status seems to be in all messages, but the fields existence does not in itself indicate a message is spam. 3.x seems to be about a month old, I have not checked what (if any) difference between 2.6x and 3.x behaviour exists. This may make assumptions in Default.pm examples redundant. On Tue, 2004-11-16 at 20:17, kalldrex-otrs@yahoo.com wrote:
Ok after doing some tests with spamassassin and looking at the configuration more closely I realize that the spamassassin headers shouldn't be in there anyways as it looks like the filter runs the text against spamassassin and when spamassassin prints out the modified email with spam headers to stdout, grep searches that output for the X-Spam-Status: header to see if it was spam, and if it was it injects the X-OTRS-Queue: spam header. However, that X-OTRS-Queue header isn't being put into the emails. How would I find out where the problem lies, as I don't know if it is giving the emails to spamassassin properly, or if the queue header isn't being injected properly or what? Anyone have any ideas on how to figure this out?
--Matthew Shapiro --- kalldrex-otrs@yahoo.com wrote:
Erm it's still isn't filtering at all. I changed the spelling error (now it's exactly what it shows below, copy/pasted) and I got a piece of spam 53 minutes ago that doesn't have any of the spamassassin headers in it. Why isn't otrs running spamassassin? The otrs logs don't tell me a thing.
--Matthew Shapiro
# Job Name: 5-Spam # (Move spam to spam queue
$Self->{'PostMaster::PreFilterModule'}->{'5-Spam'} =
{
Module => 'Kernel::System::PostMaster::Filter::CMD', CMD => '/opt/spamassassin-301/bin/spamassassin | grep -i "X-Spam-Status: yes"', Set => { 'X-OTRS-Queue' => 'spam', }, };
_______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting fr Ihr OTRS System? => http://www.otrs.de/
_______________________________________________ OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs Support oder Consulting fr Ihr OTRS System? => http://www.otrs.de/ -- Meum est propositum In tabernum mori,
Graham Smith
participants (2)
-
Graham Smith
-
kalldrex-otrs@yahoo.com