home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  

sendmail Desktop Reference

sendmail Desktop ReferenceSearch this book
Previous: 2.7 The Timeout Option Chapter 2
The sendmail.cf File
Next: 2.9 Delivery Agent S= and R=

2.8 Rule Sets

Rule sets are declared in the configuration file by beginning a line with the letter S :









Rule sets are identified either by number or symbolic name . When identified by name, a number is internally assigned by sendmail . An optional = and number may follow a name to force specific association of number to name.

Rule sets numbered 0 through 9 are reserved for sendmail 's internal use. Addresses are rewritten by a specific sequence of rules numbered 0 through 4 (see Figure 2.1 ).

Figure 2.1: Sequence of rule sets; envelope (solid) versus header (dashed)

Figure 2.1

Rewrites all addresses to prepare them for entry into the sequence for rule sets. It usually focuses on the host part of an address and detects the various forms of the local hostname, so that local delivery can take place (see §29.4).


Undoes any special rewriting done by rule set 3. Rule set 4 is always last (see §29.5).


Selects a delivery agent that determines the R= and S= rule sets. It also selects the recipient user (which is separately rewritten and placed into $u ) and the recipient host (which is placed as-is into $h ). (See §.29.6)


Rewrites all sender addresses (see §29.9).


Rewrites all recipient addresses (see §29.8).


(Not shown in Figure 2.1 .) Can select a new delivery agent (just like rule set 0). If the address is not matched in the aliases (5) database, it is passed to rule set 5. Addresses are given to rule set 5 before ~/.forward files are processed (see §29.7).

Previous: 2.7 The Timeout Option sendmail Desktop Reference Next: 2.9 Delivery Agent S= and R=
2.7 The Timeout Option   2.9 Delivery Agent S= and R=