From: Wietse Venema
Date: Tue, 21 Jun 2005 05:00:00 +0000 (-0500)
Subject: postfix-2.2.4
X-Git-Tag: v2.2.4^0
X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d72f0910037796661e0be36e0d718c2045a322bb;p=thirdparty%2Fpostfix.git
postfix-2.2.4
---
diff --git a/postfix/HISTORY b/postfix/HISTORY
index 8d7cd173d..897522f44 100644
--- a/postfix/HISTORY
+++ b/postfix/HISTORY
@@ -10513,6 +10513,13 @@ Apologies for any names omitted.
is subject to address rewriting and other processing where
applicable. File: cleanup/cleanup_message.c.
+20050402
+
+ Cleanup: updated error messages about MIME processing errors
+ in the SMTP client. These errors are no longer specific to
+ 8bit->7bit conversion; they can also happen with generic
+ address mapping. File: smtp/smtp_proto.c.
+
20050407
@%^!#& Thanks to inadequate SASL documentation the client
@@ -10521,13 +10528,6 @@ Apologies for any names omitted.
SASL support was implemented, and now Postfix needs to be
fixed. Files: */*_sasl_glue.c.
-20050402
-
- Cleanup: updated error messages about MIME processing errors
- in the SMTP client. These errors are no longer specific to
- 8bit->7bit conversion; they can also happen with generic
- address mapping. File: smtp/smtp_proto.c.
-
20050409
Safety: the CDB map now logs a warning when the source file
@@ -10571,3 +10571,41 @@ Apologies for any names omitted.
the fall-back relay can't be used because it was already
tried via a cached session. Files: util/argv.c,
smtp/smtp_connect.c.
+
+20050517
+
+ Bugfix: in a DSN report, the original recipient should not
+ be xtext encoded. File: bounce/bounce_notify_util.c.
+
+20050523
+
+ Bugfix: mymalloc() panic with mistyped server host list.
+ File: global/dict_pgsql.c.
+
+20040530
+
+ Bugfix: TLS MUST_NOPEERMATCH didn't work (inherited from
+ TLS patch), and a dangling pointer in the corresponding
+ error handling. File: smtp/smtp_proto.c.
+
+20050615
+
+ Cleanup: the SMTP client now sends QUIT when the initial
+ HELO handshake fails. it still doesn't send QUIT when the
+ server greets with a [45]XX code, as that is handled in the
+ connection management code before a session context exists.
+ File: smtp/smtp_connect.c.
+
+20050616
+
+ Bugfix: missing or mis-placed va_end() macros, found in
+ Postfix 2.3 code review. Files: util/netstring.c,
+ util/myaddrinfo.c, util/attr_clnt.c, util/vstream.c.
+
+20050621
+
+ Portability: file descriptor passing is available for Tru64
+ UNIX, but AIX4 and IRIX6 will have to do without. This means
+ no SMTP connection caching for those platforms. Albert
+ Chin. File: util/sys_defs.h.
+
diff --git a/postfix/README_FILES/CDB_README b/postfix/README_FILES/CDB_README
index 7d0e36b12..8c32ee4dd 100644
--- a/postfix/README_FILES/CDB_README
+++ b/postfix/README_FILES/CDB_README
@@ -53,6 +53,6 @@ After postfix has been built with cdb support, you can use "cdb" tables
wherever you can use read-only "hash", "btree" or "dbm" tables. However, the
"ppoossttmmaapp --ii" (incremental record insertion) and "ppoossttmmaapp --dd" (incremental
record deletion) command-line options are not available. For the same reason
-the "cdb" map type cannot be used to store the volatile address verification
+the "cdb" map type cannot be used to store the persistent address verification
cache for the verify(8) service.
diff --git a/postfix/examples/chroot-setup/Solaris8 b/postfix/examples/chroot-setup/Solaris8
index f9767fe61..dd749466d 100644
--- a/postfix/examples/chroot-setup/Solaris8
+++ b/postfix/examples/chroot-setup/Solaris8
@@ -79,6 +79,7 @@ more="
/etc/netconfig
/etc/default/init
/etc/inet/services
+/etc/resolv.conf
/etc/services
/usr/lib/ld.so
/usr/lib/ld.so.1
diff --git a/postfix/html/CDB_README.html b/postfix/html/CDB_README.html
index 4506251d9..4307cc6f7 100644
--- a/postfix/html/CDB_README.html
+++ b/postfix/html/CDB_README.html
@@ -80,5 +80,5 @@ for tinycdb, or alternatively, for the D.J.B. version:
"dbm" tables. However, the "postmap -i" (incremental record
insertion) and "postmap -d" (incremental record deletion)
command-line options are not available. For the same reason the
-"cdb" map type cannot be used to store the volatile address
+"cdb" map type cannot be used to store the persistent address
verification cache for the verify(8) service.
diff --git a/postfix/html/mysql_table.5.html b/postfix/html/mysql_table.5.html
index 23ed116ae..f6668cb92 100644
--- a/postfix/html/mysql_table.5.html
+++ b/postfix/html/mysql_table.5.html
@@ -45,7 +45,7 @@ MYSQL_TABLE(5) MYSQL_TABLE(5)
version.
Postfix 2.2 has enhanced query interfaces for MySQL and
- PostreSQL, these include features previously available
+ PostgreSQL, these include features previously available
only in the Postfix LDAP client. In the new interface the
SQL query is specified via a single query parameter
(described in more detail below). When the new query
diff --git a/postfix/man/man5/mysql_table.5 b/postfix/man/man5/mysql_table.5
index b3f3c3eb2..90d71bd75 100644
--- a/postfix/man/man5/mysql_table.5
+++ b/postfix/man/man5/mysql_table.5
@@ -45,7 +45,7 @@ Note: with this form, the passwords for the MySQL sources are
written in main.cf, which is normally world-readable. Support
for this form will be removed in a future Postfix version.
-Postfix 2.2 has enhanced query interfaces for MySQL and PostreSQL,
+Postfix 2.2 has enhanced query interfaces for MySQL and PostgreSQL,
these include features previously available only in the Postfix
LDAP client. In the new interface the SQL query is specified via
a single \fBquery\fR parameter (described in more detail below).
diff --git a/postfix/proto/CDB_README.html b/postfix/proto/CDB_README.html
index bc88967c4..5777e7573 100644
--- a/postfix/proto/CDB_README.html
+++ b/postfix/proto/CDB_README.html
@@ -80,5 +80,5 @@ for tinycdb, or alternatively, for the D.J.B. version:
"dbm" tables. However, the "postmap -i" (incremental record
insertion) and "postmap -d" (incremental record deletion)
command-line options are not available. For the same reason the
-"cdb" map type cannot be used to store the volatile address
+"cdb" map type cannot be used to store the persistent address
verification cache for the verify(8) service.
diff --git a/postfix/proto/mysql_table b/postfix/proto/mysql_table
index 1ddc07aa9..9992b6193 100644
--- a/postfix/proto/mysql_table
+++ b/postfix/proto/mysql_table
@@ -37,7 +37,7 @@
# written in main.cf, which is normally world-readable. Support
# for this form will be removed in a future Postfix version.
#
-# Postfix 2.2 has enhanced query interfaces for MySQL and PostreSQL,
+# Postfix 2.2 has enhanced query interfaces for MySQL and PostgreSQL,
# these include features previously available only in the Postfix
# LDAP client. In the new interface the SQL query is specified via
# a single \fBquery\fR parameter (described in more detail below).
diff --git a/postfix/src/bounce/bounce_notify_util.c b/postfix/src/bounce/bounce_notify_util.c
index c4138a388..4fddc9bd3 100644
--- a/postfix/src/bounce/bounce_notify_util.c
+++ b/postfix/src/bounce/bounce_notify_util.c
@@ -613,9 +613,8 @@ int bounce_recipient_dsn(VSTREAM *bounce, BOUNCE_INFO *bounce_info)
post_mail_fprintf(bounce, "Final-Recipient: rfc822; %s",
bounce_info->log_handle->recipient);
if (bounce_info->log_handle->orig_rcpt) {
- xtext_quote(bounce_info->buf, bounce_info->log_handle->orig_rcpt, "+=");
post_mail_fprintf(bounce, "Original-Recipient: rfc822; %s",
- STR(bounce_info->buf));
+ bounce_info->log_handle->orig_rcpt);
}
post_mail_fprintf(bounce, "Action: %s",
bounce_info->flush == BOUNCE_MSG_FAIL ?
diff --git a/postfix/src/global/dict_pgsql.c b/postfix/src/global/dict_pgsql.c
index 78ae4b28a..025cb6b37 100644
--- a/postfix/src/global/dict_pgsql.c
+++ b/postfix/src/global/dict_pgsql.c
@@ -600,7 +600,7 @@ static void pgsql_parse_config(DICT_PGSQL *dict_pgsql, const char *pgsqlcf)
hosts = cfg_get_str(p, "hosts", "", 0, 0);
dict_pgsql->hosts = argv_split(hosts, " ,\t\r\n");
- if (dict_pgsql->hosts == 0) {
+ if (dict_pgsql->hosts->argc == 0) {
argv_add(dict_pgsql->hosts, "localhost", ARGV_END);
argv_terminate(dict_pgsql->hosts);
if (msg_verbose)
diff --git a/postfix/src/global/mail_version.h b/postfix/src/global/mail_version.h
index 8a6688dfd..d11dbc9a6 100644
--- a/postfix/src/global/mail_version.h
+++ b/postfix/src/global/mail_version.h
@@ -20,8 +20,8 @@
* Patches change the patchlevel and the release date. Snapshots change the
* release date only.
*/
-#define MAIL_RELEASE_DATE "20050428"
-#define MAIL_VERSION_NUMBER "2.2.3"
+#define MAIL_RELEASE_DATE "20050621"
+#define MAIL_VERSION_NUMBER "2.2.4"
#define VAR_MAIL_VERSION "mail_version"
#ifdef SNAPSHOT
diff --git a/postfix/src/smtp/smtp_connect.c b/postfix/src/smtp/smtp_connect.c
index 3b69841d3..24474ca06 100644
--- a/postfix/src/smtp/smtp_connect.c
+++ b/postfix/src/smtp/smtp_connect.c
@@ -682,8 +682,12 @@ int smtp_connect(SMTP_STATE *state)
state->final_server = (cpp[1] == 0 && next == 0);
if (addr->pref == domain_best_pref)
session->features |= SMTP_FEATURE_BEST_MX;
- if ((session->features & SMTP_FEATURE_FROM_CACHE) != 0
- || smtp_helo(state, misc_flags) == 0)
+ if ((session->features & SMTP_FEATURE_FROM_CACHE) == 0
+ && smtp_helo(state, misc_flags) != 0) {
+ if (vstream_ferror(session->stream) == 0
+ && vstream_feof(session->stream) == 0)
+ smtp_quit(state);
+ } else
smtp_xfer(state);
smtp_cleanup_session(state);
} else {
diff --git a/postfix/src/smtp/smtp_proto.c b/postfix/src/smtp/smtp_proto.c
index f197ea5e1..67dfaeca2 100644
--- a/postfix/src/smtp/smtp_proto.c
+++ b/postfix/src/smtp/smtp_proto.c
@@ -627,10 +627,11 @@ static int smtp_start_tls(SMTP_STATE *state, int misc_flags)
if (session->tls_info.peer_CN != NULL) {
if (!session->tls_info.peer_verified) {
msg_info("Server certificate could not be verified");
- if (session->tls_enforce_tls) {
+ if (session->tls_enforce_peername) {
tls_client_stop(smtp_tls_ctx, session->stream,
var_smtp_starttls_tmout, 1,
&(session->tls_info));
+ session->tls_context = 0;
return (smtp_site_fail(state, 450,
"TLS failure: Cannot verify server certificate"));
}
@@ -646,10 +647,11 @@ static int smtp_start_tls(SMTP_STATE *state, int misc_flags)
* testing if a certificate is available.
*/
else {
- if (session->tls_enforce_tls) {
+ if (session->tls_enforce_peername) {
tls_client_stop(smtp_tls_ctx, session->stream,
var_smtp_starttls_tmout, 1,
&(session->tls_info));
+ session->tls_context = 0;
return (smtp_site_fail(state, 450,
"TLS failure: Cannot verify server hostname"));
}
diff --git a/postfix/src/smtpstone/smtp-sink.c b/postfix/src/smtpstone/smtp-sink.c
index 090a66ff7..d4b82f702 100644
--- a/postfix/src/smtpstone/smtp-sink.c
+++ b/postfix/src/smtpstone/smtp-sink.c
@@ -553,7 +553,7 @@ static void disconnect(SINK_STATE *state)
vstream_fclose(state->stream);
vstring_free(state->buffer);
myfree((char *) state);
- if (max_count > 0 && ++counter >= max_count)
+ if (max_count > 0 && counter >= max_count)
exit(0);
}
diff --git a/postfix/src/util/attr_clnt.c b/postfix/src/util/attr_clnt.c
index b2c843711..188899bd0 100644
--- a/postfix/src/util/attr_clnt.c
+++ b/postfix/src/util/attr_clnt.c
@@ -274,4 +274,5 @@ void attr_clnt_control(ATTR_CLNT *client, int name,...)
msg_panic("%s: bad name %d", myname, name);
}
}
+ va_end(ap);
}
diff --git a/postfix/src/util/myaddrinfo.c b/postfix/src/util/myaddrinfo.c
index afb610652..db2a60454 100644
--- a/postfix/src/util/myaddrinfo.c
+++ b/postfix/src/util/myaddrinfo.c
@@ -680,6 +680,7 @@ void myaddrinfo_control(int name,...)
msg_panic("%s: bad name %d", myname, name);
}
}
+ va_end(ap);
}
#ifdef EMULATE_IPV4_ADDRINFO
diff --git a/postfix/src/util/netstring.c b/postfix/src/util/netstring.c
index 3f3e73112..f42f44978 100644
--- a/postfix/src/util/netstring.c
+++ b/postfix/src/util/netstring.c
@@ -316,8 +316,8 @@ void netstring_put_multi(VSTREAM *stream,...)
if (vstream_fwrite(stream, data, data_len) != data_len)
netstring_except(stream, vstream_ftimeout(stream) ?
NETSTRING_ERR_TIME : NETSTRING_ERR_EOF);
- va_end(ap);
}
+ va_end(ap);
vstream_fwrite(stream, ",", 1);
}
diff --git a/postfix/src/util/sys_defs.h b/postfix/src/util/sys_defs.h
index 11e847e41..463dbf4e7 100644
--- a/postfix/src/util/sys_defs.h
+++ b/postfix/src/util/sys_defs.h
@@ -256,6 +256,7 @@ extern int opterr; /* XXX use */
#define STATFS_IN_SYS_MOUNT_H
#define HAS_POSIX_REGEXP
#define BROKEN_WRITE_SELECT_ON_NON_BLOCKING_PIPE
+#define NO_MSGHDR_MSG_CONTROL
#ifndef NO_IPV6
# define HAS_IPV6
#endif
@@ -524,6 +525,7 @@ extern int initgroups(const char *, int);
#define NATIVE_COMMAND_DIR "/usr/sbin"
#define NATIVE_DAEMON_DIR "/usr/libexec/postfix"
+#define CANT_USE_SEND_RECV_MSG
#endif
#ifdef AIX3
@@ -558,6 +560,7 @@ extern int setegid(gid_t);
extern int initgroups(const char *, int);
#define NATIVE_SENDMAIL_PATH "/usr/lib/sendmail"
+#define CANT_USE_SEND_RECV_MSG
#endif
/*
@@ -587,6 +590,7 @@ extern int initgroups(const char *, int);
#define USE_STATVFS
#define STATVFS_IN_SYS_STATVFS_H
#define BROKEN_WRITE_SELECT_ON_NON_BLOCKING_PIPE
+#define CANT_USE_SEND_RECV_MSG
#endif
#if defined(IRIX5)
@@ -594,6 +598,9 @@ extern int initgroups(const char *, int);
#endif
#if defined(IRIX6)
+#ifndef NO_IPV6
+# define HAS_IPV6
+#endif
#define HAS_POSIX_REGEXP
#define PIPES_CANT_FIONREAD
#endif
diff --git a/postfix/src/util/vstream.c b/postfix/src/util/vstream.c
index 6786c3c9e..9b7cb1151 100644
--- a/postfix/src/util/vstream.c
+++ b/postfix/src/util/vstream.c
@@ -1122,6 +1122,7 @@ void vstream_control(VSTREAM *stream, int name,...)
msg_panic("%s: bad name %d", myname, name);
}
}
+ va_end(ap);
}
/* vstream_vfprintf - formatted print engine */