Hi all,
We recently had a discussion in the inn-workers mailing list about mails sent to moderators.
The common command line used to send such mails is:
/usr/lib/sendmail -oi -oem %s
where %s is replaced by the address of the moderator.
Could it be improved to notably receive errors, and how?
As a few mail experts lurk in this newsgroup, I believe we'll manage to find the right options to use :-)
To start the discussion, here is a proposal for an improved wording for the "mta" parameter in INN, based on a feedback from Grant and Russ.
*mta*
The command to use when sending a mail (e.g. mailing postings to
moderators, gatewaying news to mail, sending statistics to the
TOP1000 project, mailing errors and reports to the news
administrator). Some programs use innmail(1) which in turn runs
*mta*. The message, with its headers, will be piped into this *mta*
program. Depending on the calling program, additional header fields
may be added when appropriate, like To, Subject or Auto-Submitted
header fields.
The string %s, if present, will be replaced by the expected
recipient(s) like the e-mail address of the moderator or of a remote
list. It's strongly recommended for this command to end with %s on
the command line rather than, when not present, use the addresses in
the To and Cc header fields of the message, since the latter
approach allows the news server to be abused as a mechanism to send
mail to arbitrary addresses and will result in unexpected behavior.
There is no default value for this parameter; it must be set in
inn.conf or a fatal error message will be logged via syslog.
For most systems, "/usr/lib/sendmail -oi -oem %s" (adjusted for the
correct path to sendmail, and between double quotes) is a good
choice.
To improve deliverability of sent mails, especially moderated group
submissions, you are encouraged to install a modern and
full-featured MTA like Postfix instead of a frugal MTA like
Nullmailer. You'll then be able to configure bounces and benefit
from DSN (Delivery Status Notifications). Useful flags to add, if
your *mta* program supports them, are "-N failure" (to only return a
DSN on failure, not delay), "-F "Newsmaster"" (to set the full name
of the notification), "-fnewsmaster" (to set the envelope sender
address), and "-opnobodyreturn" (a privacy option to only return
headers in the DSN). Feel free to add any other options you think
appropriate.
I've seen that we have an exception with the news2mail gatewaying program, which uses additional flags:
<mta without %s> -ee -odq -fxxx -pNNTP:pathhost addresses
I don't know what "-ee" means. Does someone know? Is it still a useful flag?
-odq queues mails. It means that "sendmail -q" should be periodically run to actually send the mails. I wonder whether that's really useful. Maybe a flag should be added to news2mail to configure that behaviour (for backwards compatibility: if -q is given to news2mail, then it does not queue messages).
-fxxx defaults to the newsmaster address or a specific envelope address configured in
news2mail.cf for the list.
I suggest to strip an existing -f flag in mta if one is configured in
news2mail.cf so as not to conflict with it.
I am unsure -pNNTP:pathhost is really necessary... Any thoughts?
--
Julien ÉLIE
« J'ai six loyaux serviteurs, ils m'ont appris tout ce que je sais : ils
s'appellent quoi, pourquoi, quand, comment, où et qui. » (Rudyard
Kipling)