Mail server integration#
This documentation applies to Piler enterprise edition 2.2.4+ and piler-smtp 1.1.6+
Revision #1
Publication date: 2026-OCT-17
Overview#
Your mail server sends a copy of every incoming and outgoing email to
piler-smtp by SMTP. To archive the Bcc recipients as well, it encodes each
recipient of the email in the archive address it sends the copy to:
<tenant>+<recipient local part>=<recipient domain>@<archive hostname>
customer1+anna=customer1.com@archive.example.com
piler-smtp decodes the recipients, and Piler archives them like the To
and Cc recipients. How it works and how to set up Piler for it is
described in Envelope recipients.
The guides below show the mail server side.
| Mail server | Method | Guide |
|---|---|---|
| Postfix | recipient_bcc_maps and sender_bcc_maps |
Envelope recipients |
| Axigen | Acceptance & Routing rules, Add recipient action | Axigen |
What every mail server needs#
- One copy per recipient's archive address. The mail server has to
produce the encoded address for each recipient, Bcc recipients included.
Ideally all the addresses of an email go to
piler-smtpin one SMTP transaction; copies that arrive separately are merged withinENVELOPE_MERGE_WINDOW_HOURS(24 hours by default). - Access to piler-smtp. The encoded addresses grant access to emails,
so
piler-smtpmust accept email only from your mail servers: restrict it with a firewall and with its access list (smtp_access_list=1,/etc/piler/smtp.acl). - TLS. If the mail server verifies the certificate offered for
STARTTLS,
piler-smtpneeds a certificate it trusts, e.g. one issued for the archive hostname. - No archive address as a recipient. The archiving rules must not apply
to the archive addresses themselves. Since 1.1.6
piler-smtpignores an archive address of its own hostname encoded again, but not one of another archive host (e.g. a DR site), so the rules have to exclude those.