Hi,
On Wed, Apr 21, 2021 at 11:31 AM Dominic Raferd <[email protected]> wrote:
>
> On 21/04/2021 16:17, Alex wrote:
> > I have postfix configured in a multi-instance setup in conjunction
> > with amavisd. I'm using always_bcc to create a copy of each email sent
> > or received.
> >
> > The problem is that, while postfix appears to deliver the bcc-user
> > email separately from the other recipients, amavis somehow delivers to
> > all the recipients, including the bcc-user, as one email.
> >
> > How do I configure always_bcc to bypass amavisd altogether so it isn't
> > processed at all?
> >
> > # postconf -c /etc/postfix-116 always_bcc
> > always_bcc = bcc-user
> >
> > I'm unsure what postconf details I can provide, so I'll instead just
> > provide the log entries.
> >
> > Apr 21 10:58:24 xavier postfix-out/local[2682940]: 19D63305F4A09:
> > to=<[email protected]>, relay=local, delay=0.01, delays=0.01/0/0/0,
> > dsn=2.0.0, status=sent (delivered to command: /usr/bin/procmail)
> >
> > ...
>
> If you are running amavis as a content filter, you need the initial
> postfix instance (which feeds into amavis) to have
>
> receive_override_options = no_address_mappings
>
> and then permit mappings (which include always_bcc) to occur in the 2nd
> instance (for the mail that is returned by amavis), for example this
> might be in master.cf by:
>
> 127.0.0.1:10025 inet n - n - - smtpd
> # note: absence of no_address_mappings means that address mapping
> *will* occur here, including always_bcc
> -o receive_override_options=no_unknown_recipient_checks,no_milters
> ...
Okay, got it, thanks. This is now what I currently have:
127.0.0.1:10025 inet n - n - 16 smtpd
-o content_filter=
-o smtpd_delay_reject=no
-o smtpd_client_restrictions=permit_mynetworks,reject
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,reject
-o smtpd_data_restrictions=reject_unauth_pipelining
-o smtpd_end_of_data_restrictions=
-o smtpd_restriction_classes=
-o mynetworks=127.0.0.0/8,209.111.90.0/24,209.222.85.153/29
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
-o smtpd_client_connection_count_limit=0
-o smtpd_client_connection_rate_limit=0
-o
receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_milters,no_address_mappings
-o local_header_rewrite_clients=
Thanks so much,
Alex