pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mail mail/postfix: update to 3.6.2



details:   https://anonhg.NetBSD.org/pkgsrc/rev/5fa4331afa75
branches:  trunk
changeset: 456348:5fa4331afa75
user:      taca <taca%pkgsrc.org@localhost>
date:      Mon Jul 26 15:38:10 2021 +0000

description:
mail/postfix: update to 3.6.2

* pkgsrc change: Add supportfor blocklistd(3) (and blacklistd(3)).

* From release annuonce:

Fixed in Postfix 3.6.2, 3.5.12, 3.4.22, 3.3.19:

  * In Postfix 3.6, fixed a false "Result too large" (ERANGE) fatal
    error in the compatibility_level parser, because there was no
    'errno = 0' statement before an strtol() call. In Postfix
    3.3-3.5, fixed two older latent bugs of this kind (introduced
    in 1999 and in Postfix 2.11). Problem reported by David Bohman.

  * (problem introduced in Postfix 3.3) "Null pointer read" error
    in the cleanup daemon when "header_from_format = standard" (the
    default as of Postfix 3.3), and email was submitted with
    /usr/sbin/sendmail without From: header, and an all-space full
    name was specified in 1) the password file, 2) with "sendmail
    -F", or 3) with the NAME environment variable. Found by Renaud
    Metrich.

  * (problem introduced in Postfix 2.4) False "too many reverse
    jump" warnings in the showq daemon, because loop detection code
    was comparing memory addresses instead of queue file names.
    Reported by Mehmet Avcioglu.

  * (problem introduced in 1999) The Postfix SMTP server was sending
    all session transcripts to the error_notice_recipient (default:
    postmaster), instead of sending transcripts of bounced mail to
    the bounce_notice_recipient (default: postmaster). Reported by
    Hans van Zijst.

Fixed in Postfix 3.6.2, 3.5.12, 3.4.22:

  * The texthash: map implementation broke tls_server_sni_maps,
    because it did not support multi-file inputs. Reported by
    Christopher Gurnee, who also found an instance of the missing
    code in the "postmap -F" source code. File: util/dict_thash.c.

diffstat:

 mail/postfix-mysql/Makefile                      |   3 +-
 mail/postfix/Makefile.common                     |   4 +-
 mail/postfix/distinfo                            |  16 ++++++---
 mail/postfix/patches/patch-ai                    |  38 ++++++++++++++++++-----
 mail/postfix/patches/patch-src_smtpd_Makefile.in |  24 +++++++++++++++
 mail/postfix/patches/patch-src_smtpd_pfilter.c   |  35 ++++++++++++++++++++++
 mail/postfix/patches/patch-src_smtpd_pfilter.h   |  20 ++++++++++++
 mail/postfix/patches/patch-src_smtpd_smtpd.c     |  24 +++++++++++++++
 8 files changed, 145 insertions(+), 19 deletions(-)

diffs (267 lines):

diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix-mysql/Makefile
--- a/mail/postfix-mysql/Makefile       Mon Jul 26 14:21:52 2021 +0000
+++ b/mail/postfix-mysql/Makefile       Mon Jul 26 15:38:10 2021 +0000
@@ -1,7 +1,6 @@
-# $NetBSD: Makefile,v 1.7 2021/06/23 20:33:13 nia Exp $
+# $NetBSD: Makefile,v 1.8 2021/07/26 15:38:10 taca Exp $
 #
 
-PKGREVISION=           1
 COMMENT=               Postfix SMTP server MySQL backend module
 
 POSTFIX_LIB=           mysql
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/Makefile.common
--- a/mail/postfix/Makefile.common      Mon Jul 26 14:21:52 2021 +0000
+++ b/mail/postfix/Makefile.common      Mon Jul 26 15:38:10 2021 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile.common,v 1.36 2021/06/14 14:29:47 taca Exp $
+# $NetBSD: Makefile.common,v 1.37 2021/07/26 15:38:10 taca Exp $
 # used by mail/postfix/Makefile
 # used by mail/postfix/Makefile.module
 
-DISTNAME=      postfix-3.6.1
+DISTNAME=      postfix-3.6.2
 CATEGORIES=    mail
 MASTER_SITES=  ftp://ftp.porcupine.org/mirrors/postfix-release/official/
 
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/distinfo
--- a/mail/postfix/distinfo     Mon Jul 26 14:21:52 2021 +0000
+++ b/mail/postfix/distinfo     Mon Jul 26 15:38:10 2021 +0000
@@ -1,9 +1,13 @@
-$NetBSD: distinfo,v 1.194 2021/06/14 14:29:47 taca Exp $
+$NetBSD: distinfo,v 1.195 2021/07/26 15:38:10 taca Exp $
 
-SHA1 (postfix-3.6.1.tar.gz) = 35fdad40c229014e6afa7164057d2c588db530ba
-RMD160 (postfix-3.6.1.tar.gz) = 343e1e07b6b959932c0052d3a30ee61a02b6adc0
-SHA512 (postfix-3.6.1.tar.gz) = 6f83a6aa55bd442fe005b35c7470483ff5ba6781121f783b07ef454580354fc5c85d0d5106936810d6bef0f5592937f0863eec3b82e138caac7694e2a3bb7bc3
-Size (postfix-3.6.1.tar.gz) = 4748754 bytes
+SHA1 (postfix-3.6.2.tar.gz) = 712230d7b0789d6610d84e8f03937f720fe3963d
+RMD160 (postfix-3.6.2.tar.gz) = 2ec2f96a7cafd853528646ef1e5c311a96fa8914
+SHA512 (postfix-3.6.2.tar.gz) = 464ce9ec77e637ede91123472a0383b2bfda52102f9e9852c7191016d4fda2e14f302f2db9793887c182688c2a14dde6eeda728523196a627a8028f99555a4d9
+Size (postfix-3.6.2.tar.gz) = 4749530 bytes
 SHA1 (patch-aa) = c8216f133e202a7bb37682b0dbc1448f021e7c1c
 SHA1 (patch-ag) = feccf4aba580f581953b32e6c3a2c453fcb9131c
-SHA1 (patch-ai) = 51748ccf92da543f7ff640f36906a29b5db3f6e3
+SHA1 (patch-ai) = 2d14b2bfe3d8f2b3bc80f31531285accd8eb84ac
+SHA1 (patch-src_smtpd_Makefile.in) = 8133f9cceb0c1c0250d6543cb060c66288571722
+SHA1 (patch-src_smtpd_pfilter.c) = c747d2f3584f694eb7b73b19118b4d8b450cfe7f
+SHA1 (patch-src_smtpd_pfilter.h) = 153b516da89d709d293c6086c2f126791bd945d6
+SHA1 (patch-src_smtpd_smtpd.c) = 7d709a727ca28efb2b07d3247feb7349576ae1f0
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/patches/patch-ai
--- a/mail/postfix/patches/patch-ai     Mon Jul 26 14:21:52 2021 +0000
+++ b/mail/postfix/patches/patch-ai     Mon Jul 26 15:38:10 2021 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-ai,v 1.41 2019/07/17 13:33:00 triaxx Exp $
+$NetBSD: patch-ai,v 1.42 2021/07/26 15:38:10 taca Exp $
 
 1) Add shlib definitions for NetBSD 5; the build system must be
 hard-coded per OS per version.  Not yet reported upstream.
@@ -7,9 +7,11 @@
 
 3) Add support for FreeBSD 12.
 
---- makedefs.orig      2019-03-10 23:42:59.000000000 +0000
+4) Add blocklist(3) support.
+
+--- makedefs.orig      2021-04-24 20:49:37.000000000 +0000
 +++ makedefs
-@@ -298,6 +298,15 @@ case "$SYSTEM.$RELEASE" in
+@@ -309,6 +309,15 @@ case "$SYSTEM.$RELEASE" in
                : ${SHLIB_ENV="LD_LIBRARY_PATH=`pwd`/lib"}
                : ${PLUGIN_LD="${CC} -shared"}
                ;;
@@ -25,7 +27,7 @@
   DragonFly.*) SYSTYPE=DRAGONFLY
                ;;
    OpenBSD.2*) SYSTYPE=OPENBSD2
-@@ -326,25 +335,7 @@ case "$SYSTEM.$RELEASE" in
+@@ -337,25 +346,7 @@ case "$SYSTEM.$RELEASE" in
                ;;
    ekkoBSD.1*) SYSTYPE=EKKOBSD1
                ;;
@@ -52,7 +54,7 @@
                : ${SHLIB_SUFFIX=.so}
                : ${SHLIB_CFLAGS=-fPIC}
                : ${SHLIB_LD="${CC-gcc} -shared"' -Wl,-soname,${LIB}'}
-@@ -423,13 +414,6 @@ case "$SYSTEM.$RELEASE" in
+@@ -434,13 +425,6 @@ case "$SYSTEM.$RELEASE" in
                esac
                ;;
     ULTRIX.4*) SYSTYPE=ULTRIX4
@@ -66,7 +68,7 @@
                for l in syslog resolv; do
                    if [ -f /usr/local/lib/lib$l.a ]; then
                        SYSLIBS="$SYSLIBS -l$l"
-@@ -471,33 +455,8 @@ case "$SYSTEM.$RELEASE" in
+@@ -482,33 +466,8 @@ case "$SYSTEM.$RELEASE" in
                esac;;
                # Tested with RedHat 3.03 on 20020729.
      Linux.1*) SYSTYPE=LINUX1
@@ -100,7 +102,7 @@
                for name in nsl resolv $GDBM_LIBS
                do
                    for lib in /usr/lib64 /lib64 /usr/lib /lib
-@@ -597,24 +556,6 @@ EOF
+@@ -608,24 +567,6 @@ EOF
                ;;
       GNU.0*|GNU/kFreeBSD.[567]*)
                SYSTYPE=GNU0
@@ -125,7 +127,7 @@
                for name in nsl resolv
                do
                    for lib in /usr/lib64 /lib64 /usr/lib /lib
-@@ -645,26 +586,14 @@ EOF
+@@ -656,26 +597,14 @@ EOF
  HP-UX.A.09.*) SYSTYPE=HPUX9
                SYSLIBS=-ldbm
                CCARGS="$CCARGS -DMISSING_USLEEP -DNO_SNPRINTF"
@@ -152,7 +154,7 @@
                ;;
  ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix543
                RANLIB=echo
-@@ -706,12 +635,12 @@ ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix5
+@@ -717,12 +646,12 @@ ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix5
                esac
                : ${SHLIB_CFLAGS=-fPIC}
                : ${SHLIB_SUFFIX=.dylib}
@@ -167,3 +169,21 @@
                ;;
      dcosx.1*) SYSTYPE=DCOSX1
                RANLIB=echo
+@@ -746,6 +675,17 @@ ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix5
+ esac
+ 
+ #
++# Support for blocklist(3) or blacklist(3).
++#
++if test -f /usr/include/blocklist.h; then
++   CCARGS="$CCARGS -DHAVE_BLOCKLIST"
++   SYSLIBS="$SYSLIBS -lblocklist"
++elif test -f /usr/include/blacklist.h; then
++   CCARGS="$CCARGS -DHAVE_BLACKLIST"
++   SYSLIBS="$SYSLIBS -lblacklist"
++fi
++
++#
+ # sigsetjmp()/siglongjmp() can be "better" than setjmp()/longjmp()
+ # if used wisely (that is: almost never, just like signals).
+ # Unfortunately some implementations have been buggy in the past.
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/patches/patch-src_smtpd_Makefile.in
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/postfix/patches/patch-src_smtpd_Makefile.in  Mon Jul 26 15:38:10 2021 +0000
@@ -0,0 +1,24 @@
+$NetBSD: patch-src_smtpd_Makefile.in,v 1.1 2021/07/26 15:38:10 taca Exp $
+
+Add blocklist(3) support.
+
+--- src/smtpd/Makefile.in.orig 2021-04-18 20:45:05.000000000 +0000
++++ src/smtpd/Makefile.in
+@@ -2,14 +2,14 @@ SHELL        = /bin/sh
+ SRCS  = smtpd.c smtpd_token.c smtpd_check.c smtpd_chat.c smtpd_state.c \
+       smtpd_peer.c smtpd_sasl_proto.c smtpd_sasl_glue.c smtpd_proxy.c \
+       smtpd_xforward.c smtpd_dsn_fix.c smtpd_milter.c smtpd_resolve.c \
+-      smtpd_expand.c smtpd_haproxy.c
++      smtpd_expand.c smtpd_haproxy.c pfilter.c
+ OBJS  = smtpd.o smtpd_token.o smtpd_check.o smtpd_chat.o smtpd_state.o \
+       smtpd_peer.o smtpd_sasl_proto.o smtpd_sasl_glue.o smtpd_proxy.o \
+       smtpd_xforward.o smtpd_dsn_fix.o smtpd_milter.o smtpd_resolve.o \
+-      smtpd_expand.o smtpd_haproxy.o
++      smtpd_expand.o smtpd_haproxy.o pfilter.o
+ HDRS  = smtpd_token.h smtpd_check.h smtpd_chat.h smtpd_sasl_proto.h \
+       smtpd_sasl_glue.h smtpd_proxy.h smtpd_dsn_fix.h smtpd_milter.h \
+-      smtpd_resolve.h smtpd_expand.h
++      smtpd_resolve.h smtpd_expand.h pfilter.h
+ TESTSRC       = smtpd_token_test.c
+ DEFS  = -I. -I$(INC_DIR) -D$(SYSTYPE)
+ CFLAGS        = $(DEBUG) $(OPT) $(DEFS)
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/patches/patch-src_smtpd_pfilter.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/postfix/patches/patch-src_smtpd_pfilter.c    Mon Jul 26 15:38:10 2021 +0000
@@ -0,0 +1,35 @@
+$NetBSD: patch-src_smtpd_pfilter.c,v 1.1 2021/07/26 15:38:10 taca Exp $
+
+Add blocklist(3) support.
+
+--- src/smtpd/pfilter.c.orig   2021-07-26 14:19:11.410358217 +0000
++++ src/smtpd/pfilter.c
+@@ -0,0 +1,28 @@
++#include "pfilter.h"
++#include <stdio.h>    /* for NULL */
++
++#if defined(HAVE_BLOCKLIST) || defined(HAVE_BLACKLIST)
++
++#ifdef HAVE_BLOCKLIST
++#include <blocklist.h>
++#else
++#include <blacklist.h>
++#endif
++
++static struct blocklist *blstate;
++
++void
++pfilter_notify(int a, int fd)
++{
++      if (blstate == NULL)
++              blstate = blocklist_open();
++      if (blstate == NULL)
++              return;
++      (void)blocklist_r(blstate, a, fd, "smtpd");
++      if (a == 0) {
++              blocklist_close(blstate);
++              blstate = NULL;
++      }
++}
++
++#endif
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/patches/patch-src_smtpd_pfilter.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/postfix/patches/patch-src_smtpd_pfilter.h    Mon Jul 26 15:38:10 2021 +0000
@@ -0,0 +1,20 @@
+$NetBSD: patch-src_smtpd_pfilter.h,v 1.1 2021/07/26 15:38:10 taca Exp $
+
+Add blocklist(3) support.
+
+--- src/smtpd/pfilter.h.orig   2021-07-26 14:19:32.266525421 +0000
++++ src/smtpd/pfilter.h
+@@ -0,0 +1,13 @@
++
++#if defined(HAVE_BLOCKLIST) || defined(HAVE_BLACKLIST)
++
++void pfilter_notify(int, int);
++
++#ifdef HAVE_BLACKLIST
++#define       blocklist                       blacklist
++#define blocklist_open()              blacklist_open()
++#define       blocklist_r(a, b, c, d)         blacklist_r((a), (b), (c), (d))
++#define blocklist_close(a)            blacklist_close((a))
++#endif
++
++#endif
diff -r 4240510e70d3 -r 5fa4331afa75 mail/postfix/patches/patch-src_smtpd_smtpd.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/postfix/patches/patch-src_smtpd_smtpd.c      Mon Jul 26 15:38:10 2021 +0000
@@ -0,0 +1,24 @@
+$NetBSD: patch-src_smtpd_smtpd.c,v 1.1 2021/07/26 15:38:10 taca Exp $
+
+Add blocklist(3) support.
+
+--- src/smtpd/smtpd.c.orig     2021-07-24 21:43:57.000000000 +0000
++++ src/smtpd/smtpd.c
+@@ -1263,6 +1263,8 @@
+ #include <smtpd_milter.h>
+ #include <smtpd_expand.h>
+ 
++#include "pfilter.h"
++
+  /*
+   * Tunable parameters. Make sure that there is some bound on the length of
+   * an SMTP command, so that the mail system stays in control even when a
+@@ -5804,6 +5806,8 @@ static void smtpd_proto(SMTPD_STATE *sta
+                  || strcmp(state->reason, REASON_LOST_CONNECTION)) {
+           msg_info("%s after %s from %s",
+                    state->reason, state->where, state->namaddr);
++          if (strcmp(state->where, SMTPD_CMD_AUTH) == 0)
++              pfilter_notify(1, vstream_fileno(state->client));
+       }
+     }
+ 



Home | Main Index | Thread Index | Old Index