c4558bec7dcfc9be7aead3b47e45242a602fd83a
[mmh] / man / spost.man8
1 .\"
2 .\" %nmhwarning%
3 .\"
4 .TH SPOST %manext8% "%nmhdate%" MH.6.8 [%nmhversion%]
5 .SH NAME
6 spost \- feed a message to sendmail
7 .SH SYNOPSIS
8 .HP 5
9 .na
10 .HP 5
11 .B spost
12 .RB [ \-verbose " | " \-noverbose ]
13 .I file
14 .RB [ \-Version ]
15 .RB [ \-help ]
16 .ad
17 .SH DESCRIPTION
18 .B Spost
19 is the program called by
20 .B send
21 to feed the message in
22 .I file
23 to
24 .B sendmail
25 for delivery.  In fact, many of
26 the features attributed to
27 .B send
28 in its manual page are performed by
29 .BR spost ,
30 with
31 .B send
32 acting as a preprocessor.
33 Thus, it is
34 .B spost
35 which parses the various header fields, appends
36 `From:' and `Date:' lines,
37 and finally feeds the message to the MTA.
38 .B Spost
39 will not normally be called directly by the user.
40 .PP
41 .B Spost
42 searches the `To:', `Cc:', `Bcc:', `Dcc',
43 `Fcc:', and `Resent\-xxx:' header lines of the specified
44 message for destination addresses,
45 .PP
46 .B Spost
47 invokes
48 .B sendmail
49 with all recipients, except the blind ones (`Bcc:'),
50 as command line arguments:
51 .RS
52 .B sendmail
53 .B \-i
54 .RB [ \-v ]
55 .I recipients ...
56 .RE
57 .PP
58 If a `Bcc:' field is encountered, its addresses will be used for
59 delivery, and the `Bcc:' field will be removed from the message
60 sent to sighted recipients.  The blind recipients will receive a newly
61 constructed message with a copy of the original message attached.
62 MIME rules are used for encapsulation.
63 .RB ( spost
64 invokes
65 .B send
66 to send the Bcc message.)
67 .PP
68 If a `Dcc' field is encountered, the field will be removed
69 before sending the message. The Dcc recipient will receive the
70 message as well, but without being mentioned in the recipient
71 headers.
72 .PP
73 In contrast to Bcc, the Dcc recipient receives the
74 same original message as all the sighted reciepients, whereas
75 the Bcc recipient receives a special, newly constructed message,
76 which contains the original message as an attachment.
77 .PP
78 Bcc is probably a good choice for a message with both sighted
79 and invisible reciepients (e.g. inform someone privately about
80 the message being sent). Dcc is probably a good choice for
81 a message to a group of only invisible recipients (e.g. invite
82 to a party).
83 .PP
84 The `Aliasfile' profile entry
85 can be used to specify one or more files that spost
86 should take aliases from.
87 .PP
88 Aliasing is done on any address field. Those are:
89 `From:', `To:', `Cc:', `Bcc:' and `Dcc',
90 or the `Resent\-xxx:' versions of these fields.
91 .PP
92 The
93 .B \-verbose
94 switch enables informational messages.
95 For example, the `\-v' switch will be added to the
96 .B sendmail
97 invocation.
98 .PP
99 .B Spost
100 puts the
101 .RI ` Default-From '
102 profile entry in the `From:' line of the message.
103 If `Default-From' is not set,
104 .B spost
105 constructs the `From:' line of the
106 message from the user's login name and the full name from the GECOS field
107 of the passwd file.
108 An example is `From: Dan Harkless <dan>'.
109 .PP
110 If you set the
111 .B $SIGNATURE
112 environment variable.
113 Its value overrides the full name from the GECOS field.
114 .PP
115 If you specify a `From:'
116 line manually in the message draft.
117 It will be used as provided.
118 A `Sender:' header with the user's
119 .B real
120 address will be added, if the `From' line don't contain a address
121 from the user
122 .RI ` Alternate-Mailboxes '.
123 .PP
124 Note that this applies equally to `Resent\-From:' lines
125 in messages sent with
126 .BR dist .
127 .PP
128 .B Spost
129 tries to fully qualify the addresses in every address field.
130 Your MTA is supposed to add the correct domain,
131 if there is none after aliasing.
132 .PP
133 The draft is filed to the folders in the Fcc headers by
134 .BR refile .
135
136 .SH FILES
137 .fc ^ ~
138 .nf
139 .ta \w'ExtraBigFileName  'u
140 None
141 .fi
142
143 .SH "PROFILE COMPONENTS"
144 .fc ^ ~
145 .nf
146 .ta 3.5i
147 .ta \w'ExtraBigProfileName  'u
148 ^Aliasfile:~^For default alias files
149 ^Default\-From:~^The default From header
150 ^Alternate\-Mailboxes:~^The user's addresses
151 .fi
152
153 .SH "SEE ALSO"
154 send(1), mh\-mail(5), mh\-alias(5), mh\-tailor(5), refile(1),
155 .I "Standard for the Format of ARPA Internet Text Messages"
156 (RFC\-822)
157
158 .SH DEFAULTS
159 .nf
160 .RB ` \-noverbose '
161 .fi
162
163 .SH CONTEXT
164 None
165
166 .SH BUGS
167 None
168
169 .SH HISTORY
170 The
171 .B spost
172 in mmh-0.1 used
173 .BR sendmail 's
174 .I -t
175 flag to have
176 .B sendmail
177 extract the recipients from the message headers. Now, it
178 passes the recipients as command line arguments. This provides
179 better compatibility to other sendmail implementations.