Prereq: "2.2.11" diff -cr /var/tmp/postfix-2.2.11/src/global/mail_version.h ./src/global/mail_version.h *** /var/tmp/postfix-2.2.11/src/global/mail_version.h Mon Jul 24 16:17:03 2006 --- ./src/global/mail_version.h Sun Oct 21 10:06:00 2007 *************** *** 20,27 **** * Patches change the patchlevel and the release date. Snapshots change the * release date only. */ ! #define MAIL_RELEASE_DATE "20060724" ! #define MAIL_VERSION_NUMBER "2.2.11" #define VAR_MAIL_VERSION "mail_version" #ifdef SNAPSHOT --- 20,27 ---- * Patches change the patchlevel and the release date. Snapshots change the * release date only. */ ! #define MAIL_RELEASE_DATE "20071021" ! #define MAIL_VERSION_NUMBER "2.2.12" #define VAR_MAIL_VERSION "mail_version" #ifdef SNAPSHOT diff -cr /var/tmp/postfix-2.2.11/HISTORY ./HISTORY *** /var/tmp/postfix-2.2.11/HISTORY Mon Jul 24 16:20:23 2006 --- ./HISTORY Sun Oct 21 10:05:10 2007 *************** *** 11012,11014 **** --- 11012,11047 ---- if Postfix could somehow be forced to send HELO instead of EHLO. Victor Duchovni. File: src/smtp/smtp_proto.c. + 20061203 + + Bugfix (introduced with Postfix 2.2): with SMTP server + tarpit delays of smtp_rset_timeout or larger, the SMTP + client could get out of sync with the server while reusing + a connection. The symptoms were "recipient rejected .. in + reply to DATA". Fix by Victor Duchovni and Wietse. File: + smtp/smtp_proto.c, smtp/smtp_connect.c. Back-ported from + Postfix 2.3. + + Safety: additional error tests to prevent connection reuse + after timeout error. Files: lmtp/lmtp.c, smtp/smtp_connect.c. + Back-ported from Postfix 2.3. + + 20070529 + + Cleanup: misleading error message while discarding malformed + input after queue file write error. File postdrop/postdrop.c. + + 20070911 + + Bugfix (introduced Postfix 2.2.11): TLS client certificate + with unparsable canonical name caused the SMTP server's + policy client to allocate zero-length memory, triggering + an assertion that it shouldn't do such things. File: + smtpd/smtpd_check.c. + + 20070917 + + Workaround: the flush daemon forces an access time update + for the per-destination logfile, to prevent an excessive + rate of delivery attempts when the queue file system is + mounted with "noatime". File: flush/flush.c. diff -cr /var/tmp/postfix-2.2.11/src/flush/flush.c ./src/flush/flush.c *** /var/tmp/postfix-2.2.11/src/flush/flush.c Fri Feb 4 15:41:13 2005 --- ./src/flush/flush.c Wed Oct 17 11:51:07 2007 *************** *** 147,152 **** --- 147,153 ---- #include #include + #include #include #include #include *************** *** 478,483 **** --- 479,489 ---- */ if (count > 0 && ftruncate(vstream_fileno(log), (off_t) 0) < 0) msg_fatal("%s: truncate fast flush logfile %s: %m", myname, path); + + /* + * Workaround for noatime mounts. Use futimes() if available. + */ + (void) utimes(VSTREAM_PATH(log), (struct timeval *) 0); /* * Request delivery and clean up. diff -cr /var/tmp/postfix-2.2.11/src/lmtp/lmtp.c ./src/lmtp/lmtp.c *** /var/tmp/postfix-2.2.11/src/lmtp/lmtp.c Thu Dec 1 09:19:08 2005 --- ./src/lmtp/lmtp.c Sun Dec 3 16:35:59 2006 *************** *** 443,448 **** --- 443,449 ---- if (state->session != 0 && (!var_lmtp_cache_conn || vstream_ferror(state->session->stream) + || vstream_ftimeout(state->session->stream) || vstream_feof(state->session->stream))) state->session = lmtp_session_free(state->session); diff -cr /var/tmp/postfix-2.2.11/src/postdrop/postdrop.c ./src/postdrop/postdrop.c *** /var/tmp/postfix-2.2.11/src/postdrop/postdrop.c Mon Apr 18 04:16:31 2005 --- ./src/postdrop/postdrop.c Tue May 29 14:20:22 2007 *************** *** 406,411 **** --- 406,413 ---- while ((rec_type = rec_get(VSTREAM_IN, buf, var_line_limit)) > 0 && rec_type != REC_TYPE_END) /* void */ ; + if (rec_type <= 0) + msg_fatal("uid=%ld: malformed input", (long) uid); break; } if (rec_type == REC_TYPE_END) diff -cr /var/tmp/postfix-2.2.11/src/smtp/smtp_connect.c ./src/smtp/smtp_connect.c *** /var/tmp/postfix-2.2.11/src/smtp/smtp_connect.c Wed Jan 4 14:58:39 2006 --- ./src/smtp/smtp_connect.c Sun Dec 3 16:36:39 2006 *************** *** 378,384 **** * logical next-hop state, so that we won't cache connections to * less-preferred MX hosts under the logical next-hop destination. */ ! if (session->reuse_count > 0) { smtp_save_session(state); if (HAVE_NEXTHOP_STATE(state)) FREE_NEXTHOP_STATE(state); --- 378,388 ---- * logical next-hop state, so that we won't cache connections to * less-preferred MX hosts under the logical next-hop destination. */ ! if (session->reuse_count > 0 ! /* Redundant tests for safety... */ ! && vstream_ferror(session->stream) == 0 ! && vstream_ftimeout(session->stream) == 0 ! && vstream_feof(session->stream) == 0) { smtp_save_session(state); if (HAVE_NEXTHOP_STATE(state)) FREE_NEXTHOP_STATE(state); *************** *** 709,714 **** --- 713,719 ---- if ((session->features & SMTP_FEATURE_FROM_CACHE) == 0 && smtp_helo(state, misc_flags) != 0) { if (vstream_ferror(session->stream) == 0 + && vstream_ftimeout(session->stream) == 0 && vstream_feof(session->stream) == 0) smtp_quit(state); } else diff -cr /var/tmp/postfix-2.2.11/src/smtp/smtp_proto.c ./src/smtp/smtp_proto.c *** /var/tmp/postfix-2.2.11/src/smtp/smtp_proto.c Tue Jul 18 20:24:18 2006 --- ./src/smtp/smtp_proto.c Sun Dec 3 15:03:47 2006 *************** *** 888,893 **** --- 888,895 ---- } while (0) #define RETURN(x) do { \ + if (recv_state != SMTP_STATE_LAST) \ + DONT_CACHE_THIS_SESSION; \ vstring_free(next_command); \ if (session->mime_state) \ session->mime_state = mime_state_free(session->mime_state); \ diff -cr /var/tmp/postfix-2.2.11/src/smtpd/smtpd_check.c ./src/smtpd/smtpd_check.c *** /var/tmp/postfix-2.2.11/src/smtpd/smtpd_check.c Sat Jul 22 19:40:23 2006 --- ./src/smtpd/smtpd_check.c Tue Sep 11 10:29:40 2007 *************** *** 3072,3078 **** coded_CN_buf = 0; \ coded_CN = ""; \ } else { \ ! coded_CN_buf = vstring_alloc(strlen(CN)); \ xtext_quote(coded_CN_buf, CN, ""); \ coded_CN = STR(coded_CN_buf); \ } \ --- 3072,3078 ---- coded_CN_buf = 0; \ coded_CN = ""; \ } else { \ ! coded_CN_buf = vstring_alloc(strlen(CN) + 1); \ xtext_quote(coded_CN_buf, CN, ""); \ coded_CN = STR(coded_CN_buf); \ } \