- The postdrop mail submission command could die with SIGHUP and
abort mail submission. This was observed with mail from cron jobs.
- The MySQL client aborted with complaints about multiple attempts
to register the same lookup table. This was observed in the proxymap
daemon.
- As a workaround for agressive SMTP command pipelining clients,
the Postfix SMTP server now allows SMTP clients to overshoot the
SMTP server recipient limit without triggering the server hard
error limit, as long as the number of excess recipients stays within
a hard-coded overshoot limit of 1000. If you have such clients then
you also need to specify "smtpd_error_sleep_time = 0" or else
performance will be poor.
- The LMTP client attempted to reuse a connection after timeout,
causing protocol synchronization errors.
- The trivial-rewrite server could core dump after temporary table
lookup failure. This was not observed in Postfix 2.0.
Prereq: "2.0.19"
diff -cr /tmp/postfix-2.0.19/src/global/mail_version.h ./src/global/mail_version.h
*** /tmp/postfix-2.0.19/src/global/mail_version.h Fri Mar 12 17:12:27 2004
--- ./src/global/mail_version.h Thu Apr 22 19:40:45 2004
***************
*** 20,29 ****
* 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 "20040312"
#define VAR_MAIL_VERSION "mail_version"
! #define DEF_MAIL_VERSION "2.0.19"
extern char *var_mail_version;
/*
--- 20,29 ----
* 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 "20040422"
#define VAR_MAIL_VERSION "mail_version"
! #define DEF_MAIL_VERSION "2.0.20"
extern char *var_mail_version;
/*
diff -cr /tmp/postfix-2.0.19/HISTORY ./HISTORY
*** /tmp/postfix-2.0.19/HISTORY Fri Mar 12 21:32:34 2004
--- ./HISTORY Wed Apr 21 16:40:31 2004
***************
*** 7977,7982 ****
--- 7977,8019 ----
keys. Problem reported by Andrei Koulik. Files:
util/match_ops.c, src/trivial-rewrite/transport.c.
+ 20040401
+
+ Bugfix: the MySQL client aborted because of a spurious
+ dict_register() call, causing complaints about a table
+ already being registered. File: util/dict_mysql.c.
+
+ 20040407
+
+ Bugfix: missing return statement at the end of the
+ FREE_MEMORY_AND_RETURN error handling macro. This could
+ cause core dump after table lookup failure. Adi Prasaja.
+ File: trivial-rewrite/resolve.c.
+
+ 20040414
+
+ Bugfix: postdrop should not enable SIGHUP (and abort mail
+ delivery) when SIGHUP was ignored by the parent process.
+ File: postdrop/postdrop.c. Victor Duchovni, Morgan Stanley.
+
+
+ 20040415
+
+ Bugfix: the LMTP client attempted to reuse a connection
+ after timeout, causing protocol synchronization errors.
+ Reported by Rob Mueller. File: lmtp/lmtp.c.
+
+ 20040421
+
+ Workaround: allow pipelined SMTP clients to overshoot the
+ SMTP server recipient limit without triggering the server
+ hard error limit. The SMTP server does not count "too many
+ recipients" towards the hard error limit, as long as the
+ number of excess recipients stays within a hard-coded
+ overshoot limit of 1000. Based on a Postfix 2.1 solution
+ that was developed in cooperation with Victor Duchovni.
+ Files: smtpd/smtpd.c, smtpd/smtpd_state.c, smtpd/smtpd.h.
+
Open problems:
Doc: mention the proxy_interfaces parameter everywhere the
diff -cr /tmp/postfix-2.0.19/html/postdrop.1.html ./html/postdrop.1.html
*** /tmp/postfix-2.0.19/html/postdrop.1.html Mon Jun 9 20:16:04 2003
--- ./html/postdrop.1.html Wed Apr 21 16:57:25 2004
***************
*** 13,19 ****
Options:
! -c The main.cf configuration file is in the named
directory instead of the default configuration
directory. See also the MAIL_CONFIG environment
setting below.
--- 13,20 ----
Options:
! -c config_dir
! The main.cf configuration file is in the named
directory instead of the default configuration
directory. See also the MAIL_CONFIG environment
setting below.
diff -cr /tmp/postfix-2.0.19/man/man1/postdrop.1 ./man/man1/postdrop.1
*** /tmp/postfix-2.0.19/man/man1/postdrop.1 Mon Jun 9 20:16:04 2003
--- ./man/man1/postdrop.1 Wed Apr 21 16:57:25 2004
***************
*** 16,22 ****
directory and copies its standard input to the file.
Options:
! .IP \fB-c \fIconfig_dir\fR
The \fBmain.cf\fR configuration file is in the named directory
instead of the default configuration directory. See also the
MAIL_CONFIG environment setting below.
--- 16,22 ----
directory and copies its standard input to the file.
Options:
! .IP "\fB-c \fIconfig_dir\fR"
The \fBmain.cf\fR configuration file is in the named directory
instead of the default configuration directory. See also the
MAIL_CONFIG environment setting below.
diff -cr /tmp/postfix-2.0.19/src/lmtp/lmtp.c ./src/lmtp/lmtp.c
*** /tmp/postfix-2.0.19/src/lmtp/lmtp.c Wed Sep 10 20:13:30 2003
--- ./src/lmtp/lmtp.c Thu Apr 15 16:07:05 2004
***************
*** 417,426 ****
lmtp_chat_notify(state);
/*
! * Disconnect if we're not cacheing connections. The pipelined protocol
! * state machine knows if it should have sent a QUIT command.
*/
! if (state->session != 0 && !var_lmtp_cache_conn)
state->session = lmtp_session_free(state->session);
/*
--- 417,430 ----
lmtp_chat_notify(state);
/*
! * Disconnect if we're not caching connections. The pipelined protocol
! * state machine knows if it should have sent a QUIT command. Do not
! * cache a broken connection.
*/
! if (state->session != 0
! && (!var_lmtp_cache_conn
! || vstream_ferror(state->session->stream)
! || vstream_feof(state->session->stream)))
state->session = lmtp_session_free(state->session);
/*
diff -cr /tmp/postfix-2.0.19/src/postdrop/postdrop.c ./src/postdrop/postdrop.c
*** /tmp/postfix-2.0.19/src/postdrop/postdrop.c Fri Jun 6 13:03:20 2003
--- ./src/postdrop/postdrop.c Wed Apr 14 15:31:01 2004
***************
*** 10,16 ****
/* directory and copies its standard input to the file.
/*
/* Options:
! /* .IP \fB-c \fIconfig_dir\fR
/* The \fBmain.cf\fR configuration file is in the named directory
/* instead of the default configuration directory. See also the
/* MAIL_CONFIG environment setting below.
--- 10,16 ----
/* directory and copies its standard input to the file.
/*
/* Options:
! /* .IP "\fB-c \fIconfig_dir\fR"
/* The \fBmain.cf\fR configuration file is in the named directory
/* instead of the default configuration directory. See also the
/* MAIL_CONFIG environment setting below.
***************
*** 266,272 ****
signal(SIGPIPE, SIG_IGN);
signal(SIGXFSZ, SIG_IGN);
! signal(SIGHUP, postdrop_sig);
signal(SIGINT, postdrop_sig);
signal(SIGQUIT, postdrop_sig);
signal(SIGTERM, postdrop_sig);
--- 266,273 ----
signal(SIGPIPE, SIG_IGN);
signal(SIGXFSZ, SIG_IGN);
! if (signal(SIGHUP, SIG_IGN) == SIG_DFL)
! signal(SIGHUP, postdrop_sig);
signal(SIGINT, postdrop_sig);
signal(SIGQUIT, postdrop_sig);
signal(SIGTERM, postdrop_sig);
diff -cr /tmp/postfix-2.0.19/src/smtpd/smtpd.c ./src/smtpd/smtpd.c
*** /tmp/postfix-2.0.19/src/smtpd/smtpd.c Wed Sep 10 19:42:19 2003
--- ./src/smtpd/smtpd.c Wed Apr 21 14:29:04 2004
***************
*** 956,963 ****
}
}
if (var_smtpd_rcpt_limit && state->rcpt_count >= var_smtpd_rcpt_limit) {
- state->error_mask |= MAIL_ERROR_POLICY;
smtpd_chat_reply(state, "452 Error: too many recipients");
return (-1);
}
if (SMTPD_STAND_ALONE(state) == 0) {
--- 956,966 ----
}
}
if (var_smtpd_rcpt_limit && state->rcpt_count >= var_smtpd_rcpt_limit) {
smtpd_chat_reply(state, "452 Error: too many recipients");
+ /* XXX Turning off the error sleep involves too invasive changes. */
+ if (state->rcpt_overshoot++ < 1000)
+ return (0);
+ state->error_mask |= MAIL_ERROR_POLICY;
return (-1);
}
if (SMTPD_STAND_ALONE(state) == 0) {
***************
*** 987,992 ****
--- 990,997 ----
state->recipient = 0;
}
state->rcpt_count = 0;
+ /* XXX Must flush the command history. */
+ state->rcpt_overshoot = 0;
}
/* data_cmd - process DATA command */
diff -cr /tmp/postfix-2.0.19/src/smtpd/smtpd.h ./src/smtpd/smtpd.h
*** /tmp/postfix-2.0.19/src/smtpd/smtpd.h Wed Mar 19 10:35:49 2003
--- ./src/smtpd/smtpd.h Wed Apr 21 13:50:02 2004
***************
*** 73,78 ****
--- 73,79 ----
int recursion;
off_t msg_size;
int junk_cmds;
+ int rcpt_overshoot;
#ifdef USE_SASL_AUTH
#if SASL_VERSION_MAJOR >= 2
const char *sasl_mechanism_list;
diff -cr /tmp/postfix-2.0.19/src/smtpd/smtpd_state.c ./src/smtpd/smtpd_state.c
*** /tmp/postfix-2.0.19/src/smtpd/smtpd_state.c Wed Mar 19 10:39:13 2003
--- ./src/smtpd/smtpd_state.c Wed Apr 21 13:50:15 2004
***************
*** 92,97 ****
--- 92,98 ----
state->recursion = 0;
state->msg_size = 0;
state->junk_cmds = 0;
+ state->rcpt_overshoot = 0;
state->defer_if_permit_client = 0;
state->defer_if_permit_helo = 0;
state->defer_if_permit_sender = 0;
diff -cr /tmp/postfix-2.0.19/src/trivial-rewrite/resolve.c ./src/trivial-rewrite/resolve.c
*** /tmp/postfix-2.0.19/src/trivial-rewrite/resolve.c Fri Mar 12 10:06:29 2004
--- ./src/trivial-rewrite/resolve.c Wed Apr 7 18:52:41 2004
***************
*** 200,205 ****
--- 200,206 ----
tok822_free_tree(tree); \
if (addr_buf) \
vstring_free(addr_buf); \
+ return; \
}
/*
diff -cr /tmp/postfix-2.0.19/src/util/dict_mysql.c ./src/util/dict_mysql.c
*** /tmp/postfix-2.0.19/src/util/dict_mysql.c Thu Jun 5 19:29:36 2003
--- ./src/util/dict_mysql.c Thu Apr 1 21:56:13 2004
***************
*** 373,379 ****
dict_mysql->name->len_hosts);
if (dict_mysql->pldb == NULL)
msg_fatal("couldn't intialize pldb!\n");
- dict_register(name, (DICT *) dict_mysql);
return (DICT_DEBUG (&dict_mysql->dict));
}
--- 373,378 ----