For example, the name of the following field is Cc:
Cc: God@heaven.af.mil, email@example.comA field with name Cc is called a ``Cc field''; similar comments apply to ``To field'' and ``Subject field'' and so on.
I recommend against using field name characters other than letters, digits, and hyphens. One program reportedly has trouble with field names containing underscores.
Subject : This is an invalid field822bis explicitly prohibits spaces; several readers (reported: mpack, Cyrus imapd, AMS, and metamail) choke if they see spaces.
However, 822 allowed spaces and tabs before the colon, and there are (unconfirmed) rumors of old messages that include spaces before the colon, so I recommend that readers allow spaces and tabs.
For example, the value of the Cc field shown above is
God@heaven.af.mil, firstname.lastname@example.org two spaces after the comma.
The position of line breaks within a field is irrelevant to the field value. In principle, writers can insert a line break before any space or tab. (822 suggests a more restrictive rule, but it then immediately gives examples disobeying the restrictions.) For example, the field
From: "The boss" < God @ heaven. af (Air Force).mil>has the same value as the field
From: "The boss" < God @ heaven. af (Air Force).mil>In practice, many clients are confused by almost all line breaks within fields, except for line breaks between addresses in a recipient list. Note also that invisible lines are unsafe.
822 states incorrectly that \012 and \015 cannot appear inside field values. 822bis imposes this as a requirement.
Note that there is not necessarily a space after the colon:
Subject:This is valid
Many names have globally recognized semantics. The list of well-known names is constantly expanding; furthermore, writers are allowed to create user-defined fields with new names. Header-reading programs have to be able to handle fields with unrecognized names.
822 specified that all field names are interpreted without regard to case; so Cc and cC and CC and cc have the same meaning. This flexibility is used in practice; for example, many messages have Message-ID, and many messages have Message-Id. On the other hand, the elm filter program looks for only Cc, not cc or CC or cC; and many versions of the vacation program look for only To, not to or TO or tO.
822 suggested, but explicitly did not require, that writers use a particular order for some popular fields: Received, Date, From, Subject, Sender, To, Cc. In practice, those fields appear in several different orders. For example, readers cannot assume that From appears before To.