Rules

Rules are the main part of the chainmail configuration file. Rules define which messages chainmail selects for processing and what kind of processing it applies to those messages. Each rule specifies a condition and actions. When an email message matches the condition, the actions are executed. What conditions and actions are supported by chainmail is described further in this document.

Each rule is described by the following construct in the configuration file:

Rule "Name" Flags
If Condition
Action Actions

where:

Rules are tried in sequence. Whenever a rule's condition matches, rule's actions are executed. If the rule doesn't have the Continue flag specified the processing of the message stops then. If the flag is specified, then processing continues, and other rules are tried.