summaryrefslogtreecommitdiff
path: root/mail-filter/opendmarc
diff options
context:
space:
mode:
Diffstat (limited to 'mail-filter/opendmarc')
-rw-r--r--mail-filter/opendmarc/Manifest2
-rw-r--r--mail-filter/opendmarc/files/opendmarc-1.3.2-multiple-From.patch35
-rw-r--r--mail-filter/opendmarc/opendmarc-1.3.2-r3.ebuild72
3 files changed, 109 insertions, 0 deletions
diff --git a/mail-filter/opendmarc/Manifest b/mail-filter/opendmarc/Manifest
index 8a1a43553b56..32bdbd401a2f 100644
--- a/mail-filter/opendmarc/Manifest
+++ b/mail-filter/opendmarc/Manifest
@@ -1,3 +1,4 @@
+AUX opendmarc-1.3.2-multiple-From.patch 1394 BLAKE2B 91b36a131ca9dca5e33f3a9610ab5c3ba17bf7f44f891d278f4c070629987a4177166c176692edd36dee184948811f727a9752e3c6adcbaf1822cfe9aa6d0c8e SHA512 068f58f25133fc6216c437ba9df5a44d5e7139c471f85d63bea81d7c930a56a2900239bc051cf2a3ed7f60fac939a0090bbef4a690c78457911e267293019d66
AUX opendmarc.confd 85 BLAKE2B 52cccfd8d194febc24453ad92bebf4358f92125cc4512e664e279f09ee0c44bffc4fa2c4c6dbbdfaf653576bcce821597cccb58fafdfae51b81e5ac149e20113 SHA512 7e5faeebbccaaafe42e6edda3a812b9954f19d71b4593cb2ab895dfeb26a8073e4aaeb2f5c626b1c35877d08ea00077b0507fe833e2838b10d83d5e0acfe966c
AUX opendmarc.initd 1509 BLAKE2B b1cde9546c95b51c8c395f10eddf85bcb2fd17fd8a537df523e04a71d241c0fad4a3d2e4c34c950d7b684be518368fe78538828b81627d647e3531177eabb85e SHA512 00c9901cf5b460e20d8010d4aedfd7c338c76d1053f9ddcd9d4aa2c183345e3b810d0bee1207ff9a7ad988577192c52470ca62c67130a981fa67e393d5c70129
AUX opendmarc.service 800 BLAKE2B 866b1aaa0c8570494ac56aaa9962821204a7a24437cdb8bec0343c716cfc1d3748a368a32ec314dfce7e4264188cfb1dff51212d60340d4be8e33394a85486f6 SHA512 b140dc3ac99ee7c3dcee80743d6c4295dec4ce5090ab9f560ffe35f9d5e63c7f5af871edcc759be462b8110706028c047cd05ae910a74ecba0436620d6b291bb
@@ -6,4 +7,5 @@ DIST opendmarc-1.3.2.tar.gz 593448 BLAKE2B 80f47a82e38c6cdc5791a695485262c50e936
EBUILD opendmarc-1.1.3.ebuild 768 BLAKE2B f9fcb819281ac3eadbfc22875fdfa0d663cd5c73c9e4221ade6af260ae0f3bfdbb5b396de53b297a7346120cbc36b06a698d6ae1cb3df0b916a1842944751d2e SHA512 d2f7ae5dd159315b6f96bea798796cd6ee9ff7a3fd07329c80e7764fc1e9d9cc35fab481dccb369dea0f1682590ecc17ec45448be514602626bd565dab527257
EBUILD opendmarc-1.3.2-r1.ebuild 1522 BLAKE2B d75259d5ce9c44e3f8ba59bba674d520d886d150843298dbef587843f842d7ca8c9b368140ab4daffba1c4222245254d818bc868d5e33c6c4e18b4618c280093 SHA512 27d9c2f088c7a5789837e49e8357a3f7100852e752786060d5eb00854cbf552bf3803364ecb181aae7c13b2e5e2abfeb21f8b11ca08e98259618e77eca170250
EBUILD opendmarc-1.3.2-r2.ebuild 1656 BLAKE2B ef0130e15886f9fdb8ee8fb5fedc85b7aa98b1660870ed597c453df7771e74a3eb1b2b59fc02235f37218260af5365e0fafa044c1a60dfe017a7d3f6f138496e SHA512 8a21ac243cdf5e2a37ae1716c62c23f94d2b8bd3c3ac68713831ab3ed02448f1a456985c16465940b410e264534a5acecdc9b1d54a17f9328973ac7ce319ebe8
+EBUILD opendmarc-1.3.2-r3.ebuild 1718 BLAKE2B d27b7e5625226546de9be5a81e2d7d69f50c88556c2127899336cb5bbb990a29b1808f487fbf5e3c773861cae824274ed1062ea723b324bef6a004f3f983c0df SHA512 58b97c608a4f3e6cdf5103ac25ed693362389001ce042569071b1ec2c504ef9db9192d31c1c9e107ca5e4d10b9f19bb8af276f28f779731ff7d5b367c3040004
MISC metadata.xml 512 BLAKE2B e837ed3fdef4432f4a6e208b57942ac6b74de558ad20fa978ce046d49147b4225720506c7191a07eeceeb85d6773d3f6d2ae5ca62c08fddb7126061bcfd46fdb SHA512 33b5347b487959b6412dd8a9e7babf0cedac3dd27eb6397dfc226de5d34b70c7e67e9b30dae231bdf743e4c18ffd2cfcd6df1af450e201cafa3c5105d5a889f0
diff --git a/mail-filter/opendmarc/files/opendmarc-1.3.2-multiple-From.patch b/mail-filter/opendmarc/files/opendmarc-1.3.2-multiple-From.patch
new file mode 100644
index 000000000000..28b2f852f39a
--- /dev/null
+++ b/mail-filter/opendmarc/files/opendmarc-1.3.2-multiple-From.patch
@@ -0,0 +1,35 @@
+From f6b615e345037408b88b2ffd1acd03239af8a858 Mon Sep 17 00:00:00 2001
+From: Marcin Seremak <panpilkarz@protonmail.com>
+Date: Tue, 30 Jul 2019 08:05:28 +0200
+Subject: [PATCH] Fix multiple addresses in From vulnerability
+
+---
+ libopendmarc/tests/test_finddomain.c | 1 +
+ opendmarc/opendmarc.c | 2 +-
+ 2 files changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/libopendmarc/tests/test_finddomain.c b/libopendmarc/tests/test_finddomain.c
+index 50cf405..8447463 100644
+--- a/libopendmarc/tests/test_finddomain.c
++++ b/libopendmarc/tests/test_finddomain.c
+@@ -23,6 +23,7 @@ main(int argc, char **argv)
+ /* 11 */ {"(,) joe@joe.com", "joe.com"},
+ /* 12 */ {"\"( bob@bob.com)\" joe@joe.com", "joe.com"},
+ /* 12 */ {"From: Davide D'Marco <user@blah.com>", "blah.com"},
++ /* 13 */ {"blah.com", "blah.com"},
+ {NULL, NULL},
+ };
+ u_char dbuf[256];
+diff --git a/opendmarc/opendmarc.c b/opendmarc/opendmarc.c
+index 419c15a..9b7fe3a 100644
+--- a/opendmarc/opendmarc.c
++++ b/opendmarc/opendmarc.c
+@@ -2193,7 +2193,7 @@ mlfi_eom(SMFICTX *ctx)
+ strncpy(dfc->mctx_fromdomain, domain, sizeof dfc->mctx_fromdomain - 1);
+
+ ostatus = opendmarc_policy_store_from_domain(cc->cctx_dmarc,
+- from->hdr_value);
++ dfc->mctx_fromdomain);
+ if (ostatus != DMARC_PARSE_OKAY)
+ {
+ if (conf->conf_dolog)
diff --git a/mail-filter/opendmarc/opendmarc-1.3.2-r3.ebuild b/mail-filter/opendmarc/opendmarc-1.3.2-r3.ebuild
new file mode 100644
index 000000000000..2482aed4e1f8
--- /dev/null
+++ b/mail-filter/opendmarc/opendmarc-1.3.2-r3.ebuild
@@ -0,0 +1,72 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit user multilib systemd
+
+DESCRIPTION="Open source DMARC implementation "
+HOMEPAGE="http://www.trusteddomain.org/opendmarc/"
+SRC_URI="mirror://sourceforge/opendmarc/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="spf +reports static-libs"
+
+DEPEND="reports? ( dev-perl/DBI )
+ || ( mail-filter/libmilter mail-mta/sendmail )"
+RDEPEND="${DEPEND}
+ reports? (
+ dev-perl/DBD-mysql
+ dev-perl/HTTP-Message
+ dev-perl/Switch
+ )
+ spf? ( mail-filter/libspf2 )"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-multiple-From.patch
+)
+
+pkg_setup() {
+ enewgroup milter
+ enewuser milter -1 -1 /var/lib/milter milter
+}
+
+src_prepare() {
+ default
+ if use !reports ; then
+ sed -i -e '/^SUBDIRS =/s/reports//' Makefile.in || die
+ fi
+}
+
+src_configure() {
+ econf \
+ --docdir="${EPREFIX}"/usr/share/doc/${PF} \
+ --htmldir="${EPREFIX}"/usr/share/doc/${PF}/html \
+ $(use_with spf) \
+ $(use_with spf spf2-include "${EPREFIX}"/usr/include/spf2) \
+ $(use_with spf spf2-lib "${EPREFIX}"/usr/$(get_libdir)) \
+ $(use_enable static-libs static)
+}
+
+src_install() {
+ default
+
+ use static-libs || rm -f "${ED}"/usr/$(get_libdir)/*.la
+
+ newinitd "${FILESDIR}"/opendmarc.initd opendmarc
+ newconfd "${FILESDIR}"/opendmarc.confd opendmarc
+ systemd_dounit "${FILESDIR}/${PN}.service"
+
+ dodir /etc/opendmarc
+
+ # create config file
+ sed \
+ -e 's:^# UserID .*$:UserID milter:' \
+ -e "s:^# PidFile .*:PidFile ${EPREFIX}/var/run/opendmarc/opendmarc.pid:" \
+ -e '/^# Socket /s:^# ::' \
+ "${S}"/opendmarc/opendmarc.conf.sample \
+ > "${ED}"/etc/opendmarc/opendmarc.conf \
+ || die
+}