Header -> amavis quarantine

Dominic Raferd dominic at timedicer.co.uk
Fri Feb 9 18:41:47 CET 2018

On 9 February 2018 at 16:59, Markus Clardy <markus at clardy.eu> wrote:
> On Fri, Feb 9, 2018 at 4:23 PM, Dominic Raferd <dominic at timedicer.co.uk>
> wrote:
>> Is there a way to have the presence of a specific header (or, better,
>> a specific beginning to a header, where the later text might vary)
>> causing quarantining by amavis. Use case is that postfix header_checks
>> will identify a suspect mail and add the header before the mail is
>> passed to amavis.
>> Example header which should lead to amavis quarantining the mail:
>> X-Hold: mydomain.tld; Withheld by order of check_header.pcre (.world
>> domain)
>> I feel sure amavis is powerful enough to do this but the plethora of
>> options, and the perl terminology, leave me baffled. Thanks for any
>> help.
> What you can do is have a port/policy in Amavisd for Quarantining
> everything, then just instead of adding a header in Postfix, have the mail
> redirect to that port.
> This way, mail that is meant to be held as designated by Postfix, will go to
> the quarantine that way.

Thanks Marcus but I want amavis to continue doing its own stuff as
normal as well as quarantining these extra mails. Also it sounds
complicated to resubmit mails via a different port but it is very easy
to add a header using the postfix PREPEND option.

More information about the amavis-users mailing list