On Thu, 7 Feb 2019 at 04:46, Tom Robinson <[email protected]> wrote:

> bump
> On 5/2/19 12:08 pm, Tom Robinson wrote:
>
> Hi,
>
> I'm sure this has been answered before but I just can't seem to find the
> right settings.
>
> I want the recipient of a quarantined SPAM email to receive a notification
> that it was quarantined.
>
> Notifications are working for viruses that get quarantined but I can't get
> it to work for SPAM.
>
> I have the following in my amavisd.conf
>
> $virus_admin               = "postmaster\@$mydomain";                   #
> notifications recip.
> $mailfrom_notify_admin     = "virusalert\@$mydomain";                   #
> notifications sender
> $mailfrom_notify_recip     = "virusalert\@$mydomain";                   #
> notifications sender
> $mailfrom_notify_spamadmin = "spamalert\@$mydomain";                    #
> notifications sender
> $mailfrom_to_quarantine = ''; # null return path; uses original sender if
> undef
>
> $final_virus_destiny      = D_DISCARD;
> $final_banned_destiny     = D_DISCARD;
> $final_spam_destiny       = D_DISCARD;  #!!!  D_DISCARD / D_REJECT
> $final_bad_header_destiny = D_PASS;
> $virus_quarantine_method        = 'local:virus/%m';
> $spam_quarantine_method         = 'local:spam/%m.gz';
> $banned_files_quarantine_method = 'local:banned/%m';
> $bad_header_quarantine_method   = 'local:badh/%m';
>
> $warnvirusrecip = 1;
> $warnbannedrecip = 1;
> $warnbannedsender = 0;
>
> Try: https://lists.amavis.org/pipermail/amavis-users/2012-July/001717.html
I'm not clear how amavis decides whether a recipient is 'local'. Might be
worth setting $warn_offsite to 1 if only to rule this out.

Looking at comments in amavisd-new code 2.11.0 it seems that
warnbannedrecip is deprecated in favour of warnbannedrecip_maps (although
it should still work).

You aren't using any named policy banks are you? If so, it might also need
to be set explicitly inside each named policy bank (as do a lot of things,
sadly), and with different syntax (warnbannedrecip  => 1,).

Reply via email to