Substitutions are used to abbreviate user names or addresses by inserting a character string into the rewritten address, the value of which is determined by the particular substitution sequence used. For example, in the template:
the $U is a substitution sequence. It causes the username portion of the address being rewritten to be substituted into the output of the template. Thus, if jdoe@mailhost.acme.com was being rewritten by this template, the resulting output would be jdoe@acme.com, the $U substituting in the username portion, jdoe, of the original address.
Substitution Sequence
|
Substitutes
|
$D
|
Portion of domain specification that matched
|
$H
|
Unmatched portion of host/domain specification; left of dot in pattern
|
$L
|
Unmatched portion of domain literal; right of dot in pattern literal
|
$U
|
Username from original address
|
$$
|
Inserts a literal dollar sign ($)
|
$%
|
Inserts a literal percent sign (%)
|
$@
|
Inserts a literal at sign (@)
|
$\
|
Force material to lowercase
|
$^
|
Force material to uppercase
|
$_
|
Use original case
|
$W
|
Substitutes in a random, unique string
|
$[...]
|
Invoke customer-supplied routine; substitute in result
|
$(text)
|
General database substitution; rule fails if lookup fails
|
${...}
|
Apply specified mapping to supplied string
|
$&n
|
nth part of unmatched (or wild card) host, as counting from left to right, starting from 0
|
$!n
|
nth part of unmatched (wild card) host, as counted from right to left, starting from 0
|
$*n
|
nth part of matching pattern, as counting from left to right, starting from 0
|
$#n
|
nth part of matching pattern, as counted from right to left, starting from 0
|