pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/mail/qmail-spp-spf Initial import of qmail-spp-spf, an...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/a054c32c6b13
branches:  trunk
changeset: 326406:a054c32c6b13
user:      schmonz <schmonz%pkgsrc.org@localhost>
date:      Thu Dec 06 00:07:33 2018 +0000

description:
Initial import of qmail-spp-spf, an implementation of SPF as a qmail-spp
module. It requires libspf2.

diffstat:

 mail/qmail-spp-spf/DESCR                                  |   2 +
 mail/qmail-spp-spf/Makefile                               |  31 ++++++++++++
 mail/qmail-spp-spf/PLIST                                  |   3 +
 mail/qmail-spp-spf/distinfo                               |   7 ++
 mail/qmail-spp-spf/patches/patch-qmail-spp-spf-20091020.c |  37 +++++++++++++++
 5 files changed, 80 insertions(+), 0 deletions(-)

diffs (100 lines):

diff -r 88fe67006185 -r a054c32c6b13 mail/qmail-spp-spf/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/qmail-spp-spf/DESCR  Thu Dec 06 00:07:33 2018 +0000
@@ -0,0 +1,2 @@
+This is an implementation of SPF as a qmail-spp module. It
+requires libspf2.
diff -r 88fe67006185 -r a054c32c6b13 mail/qmail-spp-spf/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/qmail-spp-spf/Makefile       Thu Dec 06 00:07:33 2018 +0000
@@ -0,0 +1,31 @@
+# $NetBSD: Makefile,v 1.1 2018/12/06 00:07:33 schmonz Exp $
+
+DISTNAME=              qmail-spp-spf-20091020.c
+PKGNAME=               ${DISTNAME:S/.c$//}
+CATEGORIES=            mail
+MASTER_SITES=          ${HOMEPAGE}
+EXTRACT_SUFX=          # none
+
+MAINTAINER=            schmonz%NetBSD.org@localhost
+HOMEPAGE=              https://www.caputo.com/foss/qmail-spp-spf/
+COMMENT=               Plugin for qmail-spp that performs SPF lookups
+LICENSE=               gnu-gpl-v2
+
+WRKSRC=                        ${WRKDIR}
+
+LDFLAGS.SunOS+=                -lnsl
+
+INSTALLATION_DIRS=     bin share/doc/${PKGBASE}
+
+do-build:
+       cd ${WRKSRC} && \
+       ${CC} ${CFLAGS} ${LDFLAGS} -lspf2 -o ${PKGBASE} ${DISTNAME}
+
+do-install:
+       ${INSTALL_PROGRAM} ${WRKSRC}/${PKGBASE} \
+               ${DESTDIR}${PREFIX}/bin/${PKGBASE}
+       ${INSTALL_DATA} ${WRKSRC}/${DISTNAME} \
+               ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}/README
+
+.include "../../mail/libspf2/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 88fe67006185 -r a054c32c6b13 mail/qmail-spp-spf/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/qmail-spp-spf/PLIST  Thu Dec 06 00:07:33 2018 +0000
@@ -0,0 +1,3 @@
+@comment $NetBSD: PLIST,v 1.1 2018/12/06 00:07:33 schmonz Exp $
+bin/qmail-spp-spf
+share/doc/qmail-spp-spf/README
diff -r 88fe67006185 -r a054c32c6b13 mail/qmail-spp-spf/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/qmail-spp-spf/distinfo       Thu Dec 06 00:07:33 2018 +0000
@@ -0,0 +1,7 @@
+$NetBSD: distinfo,v 1.1 2018/12/06 00:07:33 schmonz Exp $
+
+SHA1 (qmail-spp-spf-20091020.c) = 3aca350c027345126cc631ffecdbbb697c9c4c45
+RMD160 (qmail-spp-spf-20091020.c) = 874bf86fdd4ddb671ad0827e1bf56cdda1deaec9
+SHA512 (qmail-spp-spf-20091020.c) = ffccb601ffa6d9088fc2530024412628a69f57f6448b78fa0d37d4aecc4a886360682bcaf49391f94edeb56b1cbf576122183461f25d4a661ce16e1eeeed8bf0
+Size (qmail-spp-spf-20091020.c) = 14965 bytes
+SHA1 (patch-qmail-spp-spf-20091020.c) = 6148fb9f1f56b6e154890a3de10877572e139add
diff -r 88fe67006185 -r a054c32c6b13 mail/qmail-spp-spf/patches/patch-qmail-spp-spf-20091020.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/qmail-spp-spf/patches/patch-qmail-spp-spf-20091020.c Thu Dec 06 00:07:33 2018 +0000
@@ -0,0 +1,37 @@
+$NetBSD: patch-qmail-spp-spf-20091020.c,v 1.1 2018/12/06 00:07:33 schmonz Exp $
+
+Adjust include path and IPv6 struct access.
+
+--- qmail-spp-spf-20091020.c.orig      2018-12-05 23:27:39.000000000 +0000
++++ qmail-spp-spf-20091020.c
+@@ -150,7 +150,7 @@
+ #include <time.h>
+ #include <arpa/inet.h>
+ #include <unistd.h>
+-#include "spf.h"
++#include "spf2/spf.h"
+ 
+ #define LOG "qmail-spp-spf: "
+ #define LOGR "qmail-spp-spf:%s: "
+@@ -263,10 +263,17 @@ int random_ip_passes(SPF_request_t *spf_
+     }
+   else
+     {
+-      addr6.s6_addr32[0] = random();
+-      addr6.s6_addr32[1] = random();
+-      addr6.s6_addr32[2] = random();
+-      addr6.s6_addr32[3] = random();
++#if defined (__linux__)
++# define v6member s6_addr32
++#elif (defined (sun) || defined (__sun)) && (defined (__SVR4) || defined(__svr4__))
++# define v6member _S6_un._S6_u32
++#else
++# define v6member __u6_addr.__u6_addr32
++#endif
++      addr6.v6member[0] = random();
++      addr6.v6member[1] = random();
++      addr6.v6member[2] = random();
++      addr6.v6member[3] = random();
+ 
+       if (SPF_request_set_ipv6(spf_request, addr6))
+       {



Home | Main Index | Thread Index | Old Index