NAME

aliases - Postfix local alias database format

SYNOPSIS



nneewwaalliiaasseess

DESCRIPTION

The aalliiaasseess(5) table provides a system-wide mechanism to redirect mail for local recipients. The redirections are processed by the Postfix llooccaall(8) delivery agent.

Normally, the aalliiaasseess(5) table is specified as a text file that serves as input to the ppoossttaalliiaass(1) command. The result, an indexed file in ddbbmm or ddbb format, is used for fast lookup by the mail system. Execute the command nneewwaalliiaasseess in order to rebuild the indexed file after changing the Postfix alias database.

The input and output file formats are expected to be compatible with Sendmail version 8, and are expected to be suitable for the use as NIS maps.

Users can control delivery of their own mail by setting up ..ffoorrwwaarrdd files in their home directory. Lines in per-user ..ffoorrwwaarrdd files have the same syntax as the right-hand side of aalliiaasseess(5) entries.

The format of the alias database input file is as follows:

· An alias definition has the form



     _n_a_m_e: _v_a_l_u_e_1, _v_a_l_u_e_2, _._._.
· Empty lines and whitespace-only lines are ignored, as
are lines whose first non-whitespace character is a `#'.
· A logical line starts with non-whitespace text. A line that
starts with whitespace continues a logical line.

The _n_a_m_e is a local address (no domain part). Use double quotes when the name contains any special characters such as whitespace, `#', `:', or `@'. The _n_a_m_e is folded to lowercase, in order to make database lookups case insensitive.

In addition, when an alias exists for oowwnneerr--_n_a_m_e, delivery diagnostics are directed to that address, instead of to the originator of the message. This is typically used to direct delivery errors to the maintainer of a mailing list, who is in a better position to deal with mailing list delivery problems than the originator of the undelivered mail.

The _v_a_l_u_e contains one or more of the following:

_a_d_d_r_e_s_s Mail is forwarded to _a_d_d_r_e_s_s, which is compatible
with the RFC 822 standard.
_/_f_i_l_e_/_n_a_m_e Mail is appended to _/_f_i_l_e_/_n_a_m_e. See llooccaall(8)
for details of delivery to file. Delivery is not limited to regular files. For example, to dispose of unwanted mail, deflect it to //ddeevv//nnuullll.
|_c_o_m_m_a_n_d Mail is piped into _c_o_m_m_a_n_d. Commands that contain special
characters, such as whitespace, should be enclosed between double quotes. See llooccaall(8) for details of delivery to command.

When the command fails, a limited amount of command output is mailed back to the sender. The file //uussrr//iinncclluuddee//ssyysseexxiittss..hh defines the expected exit status codes. For example, use ""||eexxiitt 6677"" to simulate a "user unknown" error, and ""||eexxiitt 00"" to implement an expensive black hole.
::iinncclluuddee::_/_f_i_l_e_/_n_a_m_e Mail is sent to the destinations listed in the named file.
Lines in ::iinncclluuddee:: files have the same syntax as the right-hand side of alias entries.

A destination can be any destination that is described in this manual page. However, delivery to "|_c_o_m_m_a_n_d" and _/_f_i_l_e_/_n_a_m_e is disallowed by default. To enable, edit the aallllooww__mmaaiill__ttoo__ccoommmmaannddss and aallllooww__mmaaiill__ttoo__ffiilleess configuration parameters.

ADDRESS EXTENSION



When alias database search fails, and the recipient localpart
contains the optional recipient delimiter (e.g., _u_s_e_r_+_f_o_o),
the search is repeated for the unextended address (e.g., _u_s_e_r).
        

The pprrooppaaggaattee__uunnmmaattcchheedd__eexxtteennssiioonnss parameter controls whether an unmatched address extension (_+_f_o_o) is propagated to the result of table lookup.

CASE FOLDING



The local(8) delivery agent always folds the search string
to lowercase before database lookup.

SECURITY



The llooccaall(8) delivery agent disallows regular expression
substitution of $1 etc. in aalliiaass__mmaappss, because that
would open a security hole.
        

The llooccaall(8) delivery agent will silently ignore requests to use the pprrooxxyymmaapp(8) server within aalliiaass__mmaappss. Instead it will open the table directly. Before Postfix version 2.2, the llooccaall(8) delivery agent will terminate with a fatal error.

CONFIGURATION PARAMETERS



The following mmaaiinn..ccff parameters are especially relevant.
The text below provides only a parameter summary. See
ppoossttccoonnff(5) for more details including examples.
aalliiaass__ddaattaabbaassee List of alias databases that are updated by the
nneewwaalliiaasseess(1) command.
aalliiaass__mmaappss List of alias databases queried by the llooccaall(8) delivery agent.
aallllooww__mmaaiill__ttoo__ccoommmmaannddss Restrict the usage of mail delivery to external command.
aallllooww__mmaaiill__ttoo__ffiilleess Restrict the usage of mail delivery to external file.
eexxppaanndd__oowwnneerr__aalliiaass When delivering to an alias that has an oowwnneerr-- companion alias,
set the envelope sender address to the right-hand side of the owner alias, instead using of the left-hand side address.
pprrooppaaggaattee__uunnmmaattcchheedd__eexxtteennssiioonnss A list of address rewriting or forwarding mechanisms that
propagate an address extension from the original address to the result. Specify zero or more of ccaannoonniiccaall, vviirrttuuaall, aalliiaass, ffoorrwwaarrdd, iinncclluuddee, or ggeenneerriicc.
oowwnneerr__rreeqquueesstt__ssppeecciiaall Give special treatment to oowwnneerr--_l_i_s_t_n_a_m_e and
_l_i_s_t_n_a_m_e--rreeqquueesstt addresses.
rreecciippiieenntt__ddeelliimmiitteerr Delimiter that separates recipients from address extensions.

Available in Postfix version 2.3 and later:

ffrroozzeenn__ddeelliivveerreedd__ttoo Update the local(8) delivery agent's Delivered-To: address
(see prepend_delivered_header) only once, at the start of a delivery; do not update the Delivered-To: address while expanding aliases or .forward files.

STANDARDS


RFC 822 (ARPA Internet Text Messages)

SEE ALSO


local(8), local delivery agent
newaliases(1), create/update alias database
postalias(1), create/update alias database
postconf(5), configuration parameters

README FILES



Use "ppoossttccoonnff rreeaaddmmee__ddiirreeccttoorryy" or
"ppoossttccoonnff hhttmmll__ddiirreeccttoorryy" to locate this information.

DATABASE_README, Postfix lookup table overview

LICENSE



The Secure Mailer license must be distributed with this software.

AUTHOR(S)


Wietse Venema
IBM T.J. Watson Research
P.O. Box 704
Yorktown Heights, NY 10598, USA