Name

MustQuoteChars

Synopsis

All addresses are composed of address information and nonaddress information. The two most common forms of addresses look like this:

address (nonaddress)
nonaddress <address>

Usually, the nonaddress information is a user’s full name or something similar. RFC2822 requires that certain characters be quoted if they appear in the nonaddress part of an address:

@ , ; : \ ( ) [ ] . ' < >

Note that here we show angle brackets, although they will not be part of this option’s setting (they are set internally by sendmail).

Nonaddress information inside parentheses is already quoted by those parentheses. But nonaddress information that is outside parentheses and contains any of these characters needs to be quoted with full quotation marks. To illustrate, consider this address:

From: Bob@home <bob@here.uofa.edu>

Because the nonaddress part Bob@home contains an @ character, sendmail is required to quote the entire phrase, thus forming:

From: "Bob@home" <bob@here.uofa.edu>

Note that the address part contains angle brackets that are not quoted. They are unquoted because they surround the address part, and are not considered part of the nonaddress part.

If you wish to add characters to the mandatory list of characters that will be quoted, you can do so with the MustQuoteChars option, the forms of which are as follows:

O MustQuoteChars=more                  configuration file (V8.8 and later) 
-OMustQuoteChars=more                  command line (V8.8 and later) 
define(`confMUST_QUOTE_CHARS', `more')

Get Sendmail, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.