The description of an action in the chainmail configuration file consists of a keyword - action name - followed by zero, one or several quoted strings - action parameters. Note that parameters must by double-quoted and separated by blanks.
Chainmail knows about the following actions:
AddRcpt "address". Add recipient "address" to the message.
DelRcpt "address". Remove recipient "address" from message. If "address" was not among the message recipients, nothing happens.
Reject "code" "enh_code" "reply". Reject the message. All the three parameters are optional and may be omitted. If the "code" parameter is given, it must be a valid SMTP status code (three digits starting with 5). If the "enh_code" parameter is given it must be valid SMTP enhanced status code (as defined in RFC1893). If the "reply" parameter is given, it will be used as SMTP reply text. Note that if any of the tree parameters is given, but is am empty string (""), the default value will be used, as if the parameter as not given.
Reject with generic code and message:
Reject with custom codes and message:
Reject "550" "5.7.1" "This message violates our policy"
Tempfail "code" "enh_code" "reply". Temporarily fail the message. This differs from Reject action in that rejected message will not be resent again, while temporarily failed message will be resend again later. The meaning of the parameters is the same. The "code" parameter, is given, must start with digit 4.
Temporarily fail with generic code and message:
Temporarily fail with custom codes and message:
Tempfail "451" "4.7.1" "The system is down for maintenance, contact support"
Discard. Discard the message. The message will be silently dropped, without indicating any error to the message sender.
Accept. Accept the message immediately without trying any further chainmail rules.