Received: by mail.netbsd.org (Postfix, from userid 605) id 1C2C784D52; Wed, 17 Feb 2021 01:49:14 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 5797D84D25 for ; Wed, 17 Feb 2021 01:49:13 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([IPv6:::1]) by localhost (mail.netbsd.org [IPv6:::1]) (amavisd-new, port 10025) with ESMTP id HHq6i07KLnSJ for ; Wed, 17 Feb 2021 01:49:12 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.netbsd.org [199.233.217.197]) by mail.netbsd.org (Postfix) with ESMTP id B58AA84CE8 for ; Wed, 17 Feb 2021 01:49:12 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id AE057FA95; Wed, 17 Feb 2021 01:49:12 +0000 (UTC) Content-Transfer-Encoding: 7bit Content-Type: multipart/mixed; boundary="_----------=_1613526552206050" MIME-Version: 1.0 Date: Wed, 17 Feb 2021 01:49:12 +0000 From: "Emmanuel Dreyfus" Subject: CVS commit: pkgsrc/mail/opendmarc To: pkgsrc-changes@NetBSD.org Reply-To: manu@netbsd.org X-Mailer: log_accum Message-Id: <20210217014912.AE057FA95@cvs.NetBSD.org> Sender: pkgsrc-changes-owner@NetBSD.org List-Id: Precedence: bulk List-Unsubscribe: This is a multi-part message in MIME format. --_----------=_1613526552206050 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Module Name: pkgsrc Committed By: manu Date: Wed Feb 17 01:49:12 UTC 2021 Modified Files: pkgsrc/mail/opendmarc: Makefile distinfo Added Files: pkgsrc/mail/opendmarc/patches: patch-opendmarc_opendmarc-arcares.c patch-opendmarc_opendmarc-arcseal.c Log Message: Fix two null pointer reference To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 pkgsrc/mail/opendmarc/Makefile cvs rdiff -u -r1.8 -r1.9 pkgsrc/mail/opendmarc/distinfo cvs rdiff -u -r0 -r1.1 \ pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcares.c \ pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcseal.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. --_----------=_1613526552206050 Content-Disposition: inline Content-Length: 3645 Content-Transfer-Encoding: binary Content-Type: text/x-diff; charset=us-ascii Modified files: Index: pkgsrc/mail/opendmarc/Makefile diff -u pkgsrc/mail/opendmarc/Makefile:1.22 pkgsrc/mail/opendmarc/Makefile:1.23 --- pkgsrc/mail/opendmarc/Makefile:1.22 Thu Dec 24 01:10:23 2020 +++ pkgsrc/mail/opendmarc/Makefile Wed Feb 17 01:49:12 2021 @@ -1,10 +1,10 @@ -# $NetBSD: Makefile,v 1.22 2020/12/24 01:10:23 manu Exp $ +# $NetBSD: Makefile,v 1.23 2021/02/17 01:49:12 manu Exp $ GITHUB_PROJECT= OpenDMARC GITHUB_TAG= rel-opendmarc-1-4-0-Beta1 DISTNAME= rel-opendmarc-1-4-0-Beta1 PKGNAME= opendmarc-1.4.0b1 -#PKGREVISION= 1 +PKGREVISION= 1 CATEGORIES= mail MASTER_SITES= ${MASTER_SITE_GITHUB:=trusteddomainproject/} DIST_SUBDIR= ${GITHUB_PROJECT} Index: pkgsrc/mail/opendmarc/distinfo diff -u pkgsrc/mail/opendmarc/distinfo:1.8 pkgsrc/mail/opendmarc/distinfo:1.9 --- pkgsrc/mail/opendmarc/distinfo:1.8 Thu Dec 24 01:10:23 2020 +++ pkgsrc/mail/opendmarc/distinfo Wed Feb 17 01:49:12 2021 @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.8 2020/12/24 01:10:23 manu Exp $ +$NetBSD: distinfo,v 1.9 2021/02/17 01:49:12 manu Exp $ SHA1 (OpenDMARC/rel-opendmarc-1-4-0-Beta1.tar.gz) = 74ad1ef9f9a12b5fadef5919807cd55f7655d8d8 RMD160 (OpenDMARC/rel-opendmarc-1-4-0-Beta1.tar.gz) = e8dda5350a734509843a04329777478d9410b796 @@ -7,3 +7,5 @@ Size (OpenDMARC/rel-opendmarc-1-4-0-Beta SHA1 (patch-configure.ac) = d174911e4de37d3b50b525469cbe410bb7ae119f SHA1 (patch-libopendmarc_opendmarc__dns.c) = e76ca13707677525b72609b4a5268d77efcfba84 SHA1 (patch-libopendmarc_opendmarc__spf__dns.c) = b6e1311be8e9ef44c333be57fef474f6b080a199 +SHA1 (patch-opendmarc_opendmarc-arcares.c) = 6bf207d9984341fe13120ff8d25a77ff7f6ae1e5 +SHA1 (patch-opendmarc_opendmarc-arcseal.c) = a2ace25f687736876ea4299a0177d3c3ed1e247b Added files: Index: pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcares.c diff -u /dev/null pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcares.c:1.1 --- /dev/null Wed Feb 17 01:49:12 2021 +++ pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcares.c Wed Feb 17 01:49:12 2021 @@ -0,0 +1,17 @@ +$NetBSD: patch-opendmarc_opendmarc-arcares.c,v 1.1 2021/02/17 01:49:12 manu Exp $ + +Avoid handling a NULL pointer when parsing a malformed header + +--- opendmarc/opendmarc-arcares.c.orig 2021-02-16 16:33:34.454279528 +0000 ++++ opendmarc/opendmarc-arcares.c 2021-02-16 16:35:14.240570993 +0000 +@@ -324,8 +324,10 @@ + if (*token_ptr == '\0') + return 0; + tag_label = strsep(&token_ptr, "="); ++ if (token_ptr == NULL) ++ return -1; + tag_value = opendmarc_arcares_strip_whitespace(token_ptr); + tag_code = opendmarc_arcares_convert(aar_arc_tags, tag_label); + + switch (tag_code) + { Index: pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcseal.c diff -u /dev/null pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcseal.c:1.1 --- /dev/null Wed Feb 17 01:49:12 2021 +++ pkgsrc/mail/opendmarc/patches/patch-opendmarc_opendmarc-arcseal.c Wed Feb 17 01:49:12 2021 @@ -0,0 +1,20 @@ +$NetBSD: patch-opendmarc_opendmarc-arcseal.c,v 1.1 2021/02/17 01:49:12 manu Exp $ + +Avoid handling a NULL pointer when parsing a malformed header + +--- opendmarc/opendmarc-arcseal.c.orig 2021-02-16 23:42:14.132748160 +0100 ++++ opendmarc/opendmarc-arcseal.c 2021-02-16 23:43:43.400895411 +0100 +@@ -222,9 +222,13 @@ + token_ptr = token + leading_space_len; + if (*token_ptr == '\0') + return 0; + tag_label = strsep(&token_ptr, "="); ++ if (token_ptr == NULL) ++ return -1; + tag_value = opendmarc_arcseal_strip_whitespace(token_ptr); ++ if (tag_value == NULL) ++ return -1; + + tag_code = opendmarc_arcseal_convert(as_tags, tag_label); + + switch (tag_code) --_----------=_1613526552206050--