Tag spam only for recipients from a domain

Hoyer-Reuther, Christian Christian.Hoyer-Reuther at cac-chem.de
Tue Jun 6 08:25:44 CEST 2017


Hello,

you can try the following:

@spam_lovers_maps = ({
  'boss at example.com' => 0, # never, even if domain matches
  'example.com'      => 1, # this domain, but not it's subdomains
  '.example.com'     => 1, # this domain and it's subdomains
});

Using the ..._lovers_maps amavis scans the message, logs the results, writes headers and delivers the mail.

Regards,

Christian

-----Original Message-----
From: amavis-users [mailto:amavis-users-bounces+christian.hoyer-reuther=cac-chem.de at amavis.org] On Behalf Of Scappatura Rocco
Sent: Monday, June 05, 2017 4:46 PM
To: 'amavis-users at amavis.org'
Subject: Tag spam only for recipients from a domain

Hi,

I have Debian Lenny with postfix+amavisd-new+spamassassin+clamav.

The settings of amavisd-new port tagging spam are the following:

$sa_spam_subject_tag = '***SPAM*** ';
$sa_tag_level_deflt  = 2.0;  # add spam info headers if at, or above that level
$sa_tag2_level_deflt = 6.31; # add 'spam detected' headers at that level
$sa_kill_level_deflt = 6.31; # triggers spam evasive actions
$sa_dsn_cutoff_level = 10;   # spam level beyond which a DSN is not sent

$sa_mail_body_size_limit = 200*1024; # don't waste time on SA if mail is larger
$sa_local_tests_only = 0;    # only tests which do not require internet access?

$final_banned_destiny     = D_DISCARD;   # D_REJECT when front-end MTA

I need that the messages for recipents of a particular domain (say, example.com) will be scanned as all other messages. Moreover (Unlike the other domains), I would like that the messages for recipents of domain 'example.com', even if the score is >6.31, will not been discarded but have to be marked as SPAM and delivered. 

How I could get a such behaviour from my mail gateway?

Regards,

RS


More information about the amavis-users mailing list