FEATURE(masquerade_envelope)

Masquerade the envelope as well as headers V8.7 and later

Ordinarily, masquerading (Masquerading on page 598) affects only the headers of email messages, but sometimes it is also desirable to masquerade the envelope.[243] For example, error messages are often returned to the envelope-sender address. When many hosts are masquerading as a single host, it is often desirable to have all error messages delivered to that central masquerade host.

FEATURE(masquerade_envelope) causes masquerading to include envelope addresses:

MASQUERADE_AS(`our.domain')        ← masquerade headers
FEATURE(`masquerade_envelope')     ← also masquerade the envelope

These mc lines cause all envelope addresses (where the host part is declared as part of class $=w; $=w on page 876) to be transformed into our.domain. See MASQUERADE_DOMAIN for a way to also masquerade other domains, and see FEATURE(masquerade_entire_domain) for a way to also masquerade all the hosts under other domains.

In general, masquerade_envelope is recommended for uniform or small sites. Large or variegated sites might prefer to tailor the envelope on a subdomain-by-subdomain or host-by-host basis.

[243] * See The Envelope on page 9 for a description of the envelope and how it differs from headers.

Get sendmail, 4th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.