We need a better process retirement strategy. File:
master/multi_server.c.
+20030110
+
+ Cleanup: the virtual_mailbox_maps parameter is now optional
+ even when virtual_mailbox_domains is. This makes virtual
+ mailbox domains more like relay domains and the local
+ domain.
+
+ Portability: the makedefs script now uses the pcre-config
+ utility to find out where things are installed.
+
+ Bugfix: the SMTP server did not recognize the local built-in
+ double bounce address as local. Reported by Matthias Andree.
+ For safety sake, threw in the local postmaster address as
+ well. File: smtpd/smtpd_check.c.
+
Open problems:
Med: make qmgr recipient bounce/defer activity asynchronous
is $virtual_alias_maps for Postfix 1.1 compatibility)
virtual For hosted domains with their own mailboxes
-mailbox Known recipients are listed in $virtual_mailbox_maps
+mailbox Known recipients are listed in $virtual_mailbox_maps (if
+ this parameter is empty, the Postfix SMTP server accepts
+ all recipients for domains listed in $virtual_mailbox_domains)
Domain names are listed in $virtual_mailbox_domains (default
is $virtual_mailbox_maps for Postfix 1.1 compatibility)
Default delivery agent: virtual
relay For remote destinations that list your system as MX host
Domain names are listed in $relay_domains
- Known recipients are listed in $relay_recipient_maps (default
- is empty; if $relay_recipient_maps is empty, the Postfix
- SMTP server accepts all recipients)
+ Known recipients are listed in $relay_recipient_maps (if
+ this parameter is empty, the Postfix SMTP server accepts
+ all recipients for domains listed in $relay_domains)
Default delivery agent: relay (clone of default smtp agent)
other Restricted to mail from authorized clients
date. Snapshots change only the release date, unless they include
the same bugfixes as a patch release.
+Incompatible changes with Postfix snapshot 2.0.1-20030112
+=========================================================
+
+The Postfix build procedure now uses the pcre-config utility (part
+of PCRE version 3) to find out the pathnames of the PCRE include
+file and object library, instead of probing /usr/include and/or
+/usr/lib. To build with PCRE version 2 support you will have to
+specify pathnames as described in PCRE_README. To build without
+PCRE support, specify: make Makefiles CCARGS="-DNO_PRCE".
+
Incompatible changes with Postfix snapshot 2.0.0-20030104
=========================================================
trace unix - - n - 0 bounce
verify unix - - n - 1 verify
flush unix n - n 1000? 0 flush
+proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
<p>
+You need the <b>proxy:</b> part only if <b>master.cf</b> specifies
+that the Postfix SMTP server runs chrooted. As distributed by the
+author, Postfix runs no daemons chrooted.
+
+<p>
+
The local recipients tables are searched by the recipient address
(user@domain) and by the recipient name (the address minus the
domain). Postfix does not care what the lookup result looks like,
echo "See the RELEASE_NOTES file for more information." 1>&2
exit 1
fi
- if [ -f /usr/include/pcre/pcre.h ]
- then
- CCARGS="$CCARGS -DHAS_PCRE -I/usr/include/pcre"
- fi
# GDBM locks the DBM .pag file after open. This breaks postmap.
# if [ -f /usr/include/gdbm-ndbm.h ]
# then
# GDBM_LIBS=gdbm
# fi
SYSLIBS="-ldb"
- for name in nsl resolv pcre $GDBM_LIBS
+ for name in nsl resolv $GDBM_LIBS
do
test -e /usr/lib/lib$name.a -o -e /usr/lib/lib$name.so \
-o -e /lib/lib$name.a -o -e /lib/lib$name.so \
*) echo "Unknown system type: $SYSTEM $RELEASE" 1>&2; exit 1;;
esac
+#
+# PCRE 3.x has a pcre-config utility so we don't have to guess.
+#
+case "$CCARGS" in
+*-DHAS_PCRE*) ;;
+ *-DNO_PCRE*) ;;
+ *) pcre_cflags=`(pcre-config --cflags) 2>/dev/null`
+ pcre_libs=`(pcre-config --libs) 2>/dev/null`
+ if [ -n "$pcre_cflags" -a -n "$pcre_libs" ]
+ then
+ CCARGS="$CCARGS -DHAS_PCRE $pcre_cflags"
+ AUXLIBS="$AUXLIBS $pcre_libs"
+ fi
+ ;;
+esac
+
# Defaults that can be overruled (make makefiles CC=cc OPT=-O6 DEBUG=)
# Disable optimizations by default when compiling for Purify. Disable
# optimizations by default with gcc 2.8, until the compiler is known to
s/[<bB>]*smtp[</bB>]*(8)/<a href="smtp.8.html">&<\/a>/
s/[<bB>]*smtpd[</bB>]*(8)/<a href="smtpd.8.html">&<\/a>/
s/[<bB>]*spawn[</bB>]*(8)/<a href="spawn.8.html">&<\/a>/
+ s/[<bB>]*trace[</bB>]*(8)/<a href="trace.8.html">&<\/a>/
s/[<bB>]*triv[-</bB>]*\n*[ <bB>]*ial[-</bB>]*\n*[ <bB>]*rewrite[</bB>]*(8)/<a href="trivial-rewrite.8.html">&<\/a>/
s/[<bB>]*mailq[</bB>]*(1)/<a href="mailq.1.html">&<\/a>/
s/[<bB>]*newaliases[</bB>]*(1)/<a href="newaliases.1.html">&<\/a>/
typedef struct {
DICT dict; /* generic members */
int in_flags; /* caller-specified flags */
- CLNT_STREAM *client; /* server handle */
VSTRING *result; /* storage */
} DICT_PROXY;
* Patches change the patchlevel and the release date. Snapshots change the
* release date only, unless they include the same bugfix as a patch release.
*/
-#define MAIL_RELEASE_DATE "20030109"
+#define MAIL_RELEASE_DATE "20030112"
#define VAR_MAIL_VERSION "mail_version"
-#define DEF_MAIL_VERSION "2.0.0-" MAIL_RELEASE_DATE
+#define DEF_MAIL_VERSION "2.0.1-" MAIL_RELEASE_DATE
extern char *var_mail_version;
/*
PROXY_MAP_FIND_ERROR_RETURN(PROXY_STAT_BAD);
if (htable_locate(proxy_read_maps, map_type_name) == 0) {
msg_warn("request for unapproved table: \"%s\"", map_type_name);
- msg_warn("to approve a table for %s access, specify it in %s with %s",
- MAIL_SERVICE_PROXYMAP, MAIN_CONF_FILE, VAR_PROXY_READ_MAPS);
+ msg_warn("to approve this table for %s access, list %s:%s in %s:%s",
+ MAIL_SERVICE_PROXYMAP, DICT_TYPE_PROXY, map_type_name,
+ MAIN_CONF_FILE, VAR_PROXY_READ_MAPS);
PROXY_MAP_FIND_ERROR_RETURN(PROXY_STAT_DENY);
}
#include <record.h>
#include <rec_type.h>
#include <mail_proto.h>
+#include <mail_addr.h>
#include <verify_clnt.h>
/* Application-specific. */
* local delivery, because the virtual delivery agent requires
* user@domain style addresses in its user database.
*/
+#define MATCH_LEFT(l, r, n) (strncasecmp((l), (r), (n)) == 0 && (r)[n] == '@')
+
if ((reply->flags & RESOLVE_CLASS_LOCAL)
&& *var_local_rcpt_maps
+ && !MATCH_LEFT(var_double_bounce_sender, CONST_STR(reply->recipient),
+ strlen(var_double_bounce_sender))
+ && !MATCH_LEFT(MAIL_ADDR_POSTMASTER, CONST_STR(reply->recipient),
+ strlen(MAIL_ADDR_POSTMASTER))
&& NOMATCH(local_rcpt_maps, CONST_STR(reply->recipient)))
return (smtpd_check_reject(state, MAIL_ERROR_BOUNCE,
"%d <%s>: User unknown%s",
* Reject mail to unknown addresses in virtual mailbox domains.
*/
if ((reply->flags & RESOLVE_CLASS_VIRTUAL)
+ && *var_virt_mailbox_maps
&& NOMATCHV8(virt_mailbox_maps, CONST_STR(reply->recipient)))
return (smtpd_check_reject(state, MAIL_ERROR_BOUNCE,
"%d <%s>: User unknown%s",
/* SYNOPSIS
/* #include <clean_env.h>
/*
-/* void clean_env(export_list)
-/* const char **export_list;
+/* void clean_env(preserve_list)
+/* const char **preserve_list;
/* DESCRIPTION
/* clean_env() reduces the process environment to the bare minimum.
/* The function takes a null-terminated list of arguments.
/* clean_env - clean up the environment */
-void clean_env(char **export_list)
+void clean_env(char **preserve_list)
{
extern char **environ;
ARGV *save_list;
* Preserve selected environment variables.
*/
save_list = argv_alloc(10);
- for (cpp = export_list; *cpp; cpp++)
+ for (cpp = preserve_list; *cpp; cpp++)
if ((value = safe_getenv(*cpp)) != 0)
argv_add(save_list, *cpp, value, (char *) 0);
argv_terminate(save_list);