Wietse Venema <wie...@porcupine.org>
>
> d tbsky:
> > Dominic Raferd <domi...@timedicer.co.uk>
> > > The incoming email is saved by always_bcc, why is it important to save it 
> > > again when it is relayed (still I presume with the same 'To:' header, but 
> > > different envelope recipient) to gsmtp? You can find some information 
> > > about the relay transaction in the mail log (smtp). Example:
> > >
> > > 2018-12-20 11:27:56 streamingbats postfix/smtp[25382]: 3241861963: 
> > > to=<annbridgeha...@gmail.com>, orig_to=<a...@streamingbats.co.uk>, 
> > > relay=gmail-smtp-in.l.google.com[108.177.15.26]:25, delay=0.86, 
> > > delays=0.06/0.02/0.26/0.52, dsn=2.0.0, status=sent (250 2.0.0 OK 
> > > 1545305276 i15si6765428wrp.144 - gsmtp)
> >
> >
> > I understand the information is in the log. but I need to archive this
> > information for auditing in the future. so I need this information
> > when postfix bcc the mail.
>
> FYI, none of the Postfix built-in BCC features archives the envelope
> recipient.
>
>         Wietse

  although built-in bcc won't give envelope, there seems some tricky
ways to do. for example:
recipient_delimiter = +
recipient_bcc_maps = pcre:/etc/postfix/bcc_map.cf

and bcc_map.cf:
/^(.*)@(.*)$/      archive+$1=$2@localhost

then I can get the envelope for received mails.
but I can not find the tricky way for sender_bcc_maps.
if I need to write some script to handle this, any suggestion where to hook?
thanks a lot for help!!

Reply via email to