it sets its userid to that of the target user while delivering mail
through an MDA. Some possible MDAs are "/usr/sbin/sendmail -oem -f %F
%T", "/usr/bin/deliver" and "/usr/bin/procmail -d %T" (but the latter
-is usually redundant as). it's what SMTP listeners usually forward
+is usually redundant as it's what SMTP listeners usually forward
to). Local delivery addresses will be inserted into the MDA command
wherever you place a %T; the mail message's From address will be
inserted where you place an %F. Do \fInot\fR use an MDA invocation
This option does not work with ETRN.
.TP
.B -e, --expunge
-(keyword: expunge)
-When talking to an IMAP server,
+(keyword: expunge)
+Arrange for deletions to be made final after a given number of
+messages. Under POP2 or POP3, fetchmail cannot make deletions final
+without sending QUIT and ending the session -- with this option on,
+fetchmail will break a long mail retrieval session into multiple
+subsessions, sending QUIT after each sub-session. This is a good
+defense against line drops on POP3 servers that do not do the
+equivalent of a QUIT on hangup. Under IMAP,
.I fetchmail
normally issues an EXPUNGE command after each deletion in order to
force the deletion to be done immediately. This is safest when your
expunges less frequently. If you specify this option to an integer N,
it tells
.I fetchmail
-to only issue expunges on every Nth delete. An argument
-of zero suppresses expunges entirely (so no expunges at all will be
-done until the end of run).
-This option does not work with ETRN, POP2, or POP3.
+to only issue expunges on every Nth delete. An argument of zero
+suppresses expunges entirely (so no expunges at all will be done until
+the end of run). This option does not work with ETRN.
.SS Authentication Options
.TP
.B \-u name, --username name
The field after the second slash is a mask which specifies a range of
IP addresses to accept. If no mask is present 255.255.255.255 is
assumed (i.e. an exact match). This option is currently only supported
-under Linux.
+under Linux and FreeBSD. Please see the
+.B monitor
+section for below for FreeBSD specific information.
.TP
.B \-M interface, --monitor interface
(Keyword: monitor)
indefinitely. This option identifies a system TCP/IP interface to be
monitored for activity. After each poll interval, if the link is up but
no other activity has occurred on the link, then the poll will be
-skipped. This option is currently only supported under Linux.
+skipped. This option is currently only supported under Linux and FreeBSD.
+For the
+.B monitor
+and
+.B interface
+options to work for non root users under FreeBSD, the fetchmail binary
+must be installed SGID kmem. This would be a security hole, but
+fetchmail runs with the effective GID set to that of the kmem group
+.I only
+when interface data is being collected.
.TP
.B \-A, --auth
(Keyword: auth[enticate])
If the invoking user is root, then the default of this option is
the user `postmaster'.
.PP
+The
+.B --nobounce
+option suppresses the normal action of bouncing errors back to the
+sender in an RFC1894-conformant error message. If nobounce is on, the
+message will go to the postmaster instead.
+.PP
The
.B --invisible
option (keyword: set invisible) tries to make fetchmail invisible.
.I fetchmail
code recognizes and discards the message on any of a list of responses
that defaults to [571, 550, 501] but can be set with the `antispam'
-option. This is the
+option. This is one of the
.I only
-circumstance under which fetchmail ever discards mail.
+two circumstance under which fetchmail ever discards mail (the others
+are the 552 and 553 errors described below).
.PP
If
.I fetchmail
set postmaster \& T{
Give the name of the last-resort mail recipient
T}
+set no bouncemail \& T{
+Direct error mail to postmaster rather than sender
+T}
set logfile \& T{
Name of a file to dump error and status messages to
T}
set nosyslog \& T{
Turn off error logging through syslog(3).
T}
+set properties \& T{
+String value is ignored by fetchmail (may be used by extension scripts)
+T}
.TE
Here are the legal server options:
Strip Status and X-Mozilla-Status lines out of incoming mail
T}
mimedecode \& T{
-Convert quoted-printable to 8-bit in MIME messages
+Convert quoted-printable to 8-bit in MIME messages (default)
T}
no keep -K T{
Delete seen messages from server (default)
Don't drop Status headers (default)
T}
no mimedecode \& T{
-Don't convert quoted-printable to 8-bit in MIME messages (default)
+Don't convert quoted-printable to 8-bit in MIME messages
T}
limit -l T{
Set message size limit
Set message size warning interval
T}
batchlimit -b T{
-Max # messages to fetch in single connect
+Max # messages to forward in single connect
T}
fetchlimit -B T{
-Max # messages to forward in single connect
+Max # messages to fetch in single connect
T}
expunge -e T{
Perform an expunge on every #th message (IMAP only)
matching addresses are handled.
.PP
If \fIfetchmail\fR cannot match any mailserver usernames or
-localdomain addresses, the default recipient is the value of the
-`postmaster' global option if that has been set; otherwise it's the
-calling user (as set by the USER or LOGNAME variable in the
-environment).
+localdomain addresses, the mail will be bounced.
+Normally it will be bounced to the sender, but if `nobounce' is on
+it will go to the postmaster (which in turn defaults to being the
+calling user).
.PP
The `dns' option (normally on) controls the way addresses from
multidrop mailboxes are checked. On, it enables logic to check each
inserted by some buggy POP servers are unconditionally discarded.)
.PP
The `mimedecode' option controls whether MIME messages using the
-quoted-printable encoding are automatically converted into pure
-8-bit data. If you are delivering mail to an ESMTP-capable,
-8-bit-clean listener (that includes all of the major programs
-like sendmail), then this will automatically convert quoted-printable
-message headers and data into 8-bit data, making it easier to
-understand when reading mail. If your e-mail programs know how to
-deal with MIME messages, then this option is not needed.
+quoted-printable encoding are automatically converted into pure 8-bit
+data. If you are delivering mail to an ESMTP-capable, 8-bit-clean
+listener (that includes all of the major MTAs like sendmail), then
+this will automatically convert quoted-printable message headers and
+data into 8-bit data, making it easier to understand when reading
+mail. If your e-mail programs know how to deal with MIME messages,
+then this option is not needed (but does no harm). The mimedecode
+option is on by default.
.PP
The `properties' option is an extension mechanism. It takes a string
argument, which is ignored by fetchmail itself. The string argument may be
a DNS lookup at startup and could not proceed.
.IP 12
BSMTP batch file could not be opened.
+.IP 13
+Poll terminated by a fetch limit (see the --fetchlimit option).
.IP 23
Internal error. You should see a message on standard error with
details.
that of the last host queried.
.SH AUTHOR
-Eric S. Raymond <esr@snark.thyrsus.com>.
+Eric S. Raymond <esr@snark.thyrsus.com>. Too many other people to
+name here have contributed code and patches.
This program is descended from and replaces
.IR popclient ,
by Carl Harris <ceharris@mal.com>; the internals have become quite different,
lock file to help prevent concurrent runs (root mode, systems without /var/run).
.SH ENVIRONMENT
-For correct initialization,
-.I fetchmail
-requires either that both the USER and HOME environment variables are
-correctly set, or that \fBgetpwuid\fR(3) be able to retrieve a password
-entry from your user ID.
+If either the LOGNAME or USER and the variable is correctly set
+(e.g. the corresponding UID matches the session user ID) then that
+name is used as the default local name. Otherwise \fBgetpwuid\fR(3)
+mudst be able to retrieve a password entry for the session ID (this
+elaborate logic is designed to handle the case of multiple names per
+userid gracefully).
.SH SIGNALS
If a
headers into a single one (procmail, mailagent, or maildrop can be
orogrammed to do this fairly easily).
.PP
-Use of any of the supported protocols other than POP3 with OTP or RPA, APOP,
-KPOP, IMAP-K4, IMAP-GSS, or ETRN requires that the program send unencrypted
-passwords over the TCP/IP connection to the mailserver. This creates
-a risk that name/password pairs might be snaffled with a packet
-sniffer or more sophisticated monitoring software. Under Linux, the
---interface option can be used to restrict polling to availability of
-a specific interface device with a specific local IP address, but
-snooping is still possible if (a) either host has a network device
-that can be opened in promiscuous mode, or (b) the intervening network
-link can be tapped.
+Use of any of the supported protocols other than POP3 with OTP or RPA,
+APOP, KPOP, IMAP-K4, IMAP-GSS, or ETRN requires that the program send
+unencrypted passwords over the TCP/IP connection to the mailserver.
+This creates a risk that name/password pairs might be snaffled with a
+packet sniffer or more sophisticated monitoring software. Under Linux
+and FreeBSD, the --interface option can be used to restrict polling to
+availability of a specific interface device with a specific local IP
+address, but snooping is still possible if (a) either host has a
+network device that can be opened in promiscuous mode, or (b) the
+intervening network link can be tapped.
.PP
Use of the %F or %T escapes in an mda option could open a security
hole, because they pass text manipulable by an attacker to a shell
RFC 937
.TP 5
POP3:
-RFC 1081, RFC 1225, RFC 1460, RFC 1725, RFC 1939
+RFC 1081, RFC 1225, RFC 1460, RFC 1725, RFC 1939, RFC 2449
.TP 5
APOP:
RFC 1460, RFC 1725, RFC 1939
RFC 1176, RFC 1732
.TP 5
IMAP4:
-RFC 1730, RFC 1731, RFC 1732, RFC 2060, RFC 2061
+RFC 1730, RFC 1731, RFC 1732, RFC 2060, RFC 2061, RFC 2195
.TP 5
ETRN:
RFC 1985