Spamassassin: blocking reject notifications

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

chriscook

Spamassassin: blocking reject notifications

Postby chriscook » Wed Apr 05, 2006 8:21 pm

Spamassassin is up and running via SMTPFILTER=TRUE and spamass-milter. Looks good. One thing though.

I'm running spamass-milter with the '-r 15' flag so that it rejects spam marked over 15 points, which works fine, but sendmail or scalix then trieds to mail a rejection notice back to the sender of the spam which in turn gets passed back through the milter and is again flagged as spam over 15 and a rejection mail is then generated from <> which goes to postmaster and gets passed through the milter again and then sendmail finally savemail panics and drops the message.

How can I get sendmail/spamass-milter to drop messages over 15 without trying to send a rejection notice?


---- example log--
Apr 5 16:59:43 vm-mail sendmail[1821]: k35NxhZA001821: from=ccook@xxx.com, size=357, class=0, nrcpts=1, msgid=<443459EF.mail1EK1XC3LT@xxx.com>, relay=root@localhost
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh35001822: from=<ccook@xxx.com>, size=553, class=0, nrcpts=1, msgid=<443459EF.mail1EK1XC3LT@xxx.com>, proto=ESMTP, daemon=Daemon0, relay=localhost [127.0.0.1]
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: connection from localhost [127.0.0.1] at port 38643
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: using default config for jenny@yyy.com: /var/spool/spamassassin/jenny@yyy.com/user_prefs
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: processing message <443459EF.mail1EK1XC3LT@estrider.com> for jenny@yyy.com:8
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: identified spam (999.1/5.0) for jenny@yyy.com:8 in 0.1 seconds, 769 bytes.
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: result: Y 999 - ALL_TRUSTED,GTUBE,NO_REAL_NAME scantime=0.1,size=769,user=jenny@yyy.com,uid=8,required_score=5.0,rhost=localhost,raddr=127.0.0.1,rport=38643,mid=<443459EF.mail1EK1XC3LT@estrider.com>,autolearn=no
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh35001822: Milter add: header: X-Spam-Flag: YES
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh35001822: Milter add: header: X-Spam-Status: Yes, score=999.1 required=5.0 tests=ALL_TRUSTED,GTUBE,\r\n\tNO_REAL_NAME autolearn=no version=3.1.1
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh35001822: Milter: data, reject=550 5.7.1 Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh35001822: to=<jenny@yyy.com>, delay=00:00:00, pri=30553, stat=Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail spamd[29356]: prefork: child states: II
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZA001821: to=jenny@yyy.com, ctladdr=ccook@xxx.com (0/0), delay=00:00:01, xdelay=00:00:01, mailer=relay, pri=30357, relay=[127.0.0.1] [127.0.0.1], dsn=5.0.0, stat=Service unavailable
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZA001821: k35NxhZB001821: DSN: Service unavailable
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh37001822: from=<>, size=2198, class=0, nrcpts=1, msgid=<200604052359.k35NxhZB001821@vm-mail.corp.yyy.com>, proto=ESMTP, daemon=Daemon0, relay=localhost [127.0.0.1]
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: connection from localhost [127.0.0.1] at port 38644
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: using default config for ccook@xxx.com: /var/spool/spamassassin/ccook@xxx.com/user_prefs
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: processing message <200604052359.k35NxhZB001821@vm-mail.corp.yyy.com> for ccook@xxx.com:8
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: identified spam (998.6/5.0) for ccook@xxx.com:8 in 0.2 seconds, 2446 bytes.
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: result: Y 998 - ALL_TRUSTED,GTUBE scantime=0.2,size=2446,user=ccook@xxx.com,uid=8,required_score=5.0,rhost=localhost,raddr=127.0.0.1,rport=38644,mid=<200604052359.k35NxhZB001821@vm-mail.corp.airmedia.com>,autolearn=no
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh37001822: Milter add: header: X-Spam-Flag: YES
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh37001822: Milter add: header: X-Spam-Status: Yes, score=998.6 required=5.0 tests=ALL_TRUSTED,GTUBE \r\n\tautolearn=no version=3.1.1
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh37001822: Milter: data, reject=550 5.7.1 Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh37001822: to=<ccook@xxx.com>, delay=00:00:00, pri=32198, stat=Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZB001821: to=ccook@xxx.com, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31381, relay=[127.0.0.1] [127.0.0.1], dsn=5.0.0, stat=Service unavailable
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZB001821: k35NxhZC001821: return to sender: Service unavailable
Apr 5 16:59:44 vm-mail spamd[29356]: prefork: child states: II
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh39001822: from=<>, size=3894, class=0, nrcpts=1, msgid=<200604052359.k35NxhZC001821@vm-mail.corp.yyy.com>, proto=ESMTP, daemon=Daemon0, relay=localhost [127.0.0.1]
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: connection from localhost [127.0.0.1] at port 38645
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: using default config for postmaster@vm-mail.corp.yyy.com: /var/spool/spamassassin/postmaster@vm-mail.corp.yyy.com/user_prefs
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: processing message <200604052359.k35NxhZC001821@vm-mail.corp.yyy.com> for postmaster@vm-mail.corp.yyy.com:8
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: identified spam (998.6/5.0) for postmaster@vm-mail.corp.yyy.com:8 in 0.1 seconds, 4212 bytes.
Apr 5 16:59:44 vm-mail spamd[1819]: spamd: result: Y 998 - ALL_TRUSTED,GTUBE scantime=0.1,size=4212,user=postmaster@vm-mail.corp.yyy.com,uid=8,required_score=5.0,rhost=localhost,raddr=127.0.0.1,rport=38645,mid=<200604052359.k35NxhZC001821@vm-mail.corp.airmedia.com>,autolearn=no
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh39001822: Milter add: header: X-Spam-Flag: YES
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh39001822: Milter add: header: X-Spam-Status: Yes, score=998.6 required=5.0 tests=ALL_TRUSTED,GTUBE \r\n\tautolearn=no version=3.1.1
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh39001822: Milter: data, reject=550 5.7.1 Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail sendmail[1822]: k35Nxh39001822: to=<postmaster@vm-mail.corp.yyy.com>, delay=00:00:00, pri=33894, stat=Blocked by SpamAssassin
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZC001821: to=postmaster, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=32405, relay=[127.0.0.1] [127.0.0.1], dsn=5.0.0, stat=Service unavailable
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZB001821: Losing ./qfk35NxhZB001821: savemail panic
Apr 5 16:59:44 vm-mail sendmail[1821]: k35NxhZB001821: SYSERR(root): savemail: cannot save rejected email anywhere

ScalixSupport
Scalix
Scalix
Posts: 5503
Joined: Thu Mar 25, 2004 8:15 pm

Postby ScalixSupport » Thu Apr 06, 2006 7:53 am

Hi,

you should either whitelist your domain or use -b spameater and create an /etc/mail/alises :

spameater: /dev/null

Cheers,

Sascha.

chriscook

Postby chriscook » Thu Apr 06, 2006 12:36 pm

Which whitelist? Wouldn't whitelisting the sender still send the rejection messages? If the Spam scores that high, I'd just want to drop it as any reply message would probably just bounce or clog up someone else's server.

Wouldn't using the '-b' milter flag forward all spam to an alias, I just want high scoring span dealt with in this manner.

e1kosau
Posts: 30
Joined: Fri Mar 03, 2006 3:52 am
Location: california SF

Postby e1kosau » Sat Apr 08, 2006 1:27 am

here's how i do it I use the -b option/flag to redirect the mail to a mailbox for sa-learn. i send it to a spam account. then i use that account for sa-learn for bayesian filter.

put the option -b at /etc/sysconfig/spamass-milter

code is

-b spam@domain.com

i lowered the rating to 7. any messages with a score of 7 will be redirected to the spam account.

I see that you also have a DSN service unavailable error in your logs. I suggest to put your domain in your sendmail.mc file ( i'm not sure which file was that, i forgot about it) this will prevent the error from showing up again.

restart spamassassin, restart spam-ass milter, restart sendmail restart smtpd
#service spamassassin restart
#service sendmail restart
#omoff -d0 smtpd;omon smtpd

good luck

jonny
Posts: 39
Joined: Wed Mar 22, 2006 1:25 pm

Postby jonny » Fri Jul 28, 2006 9:26 am

Hey There

I am in the process of integrating Spam Assassin and have set the following flags in /etc/sysconfig/spamass-milter

Code: Select all

EXTRA_FLAGS="-r 15 -b spam@ourscalixdomain.com"


However, when mail gets rejected as spam it seems to get caught in an infinite loop where it keeps going round in sendmail (maillog fills up with the same delivery). Any ideas on how to stop this happening?

Thanks
j

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Postby florian » Sat Jul 29, 2006 1:14 pm

can you post an example of this maillog??

thx,
Florian.
Florian von Kurnatowski, Die Harder!

dougp23
Posts: 229
Joined: Thu Feb 15, 2007 2:42 pm

Postby dougp23 » Wed Jul 11, 2007 9:26 am

Well I am bumping this up! I see the same thing happening!

If I use -b with -r, when a message is high enough to get rejected, my mailserver falls into this infinite recursive loop. I would appreciate any thoughts on ending that loop! Right now I have my -r set quite high to avoid the loop, but it makes my box a bit of a spam magnet since almost no spam gets rejected.


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 4 guests

cron