Thanks. I tried that route, but Postfix only writes X-Original-To in its own final-delivery agents (local, virtual, pipe); the lmtp client doesn't add it. Of 18 messages delivered over LMTP in the last day, 17 have no X-Original-To, and the one that does carries [email protected], inserted by Debian's list server upstream.
That second point is why I'd rather not rely on the header fallback: it reads whatever X-Original-To the message arrives with, so the "original recipient" can be set by a remote server or by the sender. ORCPT comes from the delivering MTA in the envelope and doesn't have that problem. So the request stands: could LMTP advertise DSN (optionally behind a setting) so MTAs send ORCPT? On (Tue) Oct 20, 2026 11:00 am, Stephan Bosch via dovecot <[email protected]> wrote: >Op 9-10-2026 om 22:29 schreef Dhaval Patel via dovecot: >> If there's an existing way to get this that I've missed, I'd be glad to hear >> it. > > >https://doc.dovecot.org/2.4.5/core/summaries/settings.html#lda_original_recipient_header: > >lda_original_recipient_header > > The header from which the original recipient address (used in the >SMTP RCPT TO: address) is obtained if that address is not available >elsewhere. > > With LDA the default is based on the username in -d parameter. With >LMTP Server the default is the same as RCPT TO. > > Example: > > lda_original_recipient_header = X-Original-To > > > >https://www.postfix.org/postconf.5.html: > >enable_original_recipient (default: yes) > > Enable support for the original recipient address after an address >is rewritten to a different address (for example with aliasing or with >canonical mapping). > > The original recipient address is used as follows: > > Final delivery > With "enable_original_recipient = yes", the original recipient >address is stored in the X-Original-To message header. This header may >be used to distinguish between different recipients that share the same >mailbox. > >_______________________________________________ >dovecot mailing list -- [email protected] >To unsubscribe send an email to [email protected] _______________________________________________ dovecot mailing list -- [email protected] To unsubscribe send an email to [email protected]
