RFC 1524 (rfc1524) - Page 3 of 12


A User Agent Configuration Mechanism For Multimedia Mail Format Information



Alternative Format: Original Text Document



RFC 1524             Multimedia Mail Configuration        September 1993


   Thus the overall format of a mailcap file is given, in the modified
   BNF of RFC 822, as:

         Mailcap-File = *Mailcap-Line

         Mailcap-Line = Comment / Mailcap-Entry

         Comment = NEWLINE  /  "#" *CHAR NEWLINE

         NEWLINE = 

   Note that the above specification implies that comments must appear
   on lines all to themselves, with a "#" character as the first
   character on each comment line.

Format of a Mailcap Entry

   Each mailcap entry consists of a number of fields, separated by
   semi-colons.  The first two fields are required, and must occur in
   the specified order.  The remaining fields are optional, and may
   appear in any order.

   The first field is the content-type, which indicates the type of data
   this mailcap entry describes how to handle.  It is to be matched
   against the type/subtype specification in the "Content-Type" header
   field of an Internet mail message.  If the subtype is specified as
   "*", it is intended to match all subtypes of the named content-type.

   The second field, view-command, is a specification of how the message
   or body part can be viewed at the local site.  Although the syntax of
   this field is fully specified, the semantics of program execution are
   necessarily somewhat operating system dependent.  UNIX semantics are
   given in Appendix A.

   The optional fields, which may be given in any order, are as follows:

   -- The "compose" field may be used to specify a program that can be
      used to compose a new body or body part in the given format.  Its
      intended use is to support mail composing agents that support the
      composition of multiple types of mail using external composing
      agents.  As with the view-command, the semantics of program
      execution are operating system dependent, with UNIX semantics
      specified in Appendix A.  The result of the composing program may
      be data that is not yet suitable for mail transport -- that is, a
      Content-Transfer-Encoding may need to be applied to the data.

   -- The "composetyped" field is similar to the "compose" field, but is
      to be used when the composing program needs to specify the



Borenstein