Added mts.conf.5 page per Neil W Rickert <rickert+nmh@cs.niu.edu>'s report:
[mmh] / man / post.man
1 .\"
2 .\" %nmhwarning%
3 .\" $Id$
4 .\"
5 .\" include the -mh macro file
6 .so %etcdir%/tmac.h
7 .\"
8 .TH POST %manext8% MH.6.8 [%nmhversion%]
9 .SH NAME
10 post \- deliver a message
11 .SH SYNOPSIS
12 .in +.5i
13 .ti -.5i
14 %libdir%/post 
15 \%[\-alias\ aliasfile]
16 .br
17 \%[\-filter\ filterfile] \%[\-nofilter]
18 \%[\-format] \%[\-noformat]
19 .br
20 \%[\-mime] \%[\-nomime]
21 \%[\-msgid] \%[\-nomsgid]
22 \%[\-verbose]
23 .br
24 \%[\-noverbose]
25 \%[\-watch] \%[\-nowatch]
26 \%[\-width\ columns]
27 .br
28 file
29 \%[\-version]
30 \%[\-help]
31 .in -.5i
32 .SH DESCRIPTION
33 \fIPost\fR is the default program called by \fIsend\fR\0(1) to deliver
34 the message in \fIfile\fR to local and remote users.  In fact, most of
35 the features attributed to \fIsend\fR in its manual page are performed by
36 \fIpost\fR, with \fIsend\fR acting as a relatively simple preprocessor.
37 Thus, it is \fIpost\fR which parses the various header fields, appends
38 From: and Date: lines, and interacts with the mail transport system.
39 \fIPost\fR will not normally be called directly by the user.
40
41 \fIPost\fR searches the \*(lqTo:\*(rq, \*(lqcc:\*(rq, \*(lqBcc:\*(rq,
42 \*(lqFcc:\*(rq, and \*(lqResent\-xxx:\*(rq header lines of the specified
43 message for destination addresses, checks these addresses for validity,
44 and formats them so as to conform to ARPAnet Internet Message Format
45 protocol, unless the `\-noformat' flag is set.  This will normally cause
46 \*(lq@\fIlocal\-site\fR\*(rq to be appended to each local destination
47 address, as well as any local return addresses.  The `\-width\ columns'
48 switch can be used to indicate the preferred length of the header
49 components that contain addresses.
50
51 If a \*(lqBcc:\*(rq field is encountered, its addresses will be used for
52 delivery, and the \*(lqBcc:\*(rq field will be removed from the message
53 sent to sighted recipients.  The blind recipients will receive an entirely
54 new message with a minimal set of headers.  Included in the body of the
55 message will be a copy of the message sent to the sighted recipients.
56 If `\-filter\ filterfile' is specified, then this copy is filtered
57 (re\-formatted) by \fImhl\fR prior to being sent to the blind recipients.
58 Alternately, if the `\-mime' switch is given, then \fIpost\fR will use
59 the MIME rules for encapsulation.
60
61 The `\-alias\ aliasfile' switch can be used to specify a file that post
62 should take aliases from.  More than one file can be specified, each
63 being preceded with `\-alias'.  In any event, the primary alias file is
64 read first.
65
66 The `\-msgid' switch indicates that a \*(lqMessage\-ID:\*(rq or
67 \*(lqResent\-Message\-ID:\*(rq field should be added to the header.
68
69 The `\-verbose' switch indicates that the user should be informed of
70 each step of the posting/filing process.
71
72 The `\-watch' switch indicates that the user would like to watch the
73 transport system's handling of the message (e.g., local and \*(lqfast\*(rq
74 delivery).
75
76 Under normal circumstances, \fIpost\fR constructs the "From:" line of the
77 message from the user's login name, the full name from the GECOS field of the
78 passwd file, and the fully\-qualified name of the local machine (or the value of
79 "localname" in mts.conf, if set).  An example is "From: Dan Harkless
80 <dan@machine.company.com>".  There are four ways to override these values,
81 however.  Note that they apply equally to "Resent\-From:" lines in messages sent
82 with \fIdist\fR.
83
84 The first way is GECOS\-based username masquerading.  If the "masquerade:" line
85 in mts.conf contains "mmailid", this processing is activated.  If a user's GECOS
86 field in the passwd file is of the form "Full Name <fakename>" then "fakename"
87 will be used in place of the real username.  For instance, a GECOS field of "Dan
88 Harkless <Dan.Harkless>" would result in "From: Dan Harkless
89 <Dan.Harkless@machine.company.com>".  Naturally if you were doing something like
90 this you'd want to set up an MTA alias (e.g. in /etc/aliases) from, for
91 instance, "Dan.Harkless" to "dan".
92
93 The second way to override default construction of "From:" is to set the
94 \fB$SIGNATURE\fR environment variable.  This variable overrides the full name
95 from the GECOS field, even if GECOS\-based masquerading is being done.  This
96 processing is always active, and does not need to be enabled from mts.conf.
97
98 The third way is controlled by the "user_extension" value of "masquerade:" line
99 of mts.conf.  When that's turned on, setting the \fB$USERNAME_EXTENSION\fR
100 environment variable will result in its value being appended the user's login
101 name.  For instance, if I set \fB$USERNAME_EXTENSION\fR to "+www", my "From:"
102 line will contain "Dan Harkless <dan+www@machine.company.com>" (or
103 "Dan.Harkless+www" if I'm using mmailid masquerading as well).  Recent versions
104 of sendmail automatically deliver all mail sent to \fIuser\fR+\fIstring\fR to
105 \fIuser\fR.  qmail has a similar feature which uses '\-' as the delimiter by
106 default, but can use other characters as well.
107
108 The fourth method of address masquerading is to specify a "From:" line manually
109 in the message draft.  It will be used as provided (after alias substitution),
110 but normally, to discourage email forgery, the user's \fIreal\fR address will be
111 used in the SMTP envelope "From:" and in a "Sender:" header.  However, if the
112 "masquerade:" line of mts.conf contains "draft_from", the SMTP envelope "From:"
113 will use the address given in the draft "From:", and there will be no "Sender:"
114 header.  This is useful in pretending to send mail "directly" from a remote POP3
115 account, or when remote email robots give improper precedence to the envelope
116 "From:".  Note that your MTA may still reveal your real identity (e.g.
117 sendmail's "X\-Authentication\-Warning:" header). 
118
119 .Fi
120 ^%etcdir%/mts.conf~^nmh mts configuration file
121 ^%etcdir%/MailAliases~^global nmh alias file
122 ^%bindir%/refile~^Program to process Fcc:s
123 ^%libdir%/mhl~^Program to process Bcc:s
124 .Pr
125 \fIpost\fR does \fBNOT\fR consult the user's \&.mh\(ruprofile
126 .Sa
127 \fIStandard for the Format of ARPA Internet Text Messages\fR (RFC\-822),
128 .br
129 mhmail(1), send(1), mh\-mail(5), mh\-alias(5), mh\-tailor(5)
130 .De
131 `\-alias %etcdir%/MailAliases'
132 .Ds
133 `\-format'
134 .Ds
135 `\-nomime'
136 .Ds
137 `\-nomsgid'
138 .Ds
139 `\-noverbose'
140 .Ds
141 `\-nowatch'
142 .Ds
143 `\-width\ 72'
144 .Ds
145 `\-nofilter'
146 .Co
147 None
148 .Bu
149 \*(lqReply\-To:\*(rq fields are allowed to have groups in them according
150 to the 822 specification, but \fIpost\fR won't let you use them.
151 .En