Skip to content

Commit

Permalink
Fix DKIM canonization of headers formatted as Name:\r\n\tValue
Browse files Browse the repository at this point in the history
Submitted upstream as
trusteddomainproject/OpenDKIM#119
  • Loading branch information
manu committed Mar 19, 2021
1 parent 05eeaf1 commit 81e324d
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
4 changes: 2 additions & 2 deletions mail/opendkim/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# $NetBSD: Makefile,v 1.33 2020/08/31 18:09:58 wiz Exp $
# $NetBSD: Makefile,v 1.34 2021/03/19 09:50:21 manu Exp $

DISTNAME= opendkim-2.10.3
PKGREVISION= 6
PKGREVISION= 7
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=opendkim/}

Expand Down
3 changes: 2 additions & 1 deletion mail/opendkim/distinfo
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
$NetBSD: distinfo,v 1.20 2020/01/07 13:35:13 sborrill Exp $
$NetBSD: distinfo,v 1.21 2021/03/19 09:50:21 manu Exp $

SHA1 (opendkim-2.10.3.tar.gz) = 4e9b966860bcfbca6441ed84a95bbe762fff69f4
RMD160 (opendkim-2.10.3.tar.gz) = c6553757ae9675434e647f3cc1e6357bc60c7d2a
SHA512 (opendkim-2.10.3.tar.gz) = 97923e533d072c07ae4d16a46cbed95ee799aa50f19468d8bc6d1dc534025a8616c3b4b68b5842bc899b509349a2c9a67312d574a726b048c0ea46dd4fcc45d8
Size (opendkim-2.10.3.tar.gz) = 1210224 bytes
SHA1 (patch-configure.ac) = c9ae182ed2c5c2ec3018fe4c6066ed7fa0d3686f
SHA1 (patch-libopendkim_dkim-canon.c) = 82dc322f86981feddc2ad0100b33ce1eca7435d6
SHA1 (patch-opendkim_opendkim-crypto.c) = d7d08fda3dba5bf9cb834123218b1e89b78878e5
21 changes: 21 additions & 0 deletions mail/opendkim/patches/patch-libopendkim_dkim-canon.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
$NetBSD: patch-libopendkim_dkim-canon.c,v 1.1 2021/03/19 09:50:21 manu Exp $

--- libopendkim/dkim-canon.c.orig 2021-03-18 09:50:14.195951232 +0100
+++ libopendkim/dkim-canon.c 2021-03-19 09:49:52.141301747 +0100
@@ -386,10 +386,14 @@
break;
}
}

- /* skip all spaces before first word */
- while (*p != '\0' && DKIM_ISWSP(*p))
+ /*
+ * skip all spaces before first word
+ * we also need to skip CRLF for long header formatted as
+ * Header-Name:\r\n\tHeader-value
+ */
+ while (*p != '\0' && DKIM_ISLWSP(*p))
p++;

space = FALSE; /* just saw a space */

0 comments on commit 81e324d

Please sign in to comment.