DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Sendmail Installation and Operation Guide
SMM:08-59
H
[?${macro}?]hname: htemplate
Continuation lines in this spec are reflected directly into the outgoing message. The htemplate is
macro-expanded before insertion into the message. If the mflags (surrounded by question marks)
are specified, at least one of the specified flags must be stated in the mailer definition for this header
to be automatically output. If a ${macro} (surrounded by question marks) is specified, the header
will be automatically output if the macro is set. The macro may be set using any of the normal
methods, including using the macro storage map in a ruleset. If one of these headers is in the input
it is reflected to the output regardless of these flags or macros. Notice: If a ${macro} is used to set a
header, then it is useful to add that macro to class $={persistentMacros} which consists of the
macros that should be saved across queue runs.
Some headers have special semantics that will be described later.
A secondary syntax allows validation of headers as they are being read. To enable validation,
use:
HHeader: $>Ruleset
HHeader: $>+Ruleset
The indicated Ruleset is called for the specified Header, and can return $#error to reject or quaran-
tine the message or $#discard to discard the message (as with the other check_* rulesets). The
ruleset receives the header field-body as argument, i.e., not the header field-name; see also
${hdr_name} and ${currHeader}. The header is treated as a structured field, that is, text in paren-
theses is deleted before processing, unless the second form $>+ is used. Note: only one ruleset can
be associated with a header; sendmail will silently ignore multiple entries.
For example, the configuration lines:
HMessage-Id: $>CheckMessageId
SCheckMessageId
R< $+ @ $+ >
$@ OK
R$*
$#error $: Illegal Message-Id header
would refuse any message that had a Message-Id: header of any of the following forms:
Message-Id: <>
Message-Id: some text
Message-Id: <legal text@domain> extra crud
A default ruleset that is called for headers which don't hav e a specific ruleset defined for them can
be specified by:
H*: $>Ruleset
or
H*: $>+Ruleset
5.6. O -- Set Option
There are a number of global options that can be set from a configuration file. Options are
represented by full words; some are also representable as single characters for back compatibility.
The syntax of this line is:
O option=value
This sets option option to be value. Note that there must be a space between the letter `O' and the
name of the option. An older version is:
Oo value
where the option o is a single character. Depending on the option, value may be a string, an integer,