mirror of
https://github.com/vdukhovni/postfix
synced 2025-08-30 05:38:06 +00:00
postfix-2.3-20050328
This commit is contained in:
parent
da30144878
commit
c1e35cbf92
@ -1,46 +1,31 @@
|
||||
Postfix enhanced status code implementation notes
|
||||
=================================================
|
||||
|
||||
Enhanced status code support is implemented in stages. In the first
|
||||
stage, the goal is to minimize code changes (it's several hundred
|
||||
pages of context diffs already). For this reason, the pre-existing
|
||||
status variables (success, defer, etc.) are not updated atomically
|
||||
with the enhanced status code; instead, enhanced status codes are
|
||||
updated separately. This means one has to be careful when making
|
||||
updates to the code, so that things won't go out of sync.
|
||||
RFC 3463 Enhanced status code support is implemented in stages. In
|
||||
the first stage, the goal is to minimize code changes (it's several
|
||||
hundred pages of context diffs already). For this reason, the
|
||||
pre-existing status variables (success, defer, etc.) are still
|
||||
updated separately from the diagnostic text and the RFC 3463 enhanced
|
||||
status code. All this means that one has to be careful when updating
|
||||
the code, to keep things in sync.
|
||||
|
||||
Specific issues that one should be aware of:
|
||||
|
||||
- In the SMTP client, either update the enhanced status code and
|
||||
text whenever smtp_errno or resp->code are updated, or place an
|
||||
explicit comment that no update is needed.
|
||||
- In the SMTP client, update the enhanced status code and text
|
||||
whenever smtp_errno or resp->code are updated, or place an explicit
|
||||
comment that says no update is needed.
|
||||
|
||||
- In the SMTP client, don't worry about the first enhanced status
|
||||
- In the SMTP client, don't worry about the initial enhanced status
|
||||
digit when reporting failure to look up or connect to a host. For
|
||||
convenience, the SMTP client top-level code automatically changes
|
||||
it into '4' or '5' as appropriate.
|
||||
the initial digit into '4' or '5' as appropriate.
|
||||
|
||||
- The above two points also apply to the LMTP client; this delivery
|
||||
agent is on life support until its functionality is merged with the
|
||||
SMTP client.
|
||||
- The above two points also apply to the LMTP client.
|
||||
|
||||
- In the SMTP server, don't worry about the first enhanced status
|
||||
digit when a restriction rejects access. For convenience, the
|
||||
smtpd_check_reject() routine automatically changes it into '4' or
|
||||
'5' as appropriate.
|
||||
|
||||
- The pipe, local and virtual delivery agents never update the
|
||||
diagnostic text without also updating the enhanced status code. The
|
||||
main chore here is to choose appropriate enhanced status codes.
|
||||
|
||||
- Don't rely on the system errno value after calling a routine that
|
||||
updates the enhanced status code upon failure. Use the enhanced
|
||||
status code (and diagnostic text) instead. Currently there are two
|
||||
exceptions to this rule: mail_copy() for historical reasons may or
|
||||
may not return explicit error reports (fixing this requires that
|
||||
pipe_command() be restructured); and the maildir delivery routines
|
||||
log a helpful warning when delivery fails with EACCES. This just
|
||||
happens to work because maildir needs no file locking.
|
||||
- In the SMTP server, don't worry about the initial enhanced status
|
||||
code digit when an smtpd_mumble_restriction rejects access. For
|
||||
convenience, the smtpd_check_reject() routine automatically changes
|
||||
the initial digit into '4' or '5' as appropriate.
|
||||
|
||||
- Some low-level support routines update the diagnostic text but
|
||||
not the enhanced status code. To identify these, search for functions
|
||||
@ -48,14 +33,29 @@ that are called with why->vstring as output parameter, and make
|
||||
sure that the caller updates the enhanced status code in all
|
||||
appropriate cases.
|
||||
|
||||
- By design, the pipe, local and virtual delivery agent code never
|
||||
update the diagnostic text separately from the enhanced status code.
|
||||
|
||||
- Don't rely on the system errno value after calling a routine that
|
||||
performs or prepares for mail delivery. Instead, have that routine
|
||||
update the enhanced status code (and text) when the error happens.
|
||||
This was an issue with mailbox, maildir and file delivery. Currently
|
||||
there remain two exceptions to this rule: mail_copy() for historical
|
||||
reasons may or may not return explicit error reports (fixing this
|
||||
requires that pipe_command() be restructured); and the maildir
|
||||
delivery routines log a helpful warning when delivery fails with
|
||||
EACCES. The latter happens to work because mbox_open() does not
|
||||
need to unlock the output file, so it won't clobber the errno value.
|
||||
|
||||
- Avoid passing around strings that combine enhanced status code
|
||||
and diagnostic text, because the compiler can't help to enforce
|
||||
consistency. Currently there are two exceptions to this rule: the
|
||||
cleanup server status reply, and the delivery agent status reply.
|
||||
Once these protocols are updated we can remove the dns_prepend()
|
||||
routine.
|
||||
that everything has a status code. Currently there are two exceptions
|
||||
to this rule: the cleanup server status reply, and the delivery
|
||||
agent status reply. Once these protocols are updated we can remove
|
||||
the dns_prepend() routine. The third exception, enhanced status
|
||||
codes in external command output, is a feature.
|
||||
|
||||
- The bounce/defer/sent modules will catch the cases where an
|
||||
enhanced status code does not match the reject/defer/success status.
|
||||
These discrepancies are logged as a warning, and the enhanced status
|
||||
code is replaced by a generic one.
|
||||
- The bounce/defer/sent library modules will catch the cases where
|
||||
an enhanced status code does not match the reject/defer/success
|
||||
status. They log a warning message, and replace the incorrect
|
||||
enhanced status code by a generic one.
|
||||
|
@ -10487,7 +10487,7 @@ Apologies for any names omitted.
|
||||
|
||||
20050321-27
|
||||
|
||||
Support for RFC 1893 enhanced status codes. See also the
|
||||
Support for RFC 3463 enhanced status codes. See also the
|
||||
ENHANCED_STATUS_README file for background.
|
||||
|
||||
New module to pass around (status code + text) instead of
|
||||
@ -10497,13 +10497,14 @@ Apologies for any names omitted.
|
||||
enhanced status codes. Files: global/sys_exits.c,
|
||||
global/cleanup_strerror.c.
|
||||
|
||||
Incompatible change: centralized mapping of errno values
|
||||
to delivery status codes after failed delivery to mailbox,
|
||||
maildir, or file. Error codes EACCES, EAGAIN, ESTALE are
|
||||
4.2.0 temporary errors, ENOSPC is a 4.3.0 temporary error,
|
||||
EDQUOT and EFBIG are 5.2.2 hard errors, and everything else
|
||||
is a 5.2.0 hard error. This means that local(8) will bounce
|
||||
less mail, while virtual(8) will defer less mail. File:
|
||||
Cleanup: centralized mapping of errno values to delivery
|
||||
status codes after failed delivery to mailbox, maildir, or
|
||||
file. Error codes EAGAIN, and ESTALE are 4.2.0 temporary
|
||||
errors; ENOSPC is a 4.3.0 temporary error; and EDQUOT and
|
||||
EFBIG are 5.2.2 hard errors. For backwards compatibility,
|
||||
the result of other errors depends on the delivery agent:
|
||||
with local(8) everything else is a 5.2.0 hard error, and
|
||||
with virtual(8) everything else is soft 4.2.0 error. File:
|
||||
global/mbox_open.c.
|
||||
|
||||
20050324
|
||||
@ -10534,13 +10535,19 @@ Apologies for any names omitted.
|
||||
|
||||
20050327
|
||||
|
||||
Bugfix: the SMTP client did not ask the queue manager to
|
||||
reduce destination concurrency after a "lost connection"
|
||||
or "connection timed out" errror. File: smtp/smtp_trouble.c.
|
||||
Bugfix: the SMTP and LMTP clients did not ask the queue
|
||||
manager to reduce destination concurrency when "lost
|
||||
connection" or "connection timed out" happened AFTER Postfix
|
||||
received the server greeting. Files: smtp/smtp_trouble.c,
|
||||
lmtp/lmtp-trouble.c.
|
||||
|
||||
Workaround: FreeBSD has incompatibly changed the output
|
||||
format from "od", breaking regression test portability.
|
||||
|
||||
The TLS client session cache ID is now derived from the
|
||||
server IP address, TCP Port, and server HELO hostname
|
||||
if available. File: smtp/smtp_proto.c.
|
||||
|
||||
Open problems:
|
||||
|
||||
Med: disable header address rewriting after XCLIENT?
|
||||
|
@ -11,38 +11,48 @@ instead, a new snapshot is released.
|
||||
The mail_release_date configuration parameter (format: yyyymmdd)
|
||||
specifies the release date of a stable release or snapshot release.
|
||||
|
||||
See RELEASE_NOTES-2.2 for changes introduced during the development
|
||||
of Postfix version 2.2.
|
||||
Incompatibility with Postfix 2.1 and earlier
|
||||
============================================
|
||||
|
||||
Incompatible changes with snapshot 20050327
|
||||
===========================================
|
||||
If you upgrade from Postfix 2.1 or earlier, read RELEASE_NOTES-2.2
|
||||
before proceeding.
|
||||
|
||||
local(8) and virtual(8) now handle the same errors in the same way.
|
||||
This means that local(8) will defer some mail that it older versions
|
||||
would bounce, and that virtual(8) will bounce some mail that older
|
||||
versions would defer.
|
||||
Incompatibility with snapshot 20050328
|
||||
======================================
|
||||
|
||||
Specifically, error codes EACCES, EAGAIN, ESTALE are soft (4.2.0)
|
||||
errors, ENOSPC is a soft (4.3.0) error, EDQUOT and EFBIG are hard
|
||||
(5.2.2) errors, and everything else is a hard (5.2.0) error.
|
||||
After you upgrade from Postfix 2.2 or 2.3 you need to execute
|
||||
"postfix reload", otherwise you will keep running the old Postfix
|
||||
queue manager, which gives no special treatment to the enhanced
|
||||
status codes that it receives from Postfix delivery agents.
|
||||
|
||||
Major changes with snapshot 20050327
|
||||
Major changes with snapshot 20050328
|
||||
====================================
|
||||
|
||||
This release introduces support for RFC 1893 enhanced status codes.
|
||||
For example, status code "5.1.1" means "recipient unknown". Postfix
|
||||
recognizes enhanced status codes in remote server replies, and
|
||||
generates enhanced status codes when it responds to mail delivery
|
||||
requests. This improves the communication with mail clients that
|
||||
hide error messages from users.
|
||||
This release introduces support for RFC 3463 enhanced status codes.
|
||||
For example, status code 5.1.1 means "recipient unknown". Postfix
|
||||
recognizes enhanced status codes in remote server replies, generates
|
||||
enhanced status codes while handling email, and reports enhanced
|
||||
status codes in non-delivery notifications. This improves the user
|
||||
interaction with mail clients that hide the text of error messages
|
||||
from users.
|
||||
|
||||
You can, but don't have to, specify RFC 1893 enhanced status codes
|
||||
in Postfix access maps or header/body_checks. Example:
|
||||
You can, but don't have to, specify RFC 3463 enhanced status codes
|
||||
in the output from commands that receive mail from a pipe. If a
|
||||
command terminates with non-zero exit status, and an enhanced status
|
||||
code is present at the beginning of the command output, then that
|
||||
status code takes precedence over the non-zero exit status.
|
||||
|
||||
You can, but don't have to, specify RFC 3463 enhanced status codes
|
||||
in Postfix access maps, header/body_checks REJECT actions, or in
|
||||
RBL replies. For example:
|
||||
|
||||
REJECT 5.7.1 You can't go here from there
|
||||
|
||||
(5.7.1 means "no authorization, message refused"). Enhanced status
|
||||
code support is also available in RBL reply templates.
|
||||
The status 5.7.1 means "no authorization, message refused", and is
|
||||
the default for access maps, header/body_checks REJECT actions, and
|
||||
for RBL replies.
|
||||
|
||||
If you do specify an enhanced status code, Postfix will automatically
|
||||
change the first digit into a '4' or '5' as appropriate.
|
||||
If you specify your own enhanced status code, the Postfix SMTP
|
||||
server will automatically change a leading '5' digit (hard error)
|
||||
into '4' where appropriate. This is needed, for example, with
|
||||
soft_bounce=yes.
|
||||
|
@ -18,7 +18,7 @@ DISCARD(8) DISCARD(8)
|
||||
queue file, a sender address, a domain or host name that
|
||||
is treated as the reason for discarding the mail, and
|
||||
recipient information. The reason may be prefixed with an
|
||||
<a href="http://www.faqs.org/rfcs/rfc1893.html">RFC 1893</a>-compatible detail code. This program expects to
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a>-compatible detail code. This program expects to
|
||||
be run from the <a href="master.8.html"><b>master</b>(8)</a> process manager.
|
||||
|
||||
The <a href="discard.8.html"><b>discard</b>(8)</a> delivery agent pretends to deliver all
|
||||
|
@ -18,7 +18,7 @@ ERROR(8) ERROR(8)
|
||||
queue file, a sender address, a domain or host name that
|
||||
is treated as the reason for non-delivery, and recipient
|
||||
information. The reason may be prefixed with an RFC
|
||||
1893-compatible detail code. This program expects to be
|
||||
3463-compatible detail code. This program expects to be
|
||||
run from the <a href="master.8.html"><b>master</b>(8)</a> process manager.
|
||||
|
||||
The <a href="error.8.html"><b>error</b>(8)</a> delivery agent bounces all recipients in the
|
||||
|
@ -63,10 +63,11 @@ LMTP(8) LMTP(8)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1652.html">RFC 1652</a> (8bit-MIME transport)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1870.html">RFC 1870</a> (Message Size Declaration)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2033.html">RFC 2033</a> (LMTP protocol)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Error Codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Status codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2554.html">RFC 2554</a> (AUTH command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2821.html">RFC 2821</a> (SMTP protocol)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2920.html">RFC 2920</a> (SMTP Pipelining)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> (Enhanced Status codes)
|
||||
|
||||
<b>DIAGNOSTICS</b>
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
|
@ -172,10 +172,17 @@ LOCAL(8) LOCAL(8)
|
||||
ery status reports. A command is forcibly terminated if
|
||||
it does not complete within <b><a href="postconf.5.html#command_time_limit">command_time_limit</a></b> seconds.
|
||||
Command exit status codes are expected to follow the con-
|
||||
ventions defined in <<b>sysexits.h</b>>.
|
||||
ventions defined in <<b>sysexits.h</b>>. Exit status 0 means
|
||||
normal successful completion.
|
||||
|
||||
A limited amount of message context is exported via envi-
|
||||
ronment variables. Characters that may have special mean-
|
||||
Postfix version 2.3 and later support <a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a>-style
|
||||
enhanced status codes. If a command terminates with a
|
||||
non-zero exit status, and the command output begins with
|
||||
an enhanced status code, this status code takes precedence
|
||||
over the non-zero exit status.
|
||||
|
||||
A limited amount of message context is exported via envi-
|
||||
ronment variables. Characters that may have special mean-
|
||||
ing to the shell are replaced by underscores. The list of
|
||||
acceptable characters is specified with the <b><a href="postconf.5.html#command_expansion_filter">command_expan</a>-</b>
|
||||
<b><a href="postconf.5.html#command_expansion_filter">sion_filter</a></b> configuration parameter.
|
||||
@ -206,97 +213,97 @@ LOCAL(8) LOCAL(8)
|
||||
the following environment variables:
|
||||
|
||||
<b>CLIENT_ADDRESS</b>
|
||||
Remote client network address. Available as of
|
||||
Remote client network address. Available as of
|
||||
Postfix 2.2.
|
||||
|
||||
<b>CLIENT_HELO</b>
|
||||
Remote client EHLO command parameter. Available as
|
||||
Remote client EHLO command parameter. Available as
|
||||
of Postfix 2.2.
|
||||
|
||||
<b>CLIENT_HOSTNAME</b>
|
||||
Remote client hostname. Available as of Postfix
|
||||
Remote client hostname. Available as of Postfix
|
||||
2.2.
|
||||
|
||||
<b>CLIENT_PROTOCOL</b>
|
||||
Remote client protocol. Available as of Postfix
|
||||
Remote client protocol. Available as of Postfix
|
||||
2.2.
|
||||
|
||||
<b>SASL_METHOD</b>
|
||||
SASL authentication method specified in the remote
|
||||
SASL authentication method specified in the remote
|
||||
client AUTH command. Available as of Postfix 2.2.
|
||||
|
||||
<b>SASL_SENDER</b>
|
||||
SASL sender address specified in the remote client
|
||||
SASL sender address specified in the remote client
|
||||
MAIL FROM command. Available as of Postfix 2.2.
|
||||
|
||||
<b>SASL_USERNAME</b>
|
||||
SASL username specified in the remote client AUTH
|
||||
SASL username specified in the remote client AUTH
|
||||
command. Available as of Postfix 2.2.
|
||||
|
||||
The <b>PATH</b> environment variable is always reset to a system-
|
||||
dependent default path, and environment variables whose
|
||||
names are blessed by the <b><a href="postconf.5.html#export_environment">export_environment</a></b> configuration
|
||||
dependent default path, and environment variables whose
|
||||
names are blessed by the <b><a href="postconf.5.html#export_environment">export_environment</a></b> configuration
|
||||
parameter are exported unchanged.
|
||||
|
||||
The current working directory is the mail queue directory.
|
||||
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> daemon prepends a "<b>From</b> <i>sender time</i><b>_</b><i>stamp</i>"
|
||||
envelope header to each message, prepends an <b>X-Original-</b>
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> daemon prepends a "<b>From</b> <i>sender time</i><b>_</b><i>stamp</i>"
|
||||
envelope header to each message, prepends an <b>X-Original-</b>
|
||||
<b>To:</b> header with the recipient address as given to Postfix,
|
||||
prepends an optional <b>Delivered-To:</b> header with the final
|
||||
prepends an optional <b>Delivered-To:</b> header with the final
|
||||
recipient envelope address, prepends a <b>Return-Path:</b> header
|
||||
with the sender envelope address, and appends no empty
|
||||
with the sender envelope address, and appends no empty
|
||||
line.
|
||||
|
||||
<b>EXTERNAL FILE DELIVERY</b>
|
||||
The delivery format depends on the destination filename
|
||||
syntax. The default is to use UNIX-style mailbox format.
|
||||
Specify a name ending in <b>/</b> for <b>qmail</b>-compatible <b>maildir</b>
|
||||
The delivery format depends on the destination filename
|
||||
syntax. The default is to use UNIX-style mailbox format.
|
||||
Specify a name ending in <b>/</b> for <b>qmail</b>-compatible <b>maildir</b>
|
||||
delivery.
|
||||
|
||||
The <b><a href="postconf.5.html#allow_mail_to_files">allow_mail_to_files</a></b> configuration parameter restricts
|
||||
delivery to external files. The default setting (<b>alias,</b>
|
||||
The <b><a href="postconf.5.html#allow_mail_to_files">allow_mail_to_files</a></b> configuration parameter restricts
|
||||
delivery to external files. The default setting (<b>alias,</b>
|
||||
<b>forward</b>) forbids file destinations in <b>:include:</b> files.
|
||||
|
||||
In the case of UNIX-style mailbox delivery, the <a href="local.8.html"><b>local</b>(8)</a>
|
||||
In the case of UNIX-style mailbox delivery, the <a href="local.8.html"><b>local</b>(8)</a>
|
||||
daemon prepends a "<b>From</b> <i>sender time</i><b>_</b><i>stamp</i>" envelope header
|
||||
to each message, prepends an <b>X-Original-To:</b> header with
|
||||
the recipient address as given to Postfix, prepends an
|
||||
optional <b>Delivered-To:</b> header with the final recipient
|
||||
envelope address, prepends a > character to lines begin-
|
||||
ning with "<b>From</b> ", and appends an empty line. The enve-
|
||||
lope sender address is available in the <b>Return-Path:</b>
|
||||
header. When the destination is a regular file, it is
|
||||
to each message, prepends an <b>X-Original-To:</b> header with
|
||||
the recipient address as given to Postfix, prepends an
|
||||
optional <b>Delivered-To:</b> header with the final recipient
|
||||
envelope address, prepends a > character to lines begin-
|
||||
ning with "<b>From</b> ", and appends an empty line. The enve-
|
||||
lope sender address is available in the <b>Return-Path:</b>
|
||||
header. When the destination is a regular file, it is
|
||||
locked for exclusive access while delivery is in progress.
|
||||
In case of problems, an attempt is made to truncate a reg-
|
||||
ular file to its original length.
|
||||
|
||||
In the case of <b>maildir</b> delivery, the local daemon prepends
|
||||
an optional <b>Delivered-To:</b> header with the final envelope
|
||||
recipient address, and prepends an <b>X-Original-To:</b> header
|
||||
an optional <b>Delivered-To:</b> header with the final envelope
|
||||
recipient address, and prepends an <b>X-Original-To:</b> header
|
||||
with the recipient address as given to Postfix. The enve-
|
||||
lope sender address is available in the <b>Return-Path:</b>
|
||||
lope sender address is available in the <b>Return-Path:</b>
|
||||
header.
|
||||
|
||||
<b>ADDRESS EXTENSION</b>
|
||||
The optional <b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a></b> configuration parameter
|
||||
specifies how to separate address extensions from local
|
||||
The optional <b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a></b> configuration parameter
|
||||
specifies how to separate address extensions from local
|
||||
recipient names.
|
||||
|
||||
For example, with "<b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> = +</b>", mail for
|
||||
<i>name</i>+<i>foo</i> is delivered to the alias <i>name</i>+<i>foo</i> or to the
|
||||
alias <i>name</i>, to the destinations listed in ~<i>name</i>/.<b>for-</b>
|
||||
For example, with "<b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> = +</b>", mail for
|
||||
<i>name</i>+<i>foo</i> is delivered to the alias <i>name</i>+<i>foo</i> or to the
|
||||
alias <i>name</i>, to the destinations listed in ~<i>name</i>/.<b>for-</b>
|
||||
<b>ward</b>+<i>foo</i> or in ~<i>name</i>/.<b>forward</b>, to the mailbox owned by the
|
||||
user <i>name</i>, or it is sent back as undeliverable.
|
||||
|
||||
In all cases the <a href="local.8.html"><b>local</b>(8)</a> daemon prepends an optional
|
||||
`<b>Delivered-To:</b> header line with the final recipient
|
||||
In all cases the <a href="local.8.html"><b>local</b>(8)</a> daemon prepends an optional
|
||||
`<b>Delivered-To:</b> header line with the final recipient
|
||||
address.
|
||||
|
||||
<b>DELIVERY RIGHTS</b>
|
||||
Deliveries to external files and external commands are
|
||||
Deliveries to external files and external commands are
|
||||
made with the rights of the receiving user on whose behalf
|
||||
the delivery is made. In the absence of a user context,
|
||||
the delivery is made. In the absence of a user context,
|
||||
the <a href="local.8.html"><b>local</b>(8)</a> daemon uses the owner rights of the <b>:include:</b>
|
||||
file or alias database. When those files are owned by the
|
||||
superuser, delivery is made with the rights specified with
|
||||
@ -304,50 +311,51 @@ LOCAL(8) LOCAL(8)
|
||||
|
||||
<b>STANDARDS</b>
|
||||
<a href="http://www.faqs.org/rfcs/rfc822.html">RFC 822</a> (ARPA Internet Text Messages)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> (Enhanced status codes)
|
||||
|
||||
<b>DIAGNOSTICS</b>
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
rupted message files are marked so that the queue manager
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
rupted message files are marked so that the queue manager
|
||||
can move them to the <b>corrupt</b> queue afterwards.
|
||||
|
||||
Depending on the setting of the <b><a href="postconf.5.html#notify_classes">notify_classes</a></b> parameter,
|
||||
the postmaster is notified of bounces and of other trou-
|
||||
Depending on the setting of the <b><a href="postconf.5.html#notify_classes">notify_classes</a></b> parameter,
|
||||
the postmaster is notified of bounces and of other trou-
|
||||
ble.
|
||||
|
||||
<b>SECURITY</b>
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent needs a dual personality 1) to
|
||||
access the private Postfix queue and IPC mechanisms, 2) to
|
||||
impersonate the recipient and deliver to recipient-speci-
|
||||
fied files or commands. It is therefore security sensi-
|
||||
impersonate the recipient and deliver to recipient-speci-
|
||||
fied files or commands. It is therefore security sensi-
|
||||
tive.
|
||||
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent disallows regular expression
|
||||
substitution of $1 etc. in <b><a href="postconf.5.html#alias_maps">alias_maps</a></b>, because that would
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent disallows regular expression
|
||||
substitution of $1 etc. in <b><a href="postconf.5.html#alias_maps">alias_maps</a></b>, because that would
|
||||
open a security hole.
|
||||
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent will silently ignore requests
|
||||
to use the <a href="proxymap.8.html"><b>proxymap</b>(8)</a> server within <b><a href="postconf.5.html#alias_maps">alias_maps</a></b>. Instead
|
||||
it will open the table directly. Before Postfix version
|
||||
2.2, the <a href="local.8.html"><b>local</b>(8)</a> delivery agent will terminate with a
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent will silently ignore requests
|
||||
to use the <a href="proxymap.8.html"><b>proxymap</b>(8)</a> server within <b><a href="postconf.5.html#alias_maps">alias_maps</a></b>. Instead
|
||||
it will open the table directly. Before Postfix version
|
||||
2.2, the <a href="local.8.html"><b>local</b>(8)</a> delivery agent will terminate with a
|
||||
fatal error.
|
||||
|
||||
<b>BUGS</b>
|
||||
For security reasons, the message delivery status of
|
||||
external commands or of external files is never check-
|
||||
For security reasons, the message delivery status of
|
||||
external commands or of external files is never check-
|
||||
pointed to file. As a result, the program may occasionally
|
||||
deliver more than once to a command or external file. Bet-
|
||||
ter safe than sorry.
|
||||
|
||||
Mutually-recursive aliases or ~/.<b>forward</b> files are not
|
||||
detected early. The resulting mail forwarding loop is
|
||||
Mutually-recursive aliases or ~/.<b>forward</b> files are not
|
||||
detected early. The resulting mail forwarding loop is
|
||||
broken by the use of the <b>Delivered-To:</b> message header.
|
||||
|
||||
<b>CONFIGURATION PARAMETERS</b>
|
||||
Changes to <b>main.cf</b> are picked up automatically, as
|
||||
<a href="local.8.html"><b>local</b>(8)</a> processes run for only a limited amount of time.
|
||||
Changes to <b>main.cf</b> are picked up automatically, as
|
||||
<a href="local.8.html"><b>local</b>(8)</a> processes run for only a limited amount of time.
|
||||
Use the command "<b>postfix reload</b>" to speed up a change.
|
||||
|
||||
The text below provides only a parameter summary. See
|
||||
The text below provides only a parameter summary. See
|
||||
<a href="postconf.5.html"><b>postconf</b>(5)</a> for more details including examples.
|
||||
|
||||
<b>COMPATIBILITY CONTROLS</b>
|
||||
@ -357,59 +365,59 @@ LOCAL(8) LOCAL(8)
|
||||
<b><a href="postconf.5.html#expand_owner_alias">expand_owner_alias</a> (no)</b>
|
||||
When delivering to an alias "aliasname" that has an
|
||||
"owner-aliasname" companion alias, set the envelope
|
||||
sender address to the expansion of the "owner-
|
||||
sender address to the expansion of the "owner-
|
||||
aliasname" alias.
|
||||
|
||||
<b><a href="postconf.5.html#owner_request_special">owner_request_special</a> (yes)</b>
|
||||
Give special treatment to owner-listname and list-
|
||||
name-request address localparts: don't split such
|
||||
addresses when the <a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> is set to
|
||||
Give special treatment to owner-listname and list-
|
||||
name-request address localparts: don't split such
|
||||
addresses when the <a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> is set to
|
||||
"-".
|
||||
|
||||
<b><a href="postconf.5.html#sun_mailtool_compatibility">sun_mailtool_compatibility</a> (no)</b>
|
||||
Obsolete SUN mailtool compatibility feature.
|
||||
|
||||
<b>DELIVERY METHOD CONTROLS</b>
|
||||
The precedence of <a href="local.8.html"><b>local</b>(8)</a> delivery methods from high to
|
||||
low is: aliases, .forward files, <a href="postconf.5.html#mailbox_transport">mailbox_transport</a>, <a href="postconf.5.html#mailbox_command_maps">mail</a>-
|
||||
The precedence of <a href="local.8.html"><b>local</b>(8)</a> delivery methods from high to
|
||||
low is: aliases, .forward files, <a href="postconf.5.html#mailbox_transport">mailbox_transport</a>, <a href="postconf.5.html#mailbox_command_maps">mail</a>-
|
||||
<a href="postconf.5.html#mailbox_command_maps">box_command_maps</a>, <a href="postconf.5.html#mailbox_command">mailbox_command</a>, <a href="postconf.5.html#home_mailbox">home_mailbox</a>,
|
||||
<a href="postconf.5.html#mail_spool_directory">mail_spool_directory</a>, <a href="postconf.5.html#fallback_transport">fallback_transport</a> and <a href="postconf.5.html#luser_relay">luser_relay</a>.
|
||||
<a href="postconf.5.html#mail_spool_directory">mail_spool_directory</a>, <a href="postconf.5.html#fallback_transport">fallback_transport</a> and <a href="postconf.5.html#luser_relay">luser_relay</a>.
|
||||
|
||||
<b><a href="postconf.5.html#alias_maps">alias_maps</a> (see 'postconf -d' output)</b>
|
||||
The alias databases that are used for <a href="local.8.html"><b>local</b>(8)</a>
|
||||
The alias databases that are used for <a href="local.8.html"><b>local</b>(8)</a>
|
||||
delivery.
|
||||
|
||||
<b><a href="postconf.5.html#forward_path">forward_path</a> (see 'postconf -d' output)</b>
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent search list for finding
|
||||
a .forward file with user-specified delivery meth-
|
||||
a .forward file with user-specified delivery meth-
|
||||
ods.
|
||||
|
||||
<b><a href="postconf.5.html#mailbox_transport">mailbox_transport</a> (empty)</b>
|
||||
Optional message delivery transport that the
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent should use for mailbox
|
||||
delivery to all local recipients, whether or not
|
||||
Optional message delivery transport that the
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent should use for mailbox
|
||||
delivery to all local recipients, whether or not
|
||||
they are found in the UNIX passwd database.
|
||||
|
||||
<b><a href="postconf.5.html#mailbox_command_maps">mailbox_command_maps</a> (empty)</b>
|
||||
Optional lookup tables with per-recipient external
|
||||
Optional lookup tables with per-recipient external
|
||||
commands to use for <a href="local.8.html"><b>local</b>(8)</a> mailbox delivery.
|
||||
|
||||
<b><a href="postconf.5.html#mailbox_command">mailbox_command</a> (empty)</b>
|
||||
Optional external command that the <a href="local.8.html"><b>local</b>(8)</a> deliv-
|
||||
Optional external command that the <a href="local.8.html"><b>local</b>(8)</a> deliv-
|
||||
ery agent should use for mailbox delivery.
|
||||
|
||||
<b><a href="postconf.5.html#home_mailbox">home_mailbox</a> (empty)</b>
|
||||
Optional pathname of a mailbox file relative to a
|
||||
Optional pathname of a mailbox file relative to a
|
||||
<a href="local.8.html"><b>local</b>(8)</a> user's home directory.
|
||||
|
||||
<b><a href="postconf.5.html#mail_spool_directory">mail_spool_directory</a> (see 'postconf -d' output)</b>
|
||||
The directory where <a href="local.8.html"><b>local</b>(8)</a> UNIX-style mailboxes
|
||||
The directory where <a href="local.8.html"><b>local</b>(8)</a> UNIX-style mailboxes
|
||||
are kept.
|
||||
|
||||
<b><a href="postconf.5.html#fallback_transport">fallback_transport</a> (empty)</b>
|
||||
Optional message delivery transport that the
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent should use for names that
|
||||
are not found in the <a href="aliases.5.html"><b>aliases</b>(5)</a> database or in the
|
||||
Optional message delivery transport that the
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent should use for names that
|
||||
are not found in the <a href="aliases.5.html"><b>aliases</b>(5)</a> database or in the
|
||||
UNIX passwd database.
|
||||
|
||||
<b><a href="postconf.5.html#luser_relay">luser_relay</a> (empty)</b>
|
||||
@ -419,7 +427,7 @@ LOCAL(8) LOCAL(8)
|
||||
Available in Postfix version 2.2 and later:
|
||||
|
||||
<b><a href="postconf.5.html#command_execution_directory">command_execution_directory</a> (empty)</b>
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent working directory for
|
||||
The <a href="local.8.html"><b>local</b>(8)</a> delivery agent working directory for
|
||||
delivery to external command.
|
||||
|
||||
<b>MAILBOX LOCKING CONTROLS</b>
|
||||
@ -428,15 +436,15 @@ LOCAL(8) LOCAL(8)
|
||||
sive lock on a mailbox file or <a href="bounce.8.html"><b>bounce</b>(8)</a> logfile.
|
||||
|
||||
<b><a href="postconf.5.html#deliver_lock_delay">deliver_lock_delay</a> (1s)</b>
|
||||
The time between attempts to acquire an exclusive
|
||||
The time between attempts to acquire an exclusive
|
||||
lock on a mailbox file or <a href="bounce.8.html"><b>bounce</b>(8)</a> logfile.
|
||||
|
||||
<b><a href="postconf.5.html#stale_lock_time">stale_lock_time</a> (500s)</b>
|
||||
The time after which a stale exclusive mailbox
|
||||
The time after which a stale exclusive mailbox
|
||||
lockfile is removed.
|
||||
|
||||
<b><a href="postconf.5.html#mailbox_delivery_lock">mailbox_delivery_lock</a> (see 'postconf -d' output)</b>
|
||||
How to lock a UNIX-style <a href="local.8.html"><b>local</b>(8)</a> mailbox before
|
||||
How to lock a UNIX-style <a href="local.8.html"><b>local</b>(8)</a> mailbox before
|
||||
attempting delivery.
|
||||
|
||||
<b>RESOURCE AND RATE CONTROLS</b>
|
||||
@ -444,17 +452,17 @@ LOCAL(8) LOCAL(8)
|
||||
Time limit for delivery to external commands.
|
||||
|
||||
<b><a href="postconf.5.html#duplicate_filter_limit">duplicate_filter_limit</a> (1000)</b>
|
||||
The maximal number of addresses remembered by the
|
||||
address duplicate filter for <a href="aliases.5.html"><b>aliases</b>(5)</a> or <a href="virtual.5.html"><b>vir-</b></a>
|
||||
The maximal number of addresses remembered by the
|
||||
address duplicate filter for <a href="aliases.5.html"><b>aliases</b>(5)</a> or <a href="virtual.5.html"><b>vir-</b></a>
|
||||
<a href="virtual.5.html"><b>tual</b>(5)</a> alias expansion, or for <a href="showq.8.html"><b>showq</b>(8)</a> queue dis-
|
||||
plays.
|
||||
|
||||
<b><a href="postconf.5.html#local_destination_concurrency_limit">local_destination_concurrency_limit</a> (2)</b>
|
||||
The maximal number of parallel deliveries via the
|
||||
The maximal number of parallel deliveries via the
|
||||
local mail delivery transport to the same recipient
|
||||
(when "<a href="postconf.5.html#local_destination_recipient_limit">local_destination_recipient_limit</a> = 1") or
|
||||
the maximal number of parallel deliveries to the
|
||||
same <a href="ADDRESS_CLASS_README.html#local_domain_class">local domain</a> (when "local_destination_recipi-
|
||||
(when "<a href="postconf.5.html#local_destination_recipient_limit">local_destination_recipient_limit</a> = 1") or
|
||||
the maximal number of parallel deliveries to the
|
||||
same <a href="ADDRESS_CLASS_README.html#local_domain_class">local domain</a> (when "local_destination_recipi-
|
||||
ent_limit > 1").
|
||||
|
||||
<b><a href="postconf.5.html#local_destination_recipient_limit">local_destination_recipient_limit</a> (1)</b>
|
||||
@ -467,45 +475,45 @@ LOCAL(8) LOCAL(8)
|
||||
|
||||
<b>SECURITY CONTROLS</b>
|
||||
<b><a href="postconf.5.html#allow_mail_to_commands">allow_mail_to_commands</a> (alias, forward)</b>
|
||||
Restrict <a href="local.8.html"><b>local</b>(8)</a> mail delivery to external com-
|
||||
Restrict <a href="local.8.html"><b>local</b>(8)</a> mail delivery to external com-
|
||||
mands.
|
||||
|
||||
<b><a href="postconf.5.html#allow_mail_to_files">allow_mail_to_files</a> (alias, forward)</b>
|
||||
Restrict <a href="local.8.html"><b>local</b>(8)</a> mail delivery to external files.
|
||||
Restrict <a href="local.8.html"><b>local</b>(8)</a> mail delivery to external files.
|
||||
|
||||
<b><a href="postconf.5.html#command_expansion_filter">command_expansion_filter</a> (see 'postconf -d' output)</b>
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent allows in $name expansions of $mailbox_com-
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent allows in $name expansions of $mailbox_com-
|
||||
mand.
|
||||
|
||||
<b><a href="postconf.5.html#default_privs">default_privs</a> (nobody)</b>
|
||||
The default rights used by the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
The default rights used by the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent for delivery to external file or command.
|
||||
|
||||
<b><a href="postconf.5.html#forward_expansion_filter">forward_expansion_filter</a> (see 'postconf -d' output)</b>
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent allows in $name expansions of $<a href="postconf.5.html#forward_path">forward_path</a>.
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent allows in $name expansions of $<a href="postconf.5.html#forward_path">forward_path</a>.
|
||||
|
||||
Available in Postfix version 2.2 and later:
|
||||
|
||||
<b><a href="postconf.5.html#execution_directory_expansion_filter">execution_directory_expansion_filter</a> (see 'postconf -d'</b>
|
||||
<b>output)</b>
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
Restrict the characters that the <a href="local.8.html"><b>local</b>(8)</a> delivery
|
||||
agent allows in $name expansions of $<a href="postconf.5.html#command_execution_directory">command_execu</a>-
|
||||
<a href="postconf.5.html#command_execution_directory">tion_directory</a>.
|
||||
|
||||
<b>MISCELLANEOUS CONTROLS</b>
|
||||
<b><a href="postconf.5.html#config_directory">config_directory</a> (see 'postconf -d' output)</b>
|
||||
The default location of the Postfix main.cf and
|
||||
The default location of the Postfix main.cf and
|
||||
master.cf configuration files.
|
||||
|
||||
<b><a href="postconf.5.html#daemon_timeout">daemon_timeout</a> (18000s)</b>
|
||||
How much time a Postfix daemon process may take to
|
||||
handle a request before it is terminated by a
|
||||
How much time a Postfix daemon process may take to
|
||||
handle a request before it is terminated by a
|
||||
built-in watchdog timer.
|
||||
|
||||
<b><a href="postconf.5.html#export_environment">export_environment</a> (see 'postconf -d' output)</b>
|
||||
The list of environment variables that a Postfix
|
||||
The list of environment variables that a Postfix
|
||||
process will export to non-Postfix processes.
|
||||
|
||||
<b><a href="postconf.5.html#ipc_timeout">ipc_timeout</a> (3600s)</b>
|
||||
@ -513,37 +521,37 @@ LOCAL(8) LOCAL(8)
|
||||
over an internal communication channel.
|
||||
|
||||
<b><a href="postconf.5.html#local_command_shell">local_command_shell</a> (empty)</b>
|
||||
Optional shell program for <a href="local.8.html"><b>local</b>(8)</a> delivery to
|
||||
Optional shell program for <a href="local.8.html"><b>local</b>(8)</a> delivery to
|
||||
non-Postfix command.
|
||||
|
||||
<b><a href="postconf.5.html#max_idle">max_idle</a> (100s)</b>
|
||||
The maximum amount of time that an idle Postfix
|
||||
daemon process waits for the next service request
|
||||
The maximum amount of time that an idle Postfix
|
||||
daemon process waits for the next service request
|
||||
before exiting.
|
||||
|
||||
<b><a href="postconf.5.html#max_use">max_use</a> (100)</b>
|
||||
The maximal number of connection requests before a
|
||||
The maximal number of connection requests before a
|
||||
Postfix daemon process terminates.
|
||||
|
||||
<b><a href="postconf.5.html#prepend_delivered_header">prepend_delivered_header</a> (command, file, forward)</b>
|
||||
The message delivery contexts where the Postfix
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent prepends a Delivered-To:
|
||||
The message delivery contexts where the Postfix
|
||||
<a href="local.8.html"><b>local</b>(8)</a> delivery agent prepends a Delivered-To:
|
||||
message header.
|
||||
|
||||
<b><a href="postconf.5.html#process_id">process_id</a> (read-only)</b>
|
||||
The process ID of a Postfix command or daemon
|
||||
The process ID of a Postfix command or daemon
|
||||
process.
|
||||
|
||||
<b><a href="postconf.5.html#process_name">process_name</a> (read-only)</b>
|
||||
The process name of a Postfix command or daemon
|
||||
The process name of a Postfix command or daemon
|
||||
process.
|
||||
|
||||
<b><a href="postconf.5.html#propagate_unmatched_extensions">propagate_unmatched_extensions</a> (canonical, virtual)</b>
|
||||
What address lookup tables copy an address exten-
|
||||
What address lookup tables copy an address exten-
|
||||
sion from the lookup key to the lookup result.
|
||||
|
||||
<b><a href="postconf.5.html#queue_directory">queue_directory</a> (see 'postconf -d' output)</b>
|
||||
The location of the Postfix top-level queue direc-
|
||||
The location of the Postfix top-level queue direc-
|
||||
tory.
|
||||
|
||||
<b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> (empty)</b>
|
||||
@ -551,15 +559,15 @@ LOCAL(8) LOCAL(8)
|
||||
sions (user+foo).
|
||||
|
||||
<b><a href="postconf.5.html#require_home_directory">require_home_directory</a> (no)</b>
|
||||
Whether or not a <a href="local.8.html"><b>local</b>(8)</a> recipient's home direc-
|
||||
tory must exist before mail delivery is attempted.
|
||||
Whether or not a <a href="local.8.html"><b>local</b>(8)</a> recipient's home direc-
|
||||
tory must exist before mail delivery is attempted.
|
||||
|
||||
<b><a href="postconf.5.html#syslog_facility">syslog_facility</a> (mail)</b>
|
||||
The syslog facility of Postfix logging.
|
||||
|
||||
<b><a href="postconf.5.html#syslog_name">syslog_name</a> (postfix)</b>
|
||||
The mail system name that is prepended to the
|
||||
process name in syslog records, so that "smtpd"
|
||||
The mail system name that is prepended to the
|
||||
process name in syslog records, so that "smtpd"
|
||||
becomes, for example, "postfix/smtpd".
|
||||
|
||||
<b>FILES</b>
|
||||
@ -579,14 +587,14 @@ LOCAL(8) LOCAL(8)
|
||||
syslogd(8), system logging
|
||||
|
||||
<b>LICENSE</b>
|
||||
The Secure Mailer license must be distributed with this
|
||||
The Secure Mailer license must be distributed with this
|
||||
software.
|
||||
|
||||
<b>HISTORY</b>
|
||||
The <b>Delivered-To:</b> message header appears in the <b>qmail</b> sys-
|
||||
tem by Daniel Bernstein.
|
||||
|
||||
The <i>maildir</i> structure appears in the <b>qmail</b> system by
|
||||
The <i>maildir</i> structure appears in the <b>qmail</b> system by
|
||||
Daniel Bernstein.
|
||||
|
||||
<b>AUTHOR(S)</b>
|
||||
|
@ -272,61 +272,71 @@ PIPE(8) PIPE(8)
|
||||
This information is modified by the <b>u</b> flag
|
||||
for case folding.
|
||||
|
||||
<b>STANDARDS</b>
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> (Enhanced status codes)
|
||||
|
||||
<b>DIAGNOSTICS</b>
|
||||
Command exit status codes are expected to follow the con-
|
||||
ventions defined in <<b>sysexits.h</b>>.
|
||||
ventions defined in <<b>sysexits.h</b>>. Exit status 0 means
|
||||
normal successful completion.
|
||||
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
rupted message files are marked so that the queue manager
|
||||
Postfix version 2.3 and later support <a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a>-style
|
||||
enhanced status codes. If a command terminates with a
|
||||
non-zero exit status, and the command output begins with
|
||||
an enhanced status code, this status code takes precedence
|
||||
over the non-zero exit status.
|
||||
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
rupted message files are marked so that the queue manager
|
||||
can move them to the <b>corrupt</b> queue for further inspection.
|
||||
|
||||
<b>SECURITY</b>
|
||||
This program needs a dual personality 1) to access the
|
||||
private Postfix queue and IPC mechanisms, and 2) to exe-
|
||||
This program needs a dual personality 1) to access the
|
||||
private Postfix queue and IPC mechanisms, and 2) to exe-
|
||||
cute external commands as the specified user. It is there-
|
||||
fore security sensitive.
|
||||
|
||||
<b>CONFIGURATION PARAMETERS</b>
|
||||
Changes to <b>main.cf</b> are picked up automatically as <a href="pipe.8.html"><b>pipe</b>(8)</a>
|
||||
processes run for only a limited amount of time. Use the
|
||||
Changes to <b>main.cf</b> are picked up automatically as <a href="pipe.8.html"><b>pipe</b>(8)</a>
|
||||
processes run for only a limited amount of time. Use the
|
||||
command "<b>postfix reload</b>" to speed up a change.
|
||||
|
||||
The text below provides only a parameter summary. See
|
||||
The text below provides only a parameter summary. See
|
||||
<a href="postconf.5.html"><b>postconf</b>(5)</a> for more details including examples.
|
||||
|
||||
<b>RESOURCE AND RATE CONTROLS</b>
|
||||
In the text below, <i>transport</i> is the first field in a <b>mas-</b>
|
||||
In the text below, <i>transport</i> is the first field in a <b>mas-</b>
|
||||
<b>ter.cf</b> entry.
|
||||
|
||||
<i>transport</i><b>_destination_concurrency_limit ($<a href="postconf.5.html#default_destination_concurrency_limit">default_destina</a>-</b>
|
||||
<b><a href="postconf.5.html#default_destination_concurrency_limit">tion_concurrency_limit</a>)</b>
|
||||
Limit the number of parallel deliveries to the same
|
||||
destination, for delivery via the named <i>transport</i>.
|
||||
destination, for delivery via the named <i>transport</i>.
|
||||
The limit is enforced by the Postfix queue manager.
|
||||
|
||||
<i>transport</i><b>_destination_recipient_limit ($<a href="postconf.5.html#default_destination_recipient_limit">default_destina</a>-</b>
|
||||
<b><a href="postconf.5.html#default_destination_recipient_limit">tion_recipient_limit</a>)</b>
|
||||
Limit the number of recipients per message deliv-
|
||||
ery, for delivery via the named <i>transport</i>. The
|
||||
Limit the number of recipients per message deliv-
|
||||
ery, for delivery via the named <i>transport</i>. The
|
||||
limit is enforced by the Postfix queue manager.
|
||||
|
||||
<i>transport</i><b>_time_limit ($<a href="postconf.5.html#command_time_limit">command_time_limit</a>)</b>
|
||||
Limit the time for delivery to external command,
|
||||
Limit the time for delivery to external command,
|
||||
for delivery via the named <i>transport</i>. The limit is
|
||||
enforced by the pipe delivery agent.
|
||||
|
||||
<b>MISCELLANEOUS CONTROLS</b>
|
||||
<b><a href="postconf.5.html#config_directory">config_directory</a> (see 'postconf -d' output)</b>
|
||||
The default location of the Postfix main.cf and
|
||||
The default location of the Postfix main.cf and
|
||||
master.cf configuration files.
|
||||
|
||||
<b><a href="postconf.5.html#daemon_timeout">daemon_timeout</a> (18000s)</b>
|
||||
How much time a Postfix daemon process may take to
|
||||
handle a request before it is terminated by a
|
||||
How much time a Postfix daemon process may take to
|
||||
handle a request before it is terminated by a
|
||||
built-in watchdog timer.
|
||||
|
||||
<b><a href="postconf.5.html#export_environment">export_environment</a> (see 'postconf -d' output)</b>
|
||||
The list of environment variables that a Postfix
|
||||
The list of environment variables that a Postfix
|
||||
process will export to non-Postfix processes.
|
||||
|
||||
<b><a href="postconf.5.html#ipc_timeout">ipc_timeout</a> (3600s)</b>
|
||||
@ -338,24 +348,24 @@ PIPE(8) PIPE(8)
|
||||
and most Postfix daemon processes.
|
||||
|
||||
<b><a href="postconf.5.html#max_idle">max_idle</a> (100s)</b>
|
||||
The maximum amount of time that an idle Postfix
|
||||
daemon process waits for the next service request
|
||||
The maximum amount of time that an idle Postfix
|
||||
daemon process waits for the next service request
|
||||
before exiting.
|
||||
|
||||
<b><a href="postconf.5.html#max_use">max_use</a> (100)</b>
|
||||
The maximal number of connection requests before a
|
||||
The maximal number of connection requests before a
|
||||
Postfix daemon process terminates.
|
||||
|
||||
<b><a href="postconf.5.html#process_id">process_id</a> (read-only)</b>
|
||||
The process ID of a Postfix command or daemon
|
||||
The process ID of a Postfix command or daemon
|
||||
process.
|
||||
|
||||
<b><a href="postconf.5.html#process_name">process_name</a> (read-only)</b>
|
||||
The process name of a Postfix command or daemon
|
||||
The process name of a Postfix command or daemon
|
||||
process.
|
||||
|
||||
<b><a href="postconf.5.html#queue_directory">queue_directory</a> (see 'postconf -d' output)</b>
|
||||
The location of the Postfix top-level queue direc-
|
||||
The location of the Postfix top-level queue direc-
|
||||
tory.
|
||||
|
||||
<b><a href="postconf.5.html#recipient_delimiter">recipient_delimiter</a> (empty)</b>
|
||||
@ -366,8 +376,8 @@ PIPE(8) PIPE(8)
|
||||
The syslog facility of Postfix logging.
|
||||
|
||||
<b><a href="postconf.5.html#syslog_name">syslog_name</a> (postfix)</b>
|
||||
The mail system name that is prepended to the
|
||||
process name in syslog records, so that "smtpd"
|
||||
The mail system name that is prepended to the
|
||||
process name in syslog records, so that "smtpd"
|
||||
becomes, for example, "postfix/smtpd".
|
||||
|
||||
<b>SEE ALSO</b>
|
||||
@ -379,7 +389,7 @@ PIPE(8) PIPE(8)
|
||||
syslogd(8), system logging
|
||||
|
||||
<b>LICENSE</b>
|
||||
The Secure Mailer license must be distributed with this
|
||||
The Secure Mailer license must be distributed with this
|
||||
software.
|
||||
|
||||
<b>AUTHOR(S)</b>
|
||||
|
@ -1710,7 +1710,10 @@ address, or Recipient address. </dd>
|
||||
<dt><b>$rbl_code</b></dt>
|
||||
|
||||
<dd>The numerical SMTP response code, as specified with the
|
||||
<a href="postconf.5.html#maps_rbl_reject_code">maps_rbl_reject_code</a> configuration parameter. </dd>
|
||||
<a href="postconf.5.html#maps_rbl_reject_code">maps_rbl_reject_code</a> configuration parameter. Note: The numerical
|
||||
SMTP response code is required, and must appear at the start of the
|
||||
reply. With Postfix 2.3 and later this information may be followed
|
||||
by an <a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> enhanced status code. </dd>
|
||||
|
||||
<dt><b>$rbl_domain</b></dt>
|
||||
|
||||
|
@ -56,12 +56,13 @@ SMTP(8) SMTP(8)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1652.html">RFC 1652</a> (8bit-MIME transport)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1870.html">RFC 1870</a> (Message Size Declaration)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2045.html">RFC 2045</a> (MIME: Format of Internet Message Bodies)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Error Codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Status Codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2046.html">RFC 2046</a> (MIME: Media Types)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2554.html">RFC 2554</a> (AUTH command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2821.html">RFC 2821</a> (SMTP protocol)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2920.html">RFC 2920</a> (SMTP Pipelining)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3207.html">RFC 3207</a> (STARTTLS command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> (Enhanced Status Codes)
|
||||
|
||||
<b>DIAGNOSTICS</b>
|
||||
Problems and transactions are logged to <b>syslogd</b>(8). Cor-
|
||||
|
@ -43,11 +43,12 @@ SMTPD(8) SMTPD(8)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1869.html">RFC 1869</a> (SMTP service extensions)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1870.html">RFC 1870</a> (Message Size Declaration)
|
||||
<a href="http://www.faqs.org/rfcs/rfc1985.html">RFC 1985</a> (ETRN command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Error Codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2034.html">RFC 2034</a> (Enhanced Status Codes)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2554.html">RFC 2554</a> (AUTH command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2821.html">RFC 2821</a> (SMTP protocol)
|
||||
<a href="http://www.faqs.org/rfcs/rfc2920.html">RFC 2920</a> (SMTP Pipelining)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3207.html">RFC 3207</a> (STARTTLS command)
|
||||
<a href="http://www.faqs.org/rfcs/rfc3463.html">RFC 3463</a> (Enhanced Status Codes)
|
||||
|
||||
<b>DIAGNOSTICS</b>
|
||||
Problems and transactions are logged to <b>syslogd</b>(8).
|
||||
|
@ -929,7 +929,10 @@ The blacklisted entity type: Client host, Helo command, Sender
|
||||
address, or Recipient address.
|
||||
.IP "\fB$rbl_code\fR"
|
||||
The numerical SMTP response code, as specified with the
|
||||
maps_rbl_reject_code configuration parameter.
|
||||
maps_rbl_reject_code configuration parameter. Note: The numerical
|
||||
SMTP response code is required, and must appear at the start of the
|
||||
reply. With Postfix 2.3 and later this information may be followed
|
||||
by an RFC 3463 enhanced status code.
|
||||
.IP "\fB$rbl_domain\fR"
|
||||
The RBL domain where $rbl_what is blacklisted.
|
||||
.IP "\fB$rbl_reason\fR"
|
||||
|
@ -17,7 +17,7 @@ delivery requests from
|
||||
the queue manager. Each request specifies a queue file, a sender
|
||||
address, a domain or host name that is treated as the reason for
|
||||
discarding the mail, and recipient information.
|
||||
The reason may be prefixed with an RFC 1893-compatible detail code.
|
||||
The reason may be prefixed with an RFC 3463-compatible detail code.
|
||||
This program expects to be run from the \fBmaster\fR(8) process
|
||||
manager.
|
||||
|
||||
|
@ -17,7 +17,7 @@ requests from
|
||||
the queue manager. Each request specifies a queue file, a sender
|
||||
address, a domain or host name that is treated as the reason for
|
||||
non-delivery, and recipient information.
|
||||
The reason may be prefixed with an RFC 1893-compatible detail code.
|
||||
The reason may be prefixed with an RFC 3463-compatible detail code.
|
||||
This program expects to be run from the \fBmaster\fR(8) process
|
||||
manager.
|
||||
|
||||
|
@ -60,10 +60,11 @@ RFC 1651 (SMTP service extensions)
|
||||
RFC 1652 (8bit-MIME transport)
|
||||
RFC 1870 (Message Size Declaration)
|
||||
RFC 2033 (LMTP protocol)
|
||||
RFC 2034 (Enhanced Error Codes)
|
||||
RFC 2034 (Enhanced Status codes)
|
||||
RFC 2554 (AUTH command)
|
||||
RFC 2821 (SMTP protocol)
|
||||
RFC 2920 (SMTP Pipelining)
|
||||
RFC 3463 (Enhanced Status codes)
|
||||
.SH DIAGNOSTICS
|
||||
.ad
|
||||
.fi
|
||||
|
@ -185,6 +185,13 @@ error) is captured for inclusion with non-delivery status reports.
|
||||
A command is forcibly terminated if it does not complete within
|
||||
\fBcommand_time_limit\fR seconds. Command exit status codes are
|
||||
expected to follow the conventions defined in <\fBsysexits.h\fR>.
|
||||
Exit status 0 means normal successful completion.
|
||||
|
||||
Postfix version 2.3 and later support RFC 3463-style enhanced
|
||||
status codes. If a command terminates with a non-zero exit
|
||||
status, and the command output begins with an enhanced
|
||||
status code, this status code takes precedence over the
|
||||
non-zero exit status.
|
||||
|
||||
A limited amount of message context is exported via environment
|
||||
variables. Characters that may have special meaning to the shell
|
||||
@ -317,6 +324,7 @@ parameter.
|
||||
.na
|
||||
.nf
|
||||
RFC 822 (ARPA Internet Text Messages)
|
||||
RFC 3463 (Enhanced status codes)
|
||||
.SH DIAGNOSTICS
|
||||
.ad
|
||||
.fi
|
||||
|
@ -221,11 +221,22 @@ into as many command-line arguments as there are recipients.
|
||||
.sp
|
||||
This information is modified by the \fBu\fR flag for case folding.
|
||||
.RE
|
||||
.SH "STANDARDS"
|
||||
.na
|
||||
.nf
|
||||
RFC 3463 (Enhanced status codes)
|
||||
.SH DIAGNOSTICS
|
||||
.ad
|
||||
.fi
|
||||
Command exit status codes are expected to
|
||||
follow the conventions defined in <\fBsysexits.h\fR>.
|
||||
Exit status 0 means normal successful completion.
|
||||
|
||||
Postfix version 2.3 and later support RFC 3463-style enhanced
|
||||
status codes. If a command terminates with a non-zero exit
|
||||
status, and the command output begins with an enhanced
|
||||
status code, this status code takes precedence over the
|
||||
non-zero exit status.
|
||||
|
||||
Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
Corrupted message files are marked so that the queue manager
|
||||
|
@ -57,12 +57,13 @@ RFC 1651 (SMTP service extensions)
|
||||
RFC 1652 (8bit-MIME transport)
|
||||
RFC 1870 (Message Size Declaration)
|
||||
RFC 2045 (MIME: Format of Internet Message Bodies)
|
||||
RFC 2034 (Enhanced Error Codes)
|
||||
RFC 2034 (Enhanced Status Codes)
|
||||
RFC 2046 (MIME: Media Types)
|
||||
RFC 2554 (AUTH command)
|
||||
RFC 2821 (SMTP protocol)
|
||||
RFC 2920 (SMTP Pipelining)
|
||||
RFC 3207 (STARTTLS command)
|
||||
RFC 3463 (Enhanced Status Codes)
|
||||
.SH DIAGNOSTICS
|
||||
.ad
|
||||
.fi
|
||||
|
@ -46,11 +46,12 @@ RFC 1652 (8bit-MIME transport)
|
||||
RFC 1869 (SMTP service extensions)
|
||||
RFC 1870 (Message Size Declaration)
|
||||
RFC 1985 (ETRN command)
|
||||
RFC 2034 (Enhanced Error Codes)
|
||||
RFC 2034 (Enhanced Status Codes)
|
||||
RFC 2554 (AUTH command)
|
||||
RFC 2821 (SMTP protocol)
|
||||
RFC 2920 (SMTP Pipelining)
|
||||
RFC 3207 (STARTTLS command)
|
||||
RFC 3463 (Enhanced Status Codes)
|
||||
.SH DIAGNOSTICS
|
||||
.ad
|
||||
.fi
|
||||
|
@ -992,7 +992,10 @@ address, or Recipient address. </dd>
|
||||
<dt><b>$rbl_code</b></dt>
|
||||
|
||||
<dd>The numerical SMTP response code, as specified with the
|
||||
maps_rbl_reject_code configuration parameter. </dd>
|
||||
maps_rbl_reject_code configuration parameter. Note: The numerical
|
||||
SMTP response code is required, and must appear at the start of the
|
||||
reply. With Postfix 2.3 and later this information may be followed
|
||||
by an RFC 3463 enhanced status code. </dd>
|
||||
|
||||
<dt><b>$rbl_domain</b></dt>
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
/* the queue manager. Each request specifies a queue file, a sender
|
||||
/* address, a domain or host name that is treated as the reason for
|
||||
/* discarding the mail, and recipient information.
|
||||
/* The reason may be prefixed with an RFC 1893-compatible detail code.
|
||||
/* The reason may be prefixed with an RFC 3463-compatible detail code.
|
||||
/* This program expects to be run from the \fBmaster\fR(8) process
|
||||
/* manager.
|
||||
/*
|
||||
|
@ -11,7 +11,7 @@
|
||||
/* the queue manager. Each request specifies a queue file, a sender
|
||||
/* address, a domain or host name that is treated as the reason for
|
||||
/* non-delivery, and recipient information.
|
||||
/* The reason may be prefixed with an RFC 1893-compatible detail code.
|
||||
/* The reason may be prefixed with an RFC 3463-compatible detail code.
|
||||
/* This program expects to be run from the \fBmaster\fR(8) process
|
||||
/* manager.
|
||||
/*
|
||||
|
@ -620,12 +620,61 @@ deliver_request.o: mail_open_ok.h
|
||||
deliver_request.o: mail_proto.h
|
||||
deliver_request.o: mail_queue.h
|
||||
deliver_request.o: recipient_list.h
|
||||
dict_ldap.o: ../../include/argv.h
|
||||
dict_ldap.o: ../../include/binhash.h
|
||||
dict_ldap.o: ../../include/dict.h
|
||||
dict_ldap.o: ../../include/match_list.h
|
||||
dict_ldap.o: ../../include/match_ops.h
|
||||
dict_ldap.o: ../../include/msg.h
|
||||
dict_ldap.o: ../../include/mymalloc.h
|
||||
dict_ldap.o: ../../include/stringops.h
|
||||
dict_ldap.o: ../../include/sys_defs.h
|
||||
dict_ldap.o: ../../include/vbuf.h
|
||||
dict_ldap.o: ../../include/vstream.h
|
||||
dict_ldap.o: ../../include/vstring.h
|
||||
dict_ldap.o: cfg_parser.h
|
||||
dict_ldap.o: db_common.h
|
||||
dict_ldap.o: dict_ldap.c
|
||||
dict_ldap.o: dict_ldap.h
|
||||
dict_ldap.o: string_list.h
|
||||
dict_mysql.o: ../../include/argv.h
|
||||
dict_mysql.o: ../../include/dict.h
|
||||
dict_mysql.o: ../../include/events.h
|
||||
dict_mysql.o: ../../include/find_inet.h
|
||||
dict_mysql.o: ../../include/match_list.h
|
||||
dict_mysql.o: ../../include/match_ops.h
|
||||
dict_mysql.o: ../../include/msg.h
|
||||
dict_mysql.o: ../../include/mymalloc.h
|
||||
dict_mysql.o: ../../include/myrand.h
|
||||
dict_mysql.o: ../../include/split_at.h
|
||||
dict_mysql.o: ../../include/sys_defs.h
|
||||
dict_mysql.o: ../../include/vbuf.h
|
||||
dict_mysql.o: ../../include/vstream.h
|
||||
dict_mysql.o: ../../include/vstring.h
|
||||
dict_mysql.o: cfg_parser.h
|
||||
dict_mysql.o: db_common.h
|
||||
dict_mysql.o: dict_mysql.c
|
||||
dict_mysql.o: dict_mysql.h
|
||||
dict_mysql.o: string_list.h
|
||||
dict_pgsql.o: ../../include/argv.h
|
||||
dict_pgsql.o: ../../include/dict.h
|
||||
dict_pgsql.o: ../../include/events.h
|
||||
dict_pgsql.o: ../../include/find_inet.h
|
||||
dict_pgsql.o: ../../include/match_list.h
|
||||
dict_pgsql.o: ../../include/match_ops.h
|
||||
dict_pgsql.o: ../../include/msg.h
|
||||
dict_pgsql.o: ../../include/mymalloc.h
|
||||
dict_pgsql.o: ../../include/myrand.h
|
||||
dict_pgsql.o: ../../include/split_at.h
|
||||
dict_pgsql.o: ../../include/sys_defs.h
|
||||
dict_pgsql.o: ../../include/vbuf.h
|
||||
dict_pgsql.o: ../../include/vstream.h
|
||||
dict_pgsql.o: ../../include/vstring.h
|
||||
dict_pgsql.o: cfg_parser.h
|
||||
dict_pgsql.o: db_common.h
|
||||
dict_pgsql.o: dict_pgsql.c
|
||||
dict_pgsql.o: dict_pgsql.h
|
||||
dict_pgsql.o: string_list.h
|
||||
dict_proxy.o: ../../include/argv.h
|
||||
dict_proxy.o: ../../include/attr.h
|
||||
dict_proxy.o: ../../include/dict.h
|
||||
|
@ -127,7 +127,7 @@
|
||||
/* Name of the host that the message could not be delivered to.
|
||||
/* This information is used for syslogging only.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP orig_rcpt
|
||||
|
@ -10,7 +10,7 @@
|
||||
/* .in +4
|
||||
/* const unsigned status; /* cleanup status */
|
||||
/* const int smtp; /* RFC 821 */
|
||||
/* const char *dsn; /* RFC 1893 */
|
||||
/* const char *dsn; /* RFC 3463 */
|
||||
/* const char *text; /* free text */
|
||||
/* .in -4
|
||||
/* } CLEANUP_STAT_DETAIL;
|
||||
|
@ -71,7 +71,7 @@
|
||||
typedef struct {
|
||||
const unsigned status; /* CLEANUP_STAT_MUMBLE */
|
||||
const int smtp; /* RFC 821 */
|
||||
const char *dsn; /* RFC 1893 */
|
||||
const char *dsn; /* RFC 3463 */
|
||||
const char *text; /* free text */
|
||||
} CLEANUP_STAT_DETAIL;
|
||||
|
||||
|
@ -107,7 +107,7 @@
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP format
|
||||
/* The reason for non-delivery.
|
||||
/* .IP ap
|
||||
|
@ -65,7 +65,7 @@
|
||||
/* by the caller when all delivery to the destination in
|
||||
/* \fInexthop\fR should be deferred. The value of the
|
||||
/* \fIhop_status\fR member is the reason, with optional
|
||||
/* RFC 1893-style detail at the beginning; it is passed
|
||||
/* RFC 3463-style detail at the beginning; it is passed
|
||||
/* to myfree().
|
||||
/*
|
||||
/* deliver_request_done() reports the delivery status back to the
|
||||
|
@ -8,7 +8,7 @@
|
||||
/*
|
||||
/* typedef struct {
|
||||
/* .in +4
|
||||
/* char dsn[...]; /* RFC 1893 */
|
||||
/* char dsn[...]; /* RFC 3463 */
|
||||
/* const char *text; /* Free text */
|
||||
/* .in -4
|
||||
/* } DSN_SPLIT;
|
||||
@ -24,7 +24,7 @@
|
||||
/*
|
||||
/* typedef struct {
|
||||
/* .in +4
|
||||
/* char dsn[...]; /* RFC 1893 */
|
||||
/* char dsn[...]; /* RFC 3463 */
|
||||
/* VSTRING *text; /* Free text */
|
||||
/* .in -4
|
||||
/* } DSN_VSTRING;
|
||||
@ -43,19 +43,19 @@
|
||||
/* size_t dsn_valid(text)
|
||||
/* const char *text;
|
||||
/* DESCRIPTION
|
||||
/* The functions in this module manipulate pairs of RFC 1893
|
||||
/* The functions in this module manipulate pairs of RFC 3463
|
||||
/* X.X.X detail codes and descriptive free text.
|
||||
/*
|
||||
/* dsn_split() splits text into an RFC 1893 detail code and
|
||||
/* dsn_split() splits text into an RFC 3463 detail code and
|
||||
/* descriptive free text. When the text does not start with
|
||||
/* a detail code, the specified default detail code is used
|
||||
/* instead. Whitespace before the optional detail code or
|
||||
/* text is skipped. dsn_split() returns a copy of the RFC
|
||||
/* 1893 detail code, and returns a pointer to (not copy of)
|
||||
/* 3463 detail code, and returns a pointer to (not copy of)
|
||||
/* the remainder of the text. The result value is the first
|
||||
/* argument.
|
||||
/*
|
||||
/* dsn_prepend() prepends the specified default RFC 1893 detail
|
||||
/* dsn_prepend() prepends the specified default RFC 3463 detail
|
||||
/* code to the specified text if no detail code is present in
|
||||
/* the text. This function produces the same result as calling
|
||||
/* concatenate() with the results from dsn_split(). The result
|
||||
@ -63,7 +63,7 @@
|
||||
/* detail code or text is skipped.
|
||||
/*
|
||||
/* dsn_vstring_alloc() creates initialized storage for an RFC
|
||||
/* 1893 detail code and descriptive free text.
|
||||
/* 3463 detail code and descriptive free text.
|
||||
/*
|
||||
/* dsn_vstring_update() updates the detail code, the descriptive
|
||||
/* free text, or both. Specify a null pointer (or zero-length
|
||||
@ -72,19 +72,19 @@
|
||||
/* dsn_vstring_free() recycles the storage that was allocated
|
||||
/* by dsn_vstring_alloc() and dsn_vstring_update().
|
||||
/*
|
||||
/* dsn_valid() returns the length of the RFC 1893 detail code
|
||||
/* dsn_valid() returns the length of the RFC 3463 detail code
|
||||
/* at the beginning of text, or zero. It does not skip initial
|
||||
/* whitespace.
|
||||
/*
|
||||
/* Arguments:
|
||||
/* .IP def_dsn
|
||||
/* Null-terminated default RFC 1893 detail code that will be
|
||||
/* Null-terminated default RFC 3463 detail code that will be
|
||||
/* used when the free text does not start with one.
|
||||
/* .IP dp
|
||||
/* Pointer to storage for copy of DSN detail code, and for
|
||||
/* pointer to free text.
|
||||
/* .IP dsn
|
||||
/* Null-terminated RFC 1893 detail code.
|
||||
/* Null-terminated RFC 3463 detail code.
|
||||
/* .IP text
|
||||
/* Null-terminated free text.
|
||||
/* .IP vp
|
||||
@ -123,7 +123,7 @@
|
||||
|
||||
#include <dsn_util.h>
|
||||
|
||||
/* dsn_valid - check RFC 1893 enhanced status code, return length or zero */
|
||||
/* dsn_valid - check RFC 3463 enhanced status code, return length or zero */
|
||||
|
||||
size_t dsn_valid(const char *text)
|
||||
{
|
||||
@ -157,7 +157,7 @@ DSN_SPLIT *dsn_split(DSN_SPLIT *dp, const char *def_dsn, const char *text)
|
||||
size_t len;
|
||||
|
||||
/*
|
||||
* Look for an optional RFC 1893 enhanced status code.
|
||||
* Look for an optional RFC 3463 enhanced status code.
|
||||
*
|
||||
* XXX If we want to enforce that the first digit of the status code in the
|
||||
* text matches the default status code, then pipe_command() needs to be
|
||||
|
@ -29,7 +29,7 @@
|
||||
* Split flat text into detail code and free text.
|
||||
*/
|
||||
typedef struct {
|
||||
char dsn[DSN_BUFSIZE]; /* RFC 1893 X.XXX.XXX detail */
|
||||
char dsn[DSN_BUFSIZE]; /* RFC 3463 X.XXX.XXX detail */
|
||||
const char *text; /* free text */
|
||||
} DSN_SPLIT;
|
||||
|
||||
@ -50,7 +50,7 @@ extern char *dsn_prepend(const char *, const char *);
|
||||
* Easy to update pair of detail code and free text.
|
||||
*/
|
||||
typedef struct {
|
||||
char dsn[DSN_LEN + 1]; /* RFC 1893 X.XXX.XXX detail */
|
||||
char dsn[DSN_LEN + 1]; /* RFC 3463 X.XXX.XXX detail */
|
||||
VSTRING *vstring; /* free text */
|
||||
} DSN_VSTRING;
|
||||
|
||||
|
@ -53,7 +53,7 @@
|
||||
/* .IP status
|
||||
/* bounced, deferred, sent, and so on.
|
||||
/* .IP detail
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP format
|
||||
|
@ -269,7 +269,8 @@ int mail_copy(const char *sender,
|
||||
dsn_vstring_update(why, TRY_AGAIN_ERROR(errno) ? "4.3.0" : "5.3.0",
|
||||
"error reading message: %m");
|
||||
if (why && write_error)
|
||||
dsn_vstring_update(why, mbox_dsn(errno), "error writing message: %m");
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "5.3.0"),
|
||||
"error writing message: %m");
|
||||
|
||||
/*
|
||||
* Use flag+errno description when the optional verbose description is
|
||||
|
@ -1689,7 +1689,7 @@ extern int var_access_map_code;
|
||||
extern char *var_rbl_reply_maps;
|
||||
|
||||
#define VAR_DEF_RBL_REPLY "default_rbl_reply"
|
||||
#define DEF_DEF_RBL_REPLY "$rbl_code 5.7.1 Service unavailable; $rbl_class [$rbl_what] blocked using $rbl_domain${rbl_reason?; $rbl_reason}"
|
||||
#define DEF_DEF_RBL_REPLY "$rbl_code Service unavailable; $rbl_class [$rbl_what] blocked using $rbl_domain${rbl_reason?; $rbl_reason}"
|
||||
extern char *var_def_rbl_reply;
|
||||
|
||||
#define REJECT_MAPS_RBL "reject_maps_rbl" /* backwards compat */
|
||||
|
@ -20,7 +20,7 @@
|
||||
* Patches change the patchlevel and the release date. Snapshots change the
|
||||
* release date only.
|
||||
*/
|
||||
#define MAIL_RELEASE_DATE "20050327"
|
||||
#define MAIL_RELEASE_DATE "20050328"
|
||||
#define MAIL_VERSION_NUMBER "2.3"
|
||||
|
||||
#define VAR_MAIL_VERSION "mail_version"
|
||||
|
@ -13,7 +13,8 @@
|
||||
/* .in -4
|
||||
/* } MBOX;
|
||||
/*
|
||||
/* MBOX *mbox_open(path, flags, mode, st, user, group, lock_style, why)
|
||||
/* MBOX *mbox_open(path, flags, mode, st, user, group, lock_style,
|
||||
/* def_dsn, why)
|
||||
/* const char *path;
|
||||
/* int flags;
|
||||
/* int mode;
|
||||
@ -21,13 +22,15 @@
|
||||
/* uid_t user;
|
||||
/* gid_t group;
|
||||
/* int lock_style;
|
||||
/* const char *def_dsn;
|
||||
/* DSN_VSTRING *why;
|
||||
/*
|
||||
/* void mbox_release(mbox)
|
||||
/* MBOX *mbox;
|
||||
/*
|
||||
/* const char *mbox_dsn(err)
|
||||
/* const char *mbox_dsn(err, def_dsn)
|
||||
/* int err;
|
||||
/* const char *def_dsn;
|
||||
/* DESCRIPTION
|
||||
/* This module manages access to UNIX mailbox-style files.
|
||||
/*
|
||||
@ -39,12 +42,22 @@
|
||||
/* The \fBlock_style\fR argument specifies a lock style from
|
||||
/* mbox_lock_mask(). Locks are applied to regular files only.
|
||||
/* The result is a handle that must be destroyed by mbox_release().
|
||||
/* The \fBdef_dsn\fR argument is given to mbox_dsn().
|
||||
/*
|
||||
/* mbox_release() releases the named mailbox. It is up to the
|
||||
/* application to close the stream.
|
||||
/*
|
||||
/* mbox_dsn() translates an errno value to a mailbox related
|
||||
/* DSN detail code.
|
||||
/* enhanced status code.
|
||||
/* .IP "EAGAIN, ESTALE"
|
||||
/* These result in a 4.2.0 soft error (mailbox problem).
|
||||
/* .IP ENOSPC
|
||||
/* This results in a 4.3.0 soft error (mail system full).
|
||||
/* .IP "EDQUOT, EFBIG"
|
||||
/* These result in a 5.2.2 hard error (mailbox full).
|
||||
/* .PP
|
||||
/* All other errors are assigned the specified default error
|
||||
/* code. Typically, one would specify 4.2.0 or 5.2.0.
|
||||
/* DIAGNOSTICS
|
||||
/* mbox_open() returns a null pointer in case of problems, and
|
||||
/* sets errno to EAGAIN if someone else has exclusive access.
|
||||
@ -90,7 +103,8 @@
|
||||
|
||||
MBOX *mbox_open(const char *path, int flags, int mode, struct stat * st,
|
||||
uid_t chown_uid, gid_t chown_gid,
|
||||
int lock_style, DSN_VSTRING *why)
|
||||
int lock_style, const char *def_dsn,
|
||||
DSN_VSTRING *why)
|
||||
{
|
||||
struct stat local_statbuf;
|
||||
MBOX *mp;
|
||||
@ -113,7 +127,7 @@ MBOX *mbox_open(const char *path, int flags, int mode, struct stat * st,
|
||||
st = &local_statbuf;
|
||||
if ((fp = safe_open(path, flags | O_NONBLOCK, mode, st,
|
||||
chown_uid, chown_gid, why->vstring)) == 0) {
|
||||
dsn_vstring_update(why, mbox_dsn(errno), "");
|
||||
dsn_vstring_update(why, mbox_dsn(errno, def_dsn), "");
|
||||
return (0);
|
||||
}
|
||||
close_on_exec(vstream_fileno(fp), CLOSE_ON_EXEC);
|
||||
@ -137,13 +151,13 @@ MBOX *mbox_open(const char *path, int flags, int mode, struct stat * st,
|
||||
if (dot_lockfile(path, why->vstring) == 0) {
|
||||
locked |= MBOX_DOT_LOCK;
|
||||
} else if (errno == EEXIST) {
|
||||
dsn_vstring_update(why, mbox_dsn(EAGAIN), "");
|
||||
dsn_vstring_update(why, mbox_dsn(EAGAIN, def_dsn), "");
|
||||
vstream_fclose(fp);
|
||||
return (0);
|
||||
} else if (lock_style & MBOX_DOT_LOCK_MAY_FAIL) {
|
||||
msg_warn("%s", vstring_str(why->vstring));
|
||||
} else {
|
||||
dsn_vstring_update(why, mbox_dsn(errno), "");
|
||||
dsn_vstring_update(why, mbox_dsn(errno, def_dsn), "");
|
||||
vstream_fclose(fp);
|
||||
return (0);
|
||||
}
|
||||
@ -163,7 +177,7 @@ MBOX *mbox_open(const char *path, int flags, int mode, struct stat * st,
|
||||
&& HUNKY_DORY(MBOX_FCNTL_LOCK, MYFLOCK_STYLE_FCNTL)) {
|
||||
locked |= lock_style;
|
||||
} else {
|
||||
dsn_vstring_update(why, mbox_dsn(errno), "");
|
||||
dsn_vstring_update(why, mbox_dsn(errno, def_dsn), "");
|
||||
if (locked & MBOX_DOT_LOCK)
|
||||
dot_unlockfile(path);
|
||||
vstream_fclose(fp);
|
||||
@ -187,8 +201,8 @@ void mbox_release(MBOX *mp)
|
||||
* (AFS), the only way to find out if a file was written successfully is
|
||||
* to close it, and therefore the close() operation is in the mail_copy()
|
||||
* routine. If we really insist on owning the vstream member, then we
|
||||
* should export appropriate methods that mail_copy() can use in order
|
||||
* to manipulate a message stream.
|
||||
* should export appropriate methods that mail_copy() can use in order to
|
||||
* manipulate a message stream.
|
||||
*/
|
||||
if (mp->locked & MBOX_DOT_LOCK)
|
||||
dot_unlockfile(mp->path);
|
||||
@ -198,10 +212,10 @@ void mbox_release(MBOX *mp)
|
||||
|
||||
/* mbox_dsn - map errno value to mailbox-related DSN detail */
|
||||
|
||||
const char *mbox_dsn(int err)
|
||||
const char *mbox_dsn(int err, const char *def_dsn)
|
||||
{
|
||||
#define TRY_AGAIN_ERROR(e) \
|
||||
(e == EACCES || e == EAGAIN || e == ESTALE)
|
||||
(e == EAGAIN || e == ESTALE)
|
||||
#define SYSTEM_FULL_ERROR(e) \
|
||||
(e == ENOSPC)
|
||||
#define MBOX_FULL_ERROR(e) \
|
||||
@ -210,5 +224,5 @@ const char *mbox_dsn(int err)
|
||||
return (TRY_AGAIN_ERROR(err) ? "4.2.0" :
|
||||
SYSTEM_FULL_ERROR(err) ? "4.3.0" :
|
||||
MBOX_FULL_ERROR(err) ? "5.2.2" :
|
||||
"5.2.0");
|
||||
def_dsn);
|
||||
}
|
||||
|
@ -27,13 +27,14 @@
|
||||
* External interface.
|
||||
*/
|
||||
typedef struct {
|
||||
char *path; /* saved path, for dot_unlock */
|
||||
char *path; /* saved path, for dot_unlock */
|
||||
VSTREAM *fp; /* open stream or null */
|
||||
int locked; /* what locks were set */
|
||||
} MBOX;
|
||||
extern MBOX *mbox_open(const char *, int, int, struct stat *, uid_t, gid_t, int, DSN_VSTRING *);
|
||||
extern MBOX *mbox_open(const char *, int, int, struct stat *, uid_t, gid_t,
|
||||
int, const char *, DSN_VSTRING *);
|
||||
extern void mbox_release(MBOX *);
|
||||
extern const char *mbox_dsn(int);
|
||||
extern const char *mbox_dsn(int, const char *);
|
||||
|
||||
/* LICENSE
|
||||
/* .ad
|
||||
|
@ -16,7 +16,7 @@
|
||||
/* output is captured for diagnostics purposes.
|
||||
/*
|
||||
/* If the command invokes exit() with a non-zero status,
|
||||
/* the delivery status is taken from an RFC 1893-style code
|
||||
/* the delivery status is taken from an RFC 3463-style code
|
||||
/* at the beginning of command output. If that information is
|
||||
/* unavailable, the delivery status is taken from the command
|
||||
/* exit status as per <sysexits.h>.
|
||||
|
@ -66,7 +66,7 @@
|
||||
/* .IP relay
|
||||
/* Name of the host we're talking to.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP format
|
||||
|
@ -9,7 +9,7 @@
|
||||
/* typedef struct {
|
||||
/* .in +4
|
||||
/* int status; /* exit status */
|
||||
/* const char *dsn; /* RFC 1893 */
|
||||
/* const char *dsn; /* RFC 3463 */
|
||||
/* const char *text; /* free text */
|
||||
/* .in -4
|
||||
/* } SYS_EXITS_DETAIL;
|
||||
|
@ -70,7 +70,7 @@
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP action
|
||||
/* "deliverable", "undeliverable", and so on.
|
||||
/* .IP format
|
||||
|
@ -54,7 +54,7 @@
|
||||
/* .IP relay
|
||||
/* Name of the host we're talking to.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP entry
|
||||
/* Message arrival time.
|
||||
/* .IP status
|
||||
|
@ -50,10 +50,11 @@
|
||||
/* RFC 1652 (8bit-MIME transport)
|
||||
/* RFC 1870 (Message Size Declaration)
|
||||
/* RFC 2033 (LMTP protocol)
|
||||
/* RFC 2034 (Enhanced Error Codes)
|
||||
/* RFC 2034 (Enhanced Status codes)
|
||||
/* RFC 2554 (AUTH command)
|
||||
/* RFC 2821 (SMTP protocol)
|
||||
/* RFC 2920 (SMTP Pipelining)
|
||||
/* RFC 3463 (Enhanced Status codes)
|
||||
/* DIAGNOSTICS
|
||||
/* Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
/* Corrupted message files are marked so that the queue manager can
|
||||
|
@ -387,10 +387,12 @@ maildir.o: ../../include/mail_params.h
|
||||
maildir.o: ../../include/make_dirs.h
|
||||
maildir.o: ../../include/maps.h
|
||||
maildir.o: ../../include/mbox_conf.h
|
||||
maildir.o: ../../include/mbox_open.h
|
||||
maildir.o: ../../include/msg.h
|
||||
maildir.o: ../../include/mymalloc.h
|
||||
maildir.o: ../../include/recipient_list.h
|
||||
maildir.o: ../../include/resolve_clnt.h
|
||||
maildir.o: ../../include/safe_open.h
|
||||
maildir.o: ../../include/sane_fsops.h
|
||||
maildir.o: ../../include/sent.h
|
||||
maildir.o: ../../include/set_eugid.h
|
||||
|
@ -161,7 +161,8 @@ int deliver_file(LOCAL_STATE state, USER_ATTR usr_attr, char *path)
|
||||
set_eugid(usr_attr.uid, usr_attr.gid);
|
||||
mp = mbox_open(path, O_APPEND | O_CREAT | O_WRONLY,
|
||||
S_IRUSR | S_IWUSR, &st, -1, -1,
|
||||
local_mbox_lock_mask | MBOX_DOT_LOCK_MAY_FAIL, why);
|
||||
local_mbox_lock_mask | MBOX_DOT_LOCK_MAY_FAIL,
|
||||
"5.2.0", why);
|
||||
if (mp != 0) {
|
||||
if (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH)) {
|
||||
vstream_fclose(mp->fp);
|
||||
|
@ -171,6 +171,13 @@
|
||||
/* A command is forcibly terminated if it does not complete within
|
||||
/* \fBcommand_time_limit\fR seconds. Command exit status codes are
|
||||
/* expected to follow the conventions defined in <\fBsysexits.h\fR>.
|
||||
/* Exit status 0 means normal successful completion.
|
||||
/*
|
||||
/* Postfix version 2.3 and later support RFC 3463-style enhanced
|
||||
/* status codes. If a command terminates with a non-zero exit
|
||||
/* status, and the command output begins with an enhanced
|
||||
/* status code, this status code takes precedence over the
|
||||
/* non-zero exit status.
|
||||
/*
|
||||
/* A limited amount of message context is exported via environment
|
||||
/* variables. Characters that may have special meaning to the shell
|
||||
@ -295,6 +302,7 @@
|
||||
/* parameter.
|
||||
/* STANDARDS
|
||||
/* RFC 822 (ARPA Internet Text Messages)
|
||||
/* RFC 3463 (Enhanced status codes)
|
||||
/* DIAGNOSTICS
|
||||
/* Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
/* Corrupted message files are marked so that the queue
|
||||
|
@ -186,7 +186,7 @@ static int deliver_mailbox_file(LOCAL_STATE state, USER_ATTR usr_attr)
|
||||
set_eugid(spool_uid, spool_gid);
|
||||
mp = mbox_open(mailbox, O_APPEND | O_WRONLY | O_CREAT,
|
||||
S_IRUSR | S_IWUSR, &st, chown_uid, chown_gid,
|
||||
local_mbox_lock_mask, why);
|
||||
local_mbox_lock_mask, "5.2.0", why);
|
||||
if (mp != 0) {
|
||||
if (spool_uid != usr_attr.uid || spool_gid != usr_attr.gid)
|
||||
set_eugid(usr_attr.uid, usr_attr.gid);
|
||||
|
@ -66,6 +66,7 @@
|
||||
#include <sent.h>
|
||||
#include <mail_params.h>
|
||||
#include <dsn_util.h>
|
||||
#include <mbox_open.h>
|
||||
|
||||
/* Application-specific. */
|
||||
|
||||
@ -189,9 +190,11 @@ int deliver_maildir(LOCAL_STATE state, USER_ATTR usr_attr, char *path)
|
||||
&& (errno != ENOENT
|
||||
|| make_dirs(tmpdir, 0700) < 0
|
||||
|| (dst = vstream_fopen(tmpfile, O_WRONLY | O_CREAT | O_EXCL, 0600)) == 0)) {
|
||||
dsn_vstring_update(why, "5.2.0", "create maildir file %s: %m", tmpfile);
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "5.2.0"),
|
||||
"create maildir file %s: %m", tmpfile);
|
||||
} else if (fstat(vstream_fileno(dst), &st) < 0) {
|
||||
dsn_vstring_update(why, "5.2.0", "create maildir file %s: %m", tmpfile);
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "5.2.0"),
|
||||
"create maildir file %s: %m", tmpfile);
|
||||
} else {
|
||||
vstring_sprintf(buf, "%lu.V%lxI%lxM%lu.%s",
|
||||
(unsigned long) starttime.tv_sec,
|
||||
@ -206,7 +209,7 @@ int deliver_maildir(LOCAL_STATE state, USER_ATTR usr_attr, char *path)
|
||||
&& (errno != ENOENT
|
||||
|| (make_dirs(curdir, 0700), make_dirs(newdir, 0700)) < 0
|
||||
|| sane_link(tmpfile, newfile) < 0)) {
|
||||
dsn_vstring_update(why, "5.2.0",
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "5.2.0"),
|
||||
"create maildir file %s: %m", newfile);
|
||||
mail_copy_status = MAIL_COPY_STAT_WRITE;
|
||||
}
|
||||
|
@ -25,7 +25,7 @@
|
||||
/* .IP recipient
|
||||
/* The recipient that will not be delivered.
|
||||
/* .IP dsn
|
||||
/* RFC 1893 detail code.
|
||||
/* RFC 3463 detail code.
|
||||
/* .IP format
|
||||
/* Free-format text that describes why delivery will not happen.
|
||||
/* DIAGNOSTICS
|
||||
|
@ -47,7 +47,7 @@
|
||||
/* .IP transport
|
||||
/* Specifies a message delivery transport.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP reason
|
||||
/* Free-format text that describes why delivery is deferred; this
|
||||
/* used for logging purposes, and for updating the message-specific
|
||||
|
@ -211,9 +211,18 @@
|
||||
/* .sp
|
||||
/* This information is modified by the \fBu\fR flag for case folding.
|
||||
/* .RE
|
||||
/* STANDARDS
|
||||
/* RFC 3463 (Enhanced status codes)
|
||||
/* DIAGNOSTICS
|
||||
/* Command exit status codes are expected to
|
||||
/* follow the conventions defined in <\fBsysexits.h\fR>.
|
||||
/* Exit status 0 means normal successful completion.
|
||||
/*
|
||||
/* Postfix version 2.3 and later support RFC 3463-style enhanced
|
||||
/* status codes. If a command terminates with a non-zero exit
|
||||
/* status, and the command output begins with an enhanced
|
||||
/* status code, this status code takes precedence over the
|
||||
/* non-zero exit status.
|
||||
/*
|
||||
/* Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
/* Corrupted message files are marked so that the queue manager
|
||||
|
@ -222,7 +222,7 @@ int main(int argc, char **argv)
|
||||
why = dsn_vstring_alloc(1);
|
||||
if ((mp = mbox_open(folder, O_APPEND | O_WRONLY | O_CREAT,
|
||||
S_IRUSR | S_IWUSR, (struct stat *) 0,
|
||||
-1, -1, lock_mask, why)) == 0)
|
||||
-1, -1, lock_mask, "5.2.0", why)) == 0)
|
||||
msg_fatal("open file %s: %s", folder, vstring_str(why->vstring));
|
||||
|
||||
/*
|
||||
|
@ -25,7 +25,7 @@
|
||||
/* .IP recipient
|
||||
/* The recipient that will not be delivered.
|
||||
/* .IP dsn
|
||||
/* RFC 1893 detail code.
|
||||
/* RFC 3463 detail code.
|
||||
/* .IP format
|
||||
/* Free-format text that describes why delivery will not happen.
|
||||
/* DIAGNOSTICS
|
||||
|
@ -47,7 +47,7 @@
|
||||
/* .IP transport
|
||||
/* Specifies a message delivery transport.
|
||||
/* .IP dsn
|
||||
/* X.YY.ZZ Error detail as specified in RFC 1893.
|
||||
/* X.YY.ZZ Error detail as specified in RFC 3463.
|
||||
/* .IP reason
|
||||
/* Free-format text that describes why delivery is deferred; this
|
||||
/* used for logging purposes, and for updating the message-specific
|
||||
|
@ -47,12 +47,13 @@
|
||||
/* RFC 1652 (8bit-MIME transport)
|
||||
/* RFC 1870 (Message Size Declaration)
|
||||
/* RFC 2045 (MIME: Format of Internet Message Bodies)
|
||||
/* RFC 2034 (Enhanced Error Codes)
|
||||
/* RFC 2034 (Enhanced Status Codes)
|
||||
/* RFC 2046 (MIME: Media Types)
|
||||
/* RFC 2554 (AUTH command)
|
||||
/* RFC 2821 (SMTP protocol)
|
||||
/* RFC 2920 (SMTP Pipelining)
|
||||
/* RFC 3207 (STARTTLS command)
|
||||
/* RFC 3463 (Enhanced Status Codes)
|
||||
/* DIAGNOSTICS
|
||||
/* Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
/* Corrupted message files are marked so that the queue manager can
|
||||
|
@ -601,7 +601,7 @@ static int smtp_start_tls(SMTP_STATE *state, int misc_flags)
|
||||
*/
|
||||
serverid = vstring_alloc(10);
|
||||
vstring_sprintf(serverid, "%s:%u", session->addr, ntohs(session->port));
|
||||
if (session->helo && strcasecmp(session->host, session->helo) != 0)
|
||||
if (session->helo != 0)
|
||||
vstring_sprintf_append(serverid, ":%s", session->helo);
|
||||
session->tls_context =
|
||||
tls_client_start(smtp_tls_ctx, session->stream,
|
||||
|
@ -36,11 +36,12 @@
|
||||
/* RFC 1869 (SMTP service extensions)
|
||||
/* RFC 1870 (Message Size Declaration)
|
||||
/* RFC 1985 (ETRN command)
|
||||
/* RFC 2034 (Enhanced Error Codes)
|
||||
/* RFC 2034 (Enhanced Status Codes)
|
||||
/* RFC 2554 (AUTH command)
|
||||
/* RFC 2821 (SMTP protocol)
|
||||
/* RFC 2920 (SMTP Pipelining)
|
||||
/* RFC 3207 (STARTTLS command)
|
||||
/* RFC 3463 (Enhanced Status Codes)
|
||||
/* DIAGNOSTICS
|
||||
/* Problems and transactions are logged to \fBsyslogd\fR(8).
|
||||
/*
|
||||
@ -71,7 +72,7 @@
|
||||
/* Disable the SMTP VRFY command.
|
||||
/* .IP "\fBsmtpd_noop_commands (empty)\fR"
|
||||
/* List of commands that the Postfix SMTP server replies to with "250
|
||||
/* 2.0.0 Ok", without doing any syntax checks and without changing state.
|
||||
/* Ok", without doing any syntax checks and without changing state.
|
||||
/* .IP "\fBstrict_rfc821_envelopes (no)\fR"
|
||||
/* Require that addresses received in SMTP MAIL FROM and RCPT TO
|
||||
/* commands are enclosed with <>, and that those addresses do
|
||||
@ -1045,7 +1046,7 @@ static int helo_cmd(SMTPD_STATE *state, int argc, SMTPD_TOKEN *argv)
|
||||
/*
|
||||
* RFC 2034: the text part of all 2xx, 4xx, and 5xx SMTP responses other
|
||||
* than the initial greeting and any response to HELO or EHLO are
|
||||
* prefaced with a status code as defined in RFC 1893.
|
||||
* prefaced with a status code as defined in RFC 3463.
|
||||
*/
|
||||
if (argc < 2) {
|
||||
state->error_mask |= MAIL_ERROR_PROTOCOL;
|
||||
@ -1093,7 +1094,7 @@ static int ehlo_cmd(SMTPD_STATE *state, int argc, SMTPD_TOKEN *argv)
|
||||
*
|
||||
* RFC 2034: the text part of all 2xx, 4xx, and 5xx SMTP responses other
|
||||
* than the initial greeting and any response to HELO or EHLO are
|
||||
* prefaced with a status code as defined in RFC 1893.
|
||||
* prefaced with a status code as defined in RFC 3463.
|
||||
*/
|
||||
if (argc < 2) {
|
||||
state->error_mask |= MAIL_ERROR_PROTOCOL;
|
||||
@ -3034,7 +3035,7 @@ static void smtpd_proto(SMTPD_STATE *state, const char *service)
|
||||
/*
|
||||
* RFC 2034: the text part of all 2xx, 4xx, and 5xx SMTP responses
|
||||
* other than the initial greeting and any response to HELO or EHLO
|
||||
* are prefaced with a status code as defined in RFC 1893.
|
||||
* are prefaced with a status code as defined in RFC 3463.
|
||||
*/
|
||||
else {
|
||||
smtpd_chat_reply(state, "220 %s", var_smtpd_banner);
|
||||
|
@ -1844,7 +1844,7 @@ static int check_table_result(SMTPD_STATE *state, const char *table,
|
||||
int status;
|
||||
const char *cmd_text;
|
||||
int cmd_len;
|
||||
static char def_dsn[] = "0.0.0";
|
||||
static char def_dsn[] = "5.7.1";
|
||||
DSN_SPLIT dp;
|
||||
|
||||
/*
|
||||
@ -2035,7 +2035,7 @@ static int check_table_result(SMTPD_STATE *state, const char *table,
|
||||
* 4xx or 5xx means NO as well. smtpd_check_reject() will validate the
|
||||
* response status code.
|
||||
*
|
||||
* If the caller specifies an RFC 1893 enhanced status code, put it
|
||||
* If the caller specifies an RFC 3463 enhanced status code, put it
|
||||
* immediately after the SMTP status code as described in RFC 2034.
|
||||
*/
|
||||
if (cmd_len == 3 && *cmd_text
|
||||
|
@ -104,9 +104,11 @@ maildir.o: ../../include/mail_params.h
|
||||
maildir.o: ../../include/make_dirs.h
|
||||
maildir.o: ../../include/maps.h
|
||||
maildir.o: ../../include/mbox_conf.h
|
||||
maildir.o: ../../include/mbox_open.h
|
||||
maildir.o: ../../include/msg.h
|
||||
maildir.o: ../../include/mymalloc.h
|
||||
maildir.o: ../../include/recipient_list.h
|
||||
maildir.o: ../../include/safe_open.h
|
||||
maildir.o: ../../include/sane_fsops.h
|
||||
maildir.o: ../../include/sent.h
|
||||
maildir.o: ../../include/set_eugid.h
|
||||
|
@ -117,7 +117,7 @@ static int deliver_mailbox_file(LOCAL_STATE state, USER_ATTR usr_attr)
|
||||
set_eugid(usr_attr.uid, usr_attr.gid);
|
||||
mp = mbox_open(usr_attr.mailbox, O_APPEND | O_WRONLY | O_CREAT,
|
||||
S_IRUSR | S_IWUSR, &st, -1, -1,
|
||||
virtual_mbox_lock_mask, why);
|
||||
virtual_mbox_lock_mask, "4.2.0", why);
|
||||
if (mp != 0) {
|
||||
if (S_ISREG(st.st_mode) == 0) {
|
||||
vstream_fclose(mp->fp);
|
||||
|
@ -60,6 +60,7 @@
|
||||
#include <defer.h>
|
||||
#include <sent.h>
|
||||
#include <mail_params.h>
|
||||
#include <mbox_open.h>
|
||||
|
||||
/* Application-specific. */
|
||||
|
||||
@ -182,9 +183,11 @@ int deliver_maildir(LOCAL_STATE state, USER_ATTR usr_attr)
|
||||
&& (errno != ENOENT
|
||||
|| make_dirs(tmpdir, 0700) < 0
|
||||
|| (dst = vstream_fopen(tmpfile, O_WRONLY | O_CREAT | O_EXCL, 0600)) == 0)) {
|
||||
dsn_vstring_update(why, "5.2.0", "create maildir file %s: %m", tmpfile);
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "4.2.0"),
|
||||
"create maildir file %s: %m", tmpfile);
|
||||
} else if (fstat(vstream_fileno(dst), &st) < 0) {
|
||||
dsn_vstring_update(why, "5.2.0", "create maildir file %s: %m", tmpfile);
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "4.2.0"),
|
||||
"create maildir file %s: %m", tmpfile);
|
||||
} else {
|
||||
vstring_sprintf(buf, "%lu.V%lxI%lxM%lu.%s",
|
||||
(unsigned long) starttime.tv_sec,
|
||||
@ -199,8 +202,8 @@ int deliver_maildir(LOCAL_STATE state, USER_ATTR usr_attr)
|
||||
&& (errno != ENOENT
|
||||
|| (make_dirs(curdir, 0700), make_dirs(newdir, 0700)) < 0
|
||||
|| sane_link(tmpfile, newfile) < 0)) {
|
||||
dsn_vstring_update(why, "5.2.0",
|
||||
"create maildir file %s: %m", newfile);
|
||||
dsn_vstring_update(why, mbox_dsn(errno, "4.2.0"),
|
||||
"create maildir file %s: %m", newfile);
|
||||
mail_copy_status = MAIL_COPY_STAT_WRITE;
|
||||
}
|
||||
}
|
||||
@ -223,8 +226,8 @@ int deliver_maildir(LOCAL_STATE state, USER_ATTR usr_attr)
|
||||
"maildir delivery failed: %s", vstring_str(why->vstring));
|
||||
if (errno == EACCES) {
|
||||
msg_warn("maildir access problem for UID/GID=%lu/%lu: %s",
|
||||
(long) usr_attr.uid, (long) usr_attr.gid,
|
||||
vstring_str(why->vstring));
|
||||
(long) usr_attr.uid, (long) usr_attr.gid,
|
||||
vstring_str(why->vstring));
|
||||
msg_warn("perhaps you need to create the maildirs in advance");
|
||||
}
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user