Added -mts switch to post, send, and whom. Replaced test-sendmail-pipe
[mmh] / man / mh-tailor.man
index 4304dc8..5709271 100644 (file)
@@ -1,10 +1,9 @@
 .\"
 .\" %nmhwarning%
 .\"
 .\" %nmhwarning%
-.\" $Id$
 .\"
 .TH MH-TAILOR %manext5% "%nmhdate%" MH.6.8 [%nmhversion%]
 .SH NAME
 .\"
 .TH MH-TAILOR %manext5% "%nmhdate%" MH.6.8 [%nmhversion%]
 .SH NAME
-mh-tailor, mts.conf \- mail transport customization for nmh message handler
+mh-tailor, mts.conf \- mail transport configuration for nmh message handler
 .SH SYNOPSIS
 .I %etcdir%/mts.conf
 .SH DESCRIPTION
 .SH SYNOPSIS
 .I %etcdir%/mts.conf
 .SH DESCRIPTION
@@ -30,10 +29,12 @@ default values and a description of their meanings are listed below:
 .PP
 .BR mts :
 .RS 5
 .PP
 .BR mts :
 .RS 5
-The mail transport method to use.  The two acceptable options are
+The mail transport method to use.  The three acceptable options are
 .B smtp
 .B smtp
-(which is the default), and
-.BR sendmail .
+(which is the default),
+.BR sendmail/smtp ,
+and
+.BR sendmail/pipe .
 .PP
 If you use
 .BR smtp ,
 .PP
 If you use
 .BR smtp ,
@@ -49,15 +50,33 @@ to the mail port on the machine specified in the
 entry.
 .PP
 If you use
 entry.
 .PP
 If you use
-.BR sendmail ,
+.BR sendmail/smtp ,
 then
 .B post
 will send messages by forking a
 local copy of
 .BR sendmail .
 then
 .B post
 will send messages by forking a
 local copy of
 .BR sendmail .
-Currently it will still speak SMTP with this local
-copy of
+It will still speak SMTP with this local copy of
+.BR sendmail .
+For backward compatibility,
+.B sendmail/smtp
+can be abbreviated to
 .BR sendmail .
 .BR sendmail .
+.PP
+The third alternative,
+.BR sendmail/pipe ,
+also forks a local copy of
+.B sendmail
+but feeds the message directly to it, using
+.B sendmail
+.BR -t .
+This replaces the old, undocumented
+.B spost
+mechanism and retains some of its limitations, such as lack of
+support for the
+.B \-whom
+switch and
+\*(lqDcc:\*(rq header field.
 .RE
 .PP
 .BR localname :
 .RE
 .PP
 .BR localname :
@@ -109,7 +128,7 @@ above).  If this option is set, but empty, no
 command will be given.
 .PP
 Although the
 command will be given.
 .PP
 Although the
-/B HELO
+.B HELO
 command is required by RFC\-821, many SMTP servers
 do not require it.  Early versions of
 .I SendMail
 command is required by RFC\-821, many SMTP servers
 do not require it.  Early versions of
 .I SendMail
@@ -165,79 +184,6 @@ The beginning-of-message delimiter for maildrops.
 The end-of-message delimiter for maildrops.
 .RE
 .PP
 The end-of-message delimiter for maildrops.
 .RE
 .PP
-.BR masquerade:
-.RS 5
-This directive controls three different types of email address masquerading.
-The three possible values, which may be specified in any combination on the
-line, separated by spaces, are \*(lqdraft_from\*(rq, \*(lqmmailid\*(rq, and
-\*(lqusername_extension\*(rq.
-.PP
-\*(lqmmailid\*(rq was the only type of masquerading in the original MH package, and
-apparently stands for \*(lqmasquerade mail identification\*(rq.  This type of
-masquerading keys off of the GECOS field of the passwd file.  When enabled,
-.B nmh
-will check if the user's pw_gecos field in the passwd file is of the
-form:
-.PP
-.RS 5
-Full Name <fakeusername>
-.RE
-.PP
-If it is, the internal
-.B nmh
-routines that find the username and full name
-of that user will return \*(lqfakeusername\*(rq and \*(lqFull Name\*(rq respectively.  This is
-useful if you want the messages you send to always appear to come from the name
-of an MTA alias rather than your actual account name.  For instance, many
-organizations set up \*(lqFirst.Last\*(rq sendmail aliases for all users.  If this is
-the case, the GECOS field for each user should look like:
-.PP
-.RS 5
-First [Middle] Last <First.Last>
-.RE
-.PP
-\*(lqusername_extension\*(rq, when specified on the \*(lqmasquerade:\*(rq line, allows a second
-type of username masquerading.  If the user sets the
-.B $USERNAME_EXTENSION
-environment variable, its value will be appended to the actual login name.  For
-instance, if I am \*(lqdan@company.com\*(rq, and I set
-.B $USERNAME_EXTENSION
-to \*(lq\-www\*(rq, my mail will appear to come from \*(lqdan\-www@company.com\*(rq.  This is meant
-to interact with qmail's \*(lquser\-extension\*(rq feature, where mail sent to
-.IR user \- string
-will be delivered to
-.IR user .
-Likewise, those using
-versions of sendmail for which \*(lqplussed user\*(rq processing is active can set
-.B $USERNAME_EXTENSION
-to \*(lq+\fIstring\fR\*(rq.  These MTA features are useful
-because they allow one to use different email addresses in different situations
-(to aid in automatic mail filtering or in determining where spammers got one's
-address) while only actually having a single account.  Note that
-.B $USERNAME_EXTENSION
-is only appended to the username when \fIpost\fR is
-generating \*(lq[Resent\-]From:\*(rq lines and the SMTP envelope
-\*(lqFrom:\*(rq.
-.BR inc ,
-for instance, will not try to read from a maildrop file called \*(lqdan\-www\*(rq (to
-recall the earlier example).
-.PP
-\*(lqdraft_from\*(rq controls the most powerful type of address masquerading.  Normally,
-when a user explicitly specifies a \*(lqFrom:\*(rq header in a draft,
-.B nmh
-uses it
-rather than constructing its own.  However, to discourage email forgery, the
-SMTP envelope \*(lqFrom:\*(rq and a \*(lqSender:\*(rq header are set to the user's real address.
-When \*(lqdraft_from\*(rq is turned on, though, the envelope \*(lqFrom:\*(rq will use the
-address specified in the draft, and there will be no \*(lqSender:\*(rq header.  This is
-useful when a user wants to pretend to be sending mail \*(lqdirectly\*(rq from a remote
-POP3 account, or when remote mail robots incorrectly use the envelope \*(lqFrom:\*(rq in
-preference to the body \*(lqFrom:\*(rq (or refuse to take action when the two don't
-match).  Note that the MTA may still reveal the user's real identity (e.g.
-.BR sendmail 's
-\*(lqX\-Authentication\-Warning:\*(rq header).
-.RE
-.PP
 .BR maildelivery :
 %libdir%/maildelivery
 .RS 5
 .BR maildelivery :
 %libdir%/maildelivery
 .RS 5
@@ -264,43 +210,20 @@ indicates that mail for \*(lqeveryone\*(rq should not be sent to them.
 This is useful for handling admin, dummy, and guest logins.
 .RE
 .SS "SMTP support"
 This is useful for handling admin, dummy, and guest logins.
 .RE
 .SS "SMTP support"
-These options are only available if you set
+This option is only available if you set
 .B mts
 to
 .BR smtp .
 .PP
 .B mts
 to
 .BR smtp .
 .PP
-.BR hostable :
-%etcdir%/hosts
-.RS 5
-The exceptions file for /etc/hosts used by
-.B post
-to try to find
-official names.  The format of this file is quite simple:
-.PP
-.IP 1. 4
-Comments are surrounded by sharp (`#') and newline.
-.IP 2. 4
-Words are surrounded by white space.
-.IP 3. 4
-The first word on the line is the official name of a host.
-.IP 4. 4
-All words following the official names are aliases for that host.
-.RE
-.PP
 .BR servers :
 .BR servers :
-localhost \\01localnet
+localhost
 .RS 5
 A lists of hosts and networks which to look for SMTP servers when
 .RS 5
 A lists of hosts and networks which to look for SMTP servers when
-posting local mail.  It turns out this is a major win for hosts which
-don't run an message transport system.  The value of
+posting non\-local mail.  It turns out this is a major win for hosts
+which don't run an message transport system.  The value of
 .B servers
 .B servers
-should be one or more items.  Each item is the name of either a host
-or a net (in the latter case, precede the name of the net by a \\01).
-This list is searched when looking for a smtp server to post mail.
-If a host is present, the SMTP port on that host is tried.  If a net
-is present, the SMTP port on each host in that net is tried.  Note that
-if you are running with the BIND code, then any networks specified are
-ignored (sorry, the interface went away under BIND).
+should be one or more items.  Each item is the name of a host which
+is (hopefully) running a SMTP server.
 .SS "SendMail"
 This option is only available if you set
 .B mts
 .SS "SendMail"
 This option is only available if you set
 .B mts
@@ -363,15 +286,6 @@ the named POP service host is consulted.
 \"  BBoards service host.
 \"  .RE
 
 \"  BBoards service host.
 \"  .RE
 
-\"  .SS "BBoards & The NNTP"
-\"  This option is only available if you compiled \fInmh\fP with
-\"  \*(lqbboards:\ nntp\*(rq and \*(lqpop:\ on\*(rq.
-\"  .PP
-\"  .BR nntphost :
-\"  .RS 5
-\"  The host which provides the NNTP service.  This variable should be set
-\"  on the NNTP BBoards client host.
-\"  .RE
 .SS "File Locking"
 A few words on locking:
 .B nmh
 .SS "File Locking"
 A few words on locking:
 .B nmh
@@ -402,12 +316,11 @@ specifies that
 a file should be created whose existence means \*(lqlocked\*(rq and
 whose non-existence means \*(lqunlocked\*(rq.  The name of this file is
 constructed by appending \*(lq.lock\*(rq to the name of the file being
 a file should be created whose existence means \*(lqlocked\*(rq and
 whose non-existence means \*(lqunlocked\*(rq.  The name of this file is
 constructed by appending \*(lq.lock\*(rq to the name of the file being
-locked.  If
-.B LOCKDIR
-is not specified, lock files will be created
+locked.  If \*(lq--enable-lockdir=directory\*(rq
+is not specified at build time, lock files will be created
 in the directory where the file being locked resides.  Otherwise, lock
 files will be created in the directory specified by
 in the directory where the file being locked resides.  Otherwise, lock
 files will be created in the directory specified by
-.BR LOCKDIR .
+\*(lq--enable-lockdir\*(rq.
 .PP
 Prior to installing
 .BR nmh ,
 .PP
 Prior to installing
 .BR nmh ,
@@ -417,8 +330,9 @@ your site, and set the appropriate values.
 .SH FILES
 .fc ^ ~
 .nf
 .SH FILES
 .fc ^ ~
 .nf
-.ta \w'/usr/local/nmh/etc/ExtraBigFileName  'u
+.ta \w'%etcdir%/ExtraBigFileName  'u
 ^%etcdir%/mts.conf~^nmh mts configuration file
 ^%etcdir%/mts.conf~^nmh mts configuration file
+.fi
 
 .SH "PROFILE COMPONENTS"
 None
 
 .SH "PROFILE COMPONENTS"
 None
@@ -427,4 +341,19 @@ None
 mh\-mts(8), post(8)
 
 .SH DEFAULTS
 mh\-mts(8), post(8)
 
 .SH DEFAULTS
-As listed above
+As listed above.  The path of the mail transport configuration
+file can be changed with the
+.B MHMTSCONF
+environment variable and augmented with the
+.B MHMTSUSERCONF
+environment variable, see mh\-profile(5).
+
+.SH BUGS
+Failure to open any mail transport configuration file is silently
+ignored.  Therefore, it's best to avoid dynamic creation of such
+a file with the intent of use via the
+.B MHMTSCONF
+or
+.B MHMTSUSERCONF
+environment variables.  If such use is necessary, the ability
+to successfully open the file should first be verified.