LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-11-2015, 09:14 AM   #1
xof1s
LQ Newbie
 
Registered: Sep 2015
Posts: 1

Rep: Reputation: Disabled
Why amavis doesn't send SPAM to mailbox


Hello,

When message is marked as SPAM, message is not delivered to mailbox. I don't know what happen to message, I can't see it in log. Any suggestions?

Amavis normally detect spamassassin, it looks working great.
Code:
  1 Sep 11 11:47:14.839 mail.myserver.com /usr/sbin/amavisd-new[11496]: Using internal spam scanner code for SpamAssassin                                                                                                                
Sep 11 11:47:14.839 mail.myserver.com /usr/sbin/amavisd-new[11496]: Deleting db files snmp.db,nanny.db,__db.002,__db.001,__db.003 in /var/lib/amavis/db                                                                              
Sep 11 11:47:14.841 mail.myserver.com /usr/sbin/amavisd-new[11496]: Creating db in /var/lib/amavis/db/; BerkeleyDB 0.54, libdb 5.3                                                                                                    
Sep 11 11:47:14.847 mail.myserver.com /usr/sbin/amavisd-new[11496]: initializing Mail::SpamAssassin (0)                                                                                                                              
Sep 11 11:47:14.847 mail.myserver.com /usr/sbin/amavisd-new[11496]: SpamAssassin debug facilities: info                                                                                                                              
Sep 11 11:47:16.631 mail.myserver.com /usr/sbin/amavisd-new[11496]: SpamAssassin loaded plugins: AskDNS, AutoLearnThreshold, Bayes, BodyEval, Check, DKIM, DNSEval, FreeMail, HTMLEval, HTTPSMismatch, Hashcash, HeaderEval, ImageInfo    , MIMEEval, MIMEHeader, Pyzor, Razor2, RelayEval, ReplaceTags, SPF, SpamCop, URIDNSBL, URIDetail, URIEval, VBounce, WLBLEval, WhiteListSubject                                                                                        
Sep 11 11:47:16.631 mail.myserver.com /usr/sbin/amavisd-new[11496]: SpamControl: init_pre_fork on SpamAssassin done                                                                                                                  
Sep 11 11:47:16.632 mail.myserver.com /usr/sbin/amavisd-new[11496]: extra modules loaded after daemonizing/chrooting: /etc/perl/Net/libnet.cfg, Mail/SpamAssassin/Plugin/FreeMail.pm, Mail/SpamAssassin/Plugin/SpamCop.pm, Net/Cmd.pm,     Net/Config.pm, Net/SMTP.pm                                                                                                                                                                                                          
Sep 11 11:47:16.632 mail.myserver.com /usr/sbin/amavisd-new[11496]: Net::Server: Beginning prefork (2 processes)                                                                                                                      
Sep 11 11:47:16.632 mail.myserver.com /usr/sbin/amavisd-new[11496]: Net::Server: Starting "2" children                                                                                                                                
Sep 11 11:47:16.693 mail.myserver.com /usr/sbin/amavisd-new[11503]: Net::Server: Child Preforked (11503)                                                                                                                              
Sep 11 11:47:16.694 mail.myserver.com /usr/sbin/amavisd-new[11503]: entered child_init_hook                                                                                                                                          
Sep 11 11:47:16.708 mail.myserver.com /usr/sbin/amavisd-new[11503]: SpamControl: init_child on SpamAssassin done                                                                                                                      
Sep 11 11:47:16.740 mail.myserver.com /usr/sbin/amavisd-new[11496]: Net::Server: Parent ready for children.                                                                                                                          
Sep 11 11:47:16.741 mail.myserver.com /usr/sbin/amavisd-new[11504]: Net::Server: Child Preforked (11504)                                                                                                                              
Sep 11 11:47:16.742 mail.myserver.com /usr/sbin/amavisd-new[11504]: entered child_init_hook                                                                                                                                          
Sep 11 11:47:16.753 mail.myserver.com /usr/sbin/amavisd-new[11504]: SpamControl: init_child on SpamAssassin done
But my problem is that spam test
Code:
echo "XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X" | mutt -s "zero day" -- recipient@myserver.com
Message is not delivered into mailbox (recipient@myserver.com). In Amavis debug I can see that message was marked as SPAM, which is correct:
Code:
Sep 11 11:52:20.516 binary-rose.roses.org /usr/sbin/amavisd-new[11503]: (11503-01) header_edits_for_quar: <out@gmail.com> -> <recipient@myserver.com>, Yes, score=1000 tag=2 tag2=6.31 kill=6.31 tests=[GTUBE=1000] autolearn=no autolearn_fo
rce=no
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header encoded (all-ASCII): X-Spam-Flag: YES
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header: X-Spam-Flag: YES\n
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header encoded (all-ASCII): X-Spam-Score: 1000
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header: X-Spam-Score: 1000\n
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header encoded (all-ASCII): X-Spam-Level: ****************************************************************
Sep 11 11:52:20.517 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header: X-Spam-Level: ****************************************************************\n
Sep 11 11:52:20.518 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header encoded (all-ASCII): X-Spam-Status: Yes,\n score=1000\n tag=2\n tag2=6.31\n kill=6.31\n tests=[GTUBE=1000]\n autolearn=no autolearn_force=no
Sep 11 11:52:20.518 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) header: X-Spam-Status: Yes, score=1000 tag=2 tag2=6.31 kill=6.31 tests=[GTUBE=1000]\n\tautolearn=no autolearn_force=no\n
Sep 11 11:52:20.518 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) quar: scanner provided a header field X-Spam-Checker-Version, inhibited by %allowed_added_header_fields
Sep 11 11:52:20.519 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) quar: scanner provided a header field X-Spam-Flag, but we preferred our own
Sep 11 11:52:20.519 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) quar: scanner provided a header field X-Spam-Level, but we preferred our own
Sep 11 11:52:20.519 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) quar: scanner provided a header field X-Spam-Status, but we preferred our own
Sep 11 11:52:20.519 mail.myserver.com /usr/sbin/amavisd-new[11503]: (11503-01) do_notify_and_quarantine: quarantine spam-quarantine
For to be sure everybody undesrtand I'll explain again: my host is mail.myserver.com, and spam was sent from out@gmail.com, recipient was recipient@myserver.com.

Here is complete debug of amavis, (amavids-new debug): http://pastebin.com/QDNMCz6L

And my /etc/amavis/conf.d/20-debian_defaults:
Code:
$final_virus_destiny      = D_DISCARD;  # (data not lost, see virus quarantine)                                                                                                                                                      
$final_banned_destiny     = D_BOUNCE;   # D_REJECT when front-end MTA                                                                                                                                                                
$final_spam_destiny       = D_BOUNCE;                                                                                                                                                                                                
$final_bad_header_destiny = D_PASS;     # False-positive prone (for spam)
So my expected behavior is: message marked as spam will be delivered into mailbox(and then I can configure sieve or something like that ).
Message is not delivered into mailbox as I expect. Where is the message lost? How can I configure it for deliver SPAM into mailbox? Thank you for all hints, I'll post whatever, I'm new to amavis/spamassassin. Thanks!
 
Old 09-11-2015, 03:30 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
So my expected behavior is: message marked as spam will be delivered into mailbox(and then I can configure sieve or something like that ).
Message is not delivered into mailbox as I expect. Where is the message lost? How can I configure it for deliver SPAM into mailbox? Thank you for all hints, I'll post whatever, I'm new to amavis/spamassassin. Thanks!
My guess is that you need to set
Code:
$final_spam_destiny = D_PASS
Regards

Last edited by bathory; 09-12-2015 at 03:39 AM.
 
1 members found this post helpful.
Old 09-16-2015, 11:44 PM   #3
tva
Member
 
Registered: Jul 2010
Location: Finland
Distribution: Open SUSE 13.1
Posts: 83

Rep: Reputation: 8
Could it be Spam kill level? Also final_spam_destiny might need to be as bathory said.

Code:
 X-Spam-Status: Yes,\n score=1000\n tag=2\n tag2=6.31\n kill=6.31
Score is 1000 and kill level is 6.31 so if I remember correctly, it just deletes that mail.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
spam attack +spamassassin+amavis alphatest Linux - Software 5 01-08-2011 09:36 AM
amavis wrongly detecting the spam comes from squirrelmail ssilayaraja Linux - Software 0 09-25-2009 05:51 AM
Amavis doesn't check for spam on some emails jonnytabpni Linux - Server 4 04-25-2009 06:19 PM
amavis not filtering spam exodist Linux - Software 1 12-16-2005 11:44 PM
Amavis X-spam-status ncp Linux - Newbie 0 11-25-2005 03:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:04 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration