diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /mail-filter/gld |
reinit the tree, so we can have metadata
Diffstat (limited to 'mail-filter/gld')
-rw-r--r-- | mail-filter/gld/Manifest | 8 | ||||
-rw-r--r-- | mail-filter/gld/files/gld.rc | 22 | ||||
-rw-r--r-- | mail-filter/gld/files/tables.sql | 15 | ||||
-rw-r--r-- | mail-filter/gld/gld-1.7-r2.ebuild | 76 | ||||
-rw-r--r-- | mail-filter/gld/gld-1.7-r3.ebuild | 77 | ||||
-rw-r--r-- | mail-filter/gld/metadata.xml | 8 |
6 files changed, 206 insertions, 0 deletions
diff --git a/mail-filter/gld/Manifest b/mail-filter/gld/Manifest new file mode 100644 index 000000000000..8c0cb9973067 --- /dev/null +++ b/mail-filter/gld/Manifest @@ -0,0 +1,8 @@ +AUX gld.rc 443 SHA256 84aa6b2e733c8b088ef5d82fbefd1fe6385d3db375962731b7cdafa8095b8652 SHA512 08c2d5db9e607bf583f0f7d4cfb0a8bbef68d19ae068f4e899cc620b199e2cea742e84d98ea79d14d09fc1f4635834140b8ae4c9f71f90d63c6b2fc3debd5ee6 WHIRLPOOL e7bad5619973fe88aac7ce46995fa462758c9a964c7c95df4da3cf2d9e7f0d9a1f41fe2f6f8511606a839cb95050071b7d57a4fc1a4372c1653fe506c1825de3 +AUX tables.sql 1141 SHA256 1432a8b52c55299b17cd0aeaa94076aef65f04db66f02554e83a862c298bfc5d SHA512 4501ffb273f7064f1bbb56dd6d3f433532924da52c9007d089c57a27aff9cfda2f4b0a59844d0c8e5ff8ce9218f66316914a5af2c801eacba489d003806bb56a WHIRLPOOL d2278b837ecfe255681bafd5b7ff6693218046be2433f48fb143612d18a4b8df8b0f933cadd0ff67d1c6279f04033c030dca3abddd15ecbe4f3be3c82001c365 +DIST gld-1.7.tgz 40241 SHA256 c0776f6841afa73b6579e355522d79fd15467de2936f1a4464265e6415cae14b SHA512 68bbfd03295c2895608f8404ca1a0942c53003af66d70fda0e2515717ab8e6836f2b609942633b6d70a15b49338a887b5b1082ed1d9bc7c2c0aa3a7735abb13e WHIRLPOOL 815bbf2dc565695ca14eeee5821477e35c5d804c00f33c5e988462b3e6f8f3550c24f56cf6bc77ec9378d7a0cbdc1ba76cd47ae27a40e1cdcc2b3e6ffdd06785 +EBUILD gld-1.7-r2.ebuild 1875 SHA256 92a9119394351887a3dca098deef3056c5cc8fd5999fd7393d344aeb12032f40 SHA512 16e11bd850678ef303a81fab386870bc54d9a6341f66ac55e8a84b3d0d86cf9f0fccb3aec9cd39c0eff906eac976e554c055e91c197af8f91eadb35414b931ab WHIRLPOOL f90a87668ce0e7c26c896310dee49d504f38a04318968367d79662661c13af41b1b0070b1e9dae9fa30da316cf54d4ffcb4de77cf703fb73bd03f2e09ae3ef7a +EBUILD gld-1.7-r3.ebuild 1931 SHA256 4c5c3b1e4ab90d6f204652008d3a880b326ac035f10e270854a6f9a7802ac0ce SHA512 fe2aa744f937f40f8be53c48a902f5c4711cf5f8ea7261a5bfaea30d39c2bec960cd4d74d3404de0a93ebf2ce9185f346e61b40e18728d876698964069fee833 WHIRLPOOL 20afc7291f1c8fc50d421a16b2a0dd2cf14da54c240193af46ee555a6a29b8562bc06c7ddef5318784df9418ee5b876fc878b8dc597d23d5c36066e6d863279a +MISC ChangeLog 2740 SHA256 3df6b9e788e665063551dcf2a6019778b2cacf2738b845781e4f4edde28ae67f SHA512 29202656269897696c533d52a79896c23f67c59561259664ec05f7411b227a06f73b8173267cb8bbc62490c8ead3d04b23f772b7fe1810fe96e6044fa3d0afca WHIRLPOOL 6ccdd2ef1f6a0cf493cb620d8601cfb94f43e6dd9cf80157a224689769702653324bca3389f91197dc1b66874844d641ea80f89c4acef4fa717018606fdececa +MISC ChangeLog-2015 7891 SHA256 930daf776132ea9d7d19990134ba8388ae0acb22530d01d50976689b74d086e7 SHA512 3698348c4a7c7522c786332ab116780770fe9e786e19482d6437e929f62e533e6d18b0e882064285918e2a37ebcd5326ba78c195f70ef0fd412510e3e4a45b91 WHIRLPOOL d2b7c9aadf8e26c06fc14c43a9844b08e44f9e28d66d8af1d20b9a89d81bc42195b690778b89138015384f05f00457bd2321b15afb400ca3a8061fe56ac9a026 +MISC metadata.xml 240 SHA256 f0e0bb7a24c4b1ff6b6a8a3e9315245c298499c03fbda429c0f775ec6a5396af SHA512 97824dbce22630efb21e647b55212b7a8a19d8e38b5bf05cb0b8078530bbbaaf4dc91284e2a11beab7dfcfb779df82b87b49d11a746c7a4f6dc71f2fda8942db WHIRLPOOL a7adfcb24489ae67a43a59d8350a70b20874fb03de95681c5b516a741d95422560a433f641de5a7222cf5d3500333e215055ec0cb3844e7abc6d6a836de97357 diff --git a/mail-filter/gld/files/gld.rc b/mail-filter/gld/files/gld.rc new file mode 100644 index 000000000000..7df142e1433d --- /dev/null +++ b/mail-filter/gld/files/gld.rc @@ -0,0 +1,22 @@ +#!/sbin/openrc-run +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +depend() { + need net # in case mysql daemon is not local + use dns mysql postgresql + before postfix + provide postfix_greylist +} + +start() { + ebegin "Starting gld" + start-stop-daemon --start --quiet --exec /usr/bin/gld + eend $? +} + +stop() { + ebegin "Stopping gld" + start-stop-daemon --stop --quiet --name gld + eend $? +} diff --git a/mail-filter/gld/files/tables.sql b/mail-filter/gld/files/tables.sql new file mode 100644 index 000000000000..245e9a059e36 --- /dev/null +++ b/mail-filter/gld/files/tables.sql @@ -0,0 +1,15 @@ +CREATE TABLE `greylist` ( + `ip` CHAR( 39 ) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL COMMENT 'IP of Sending Host', + `sender` CHAR( 242 ) CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL COMMENT 'Address of Sender', + `recipient` CHAR( 242 ) CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL COMMENT 'Address of Recipient', + `first` INT( 11 ) NOT NULL DEFAULT '0' COMMENT 'Date, when this Sender has first been seen', + `last` INT( 11 ) NOT NULL DEFAULT '0' COMMENT 'Date, when this sender has last been seen', + `n` INT( 11 ) NOT NULL DEFAULT '0' COMMENT 'Sequence number', + PRIMARY KEY ( `ip` , `sender` , `recipient` ) +) ENGINE = MYISAM CHARACTER SET latin1 COLLATE latin1_general_ci COMMENT = 'GLD Greylist Table'; + +CREATE TABLE `whitelist` ( + `mail` CHAR( 242 ) CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL COMMENT 'Adress which is whitelisted', + `comment` CHAR( 242 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT 'A comment, about why this adress is whitelisted', + PRIMARY KEY ( `mail` ) +) ENGINE = MYISAM CHARACTER SET latin1 COLLATE latin1_general_ci COMMENT = 'GLD Whitelist Table'; diff --git a/mail-filter/gld/gld-1.7-r2.ebuild b/mail-filter/gld/gld-1.7-r2.ebuild new file mode 100644 index 000000000000..55c7f21f081d --- /dev/null +++ b/mail-filter/gld/gld-1.7-r2.ebuild @@ -0,0 +1,76 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="4" + +inherit toolchain-funcs + +DESCRIPTION="A standalone anti-spam greylisting algorithm on top of Postfix" +HOMEPAGE="http://www.gasmi.net/gld.html" +SRC_URI="http://www.gasmi.net/down/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="postgres" +# Not adding a mysql USE flag. The package defaults to it, so we will too. +DEPEND="sys-libs/zlib + >=dev-libs/openssl-0.9.6 + postgres? ( dev-db/postgresql[server] ) + !postgres? ( virtual/mysql )" +RDEPEND="${DEPEND}" + +src_prepare() { + sed -i gld.conf \ + -e 's:^LOOPBACKONLY=.*:LOOPBACKONLY=1:' \ + -e 's:^#USER=.*:USER=nobody:' \ + -e 's:^#GROUP=.*:GROUP=nobody:' \ + || die "sed gld.conf failed" + + sed -i Makefile.in \ + -e '/ -c /{s|-O2|$(CFLAGS)|g}' \ + -e '/ -o /{s|-O2|$(CFLAGS) $(LDFLAGS)|g}' \ + -e '/strip/d' \ + || die "sed Makefile.in failed" + + sed -i tables.{my,pg}sql \ + -e '/ip char/s/16/39/' \ + || die "sed sql tables failed" +} + +src_configure() { + tc-export CC + # It's kind of weird. $(use_with postgres pgsql) won't work if you don't + # use it... + if use postgres ; then + myconf="${myconf} --with-pgsql" + fi + + econf ${myconf} +} + +src_install() { + dobin gld + + insinto /etc + newins gld.conf gld.conf.example + + dodoc HISTORY README* + + insinto /usr/share/${PN}/sql + doins *.pgsql *-whitelist.sql "${FILESDIR}"/tables.sql + + newinitd "${FILESDIR}"/gld.rc gld +} + +pkg_preinst() { + elog "Please read the README file in /usr/share/doc/${PF} for" + elog "details on how to setup gld." + elog + elog "The sql files have been installed to /usr/share/${PN}/sql." + if [[ $REPLACING_VERSIONS == "1.7-r1" ]]; then + elog "You might want to use the ALTER_TABLE command to change the" + elog "ip field width to 39 chars to accomodate ipv6 addresses." + elog "Please see your sql server documentation." + fi +} diff --git a/mail-filter/gld/gld-1.7-r3.ebuild b/mail-filter/gld/gld-1.7-r3.ebuild new file mode 100644 index 000000000000..24fe380c91f3 --- /dev/null +++ b/mail-filter/gld/gld-1.7-r3.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +inherit toolchain-funcs + +DESCRIPTION="A standalone anti-spam greylisting algorithm on top of Postfix" +HOMEPAGE="http://www.gasmi.net/gld.html" +SRC_URI="http://www.gasmi.net/down/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" +IUSE="libressl postgres" +# Not adding a mysql USE flag. The package defaults to it, so we will too. +DEPEND="sys-libs/zlib + !libressl? ( dev-libs/openssl:0 ) + libressl? ( dev-libs/libressl ) + !postgres? ( virtual/mysql ) + postgres? ( dev-db/postgresql:*[server] )" +RDEPEND="${DEPEND}" + +src_prepare() { + sed -i gld.conf \ + -e 's:^LOOPBACKONLY=.*:LOOPBACKONLY=1:' \ + -e 's:^#USER=.*:USER=nobody:' \ + -e 's:^#GROUP=.*:GROUP=nobody:' \ + || die "sed gld.conf failed" + + sed -i Makefile.in \ + -e '/ -c /{s|-O2|$(CFLAGS)|g}' \ + -e '/ -o /{s|-O2|$(CFLAGS) $(LDFLAGS)|g}' \ + -e '/strip/d' \ + || die "sed Makefile.in failed" + + sed -i tables.{my,pg}sql \ + -e '/ip char/s/16/39/' \ + || die "sed sql tables failed" +} + +src_configure() { + tc-export CC + # It's kind of weird. $(use_with postgres pgsql) won't work if you don't + # use it... + if use postgres ; then + myconf="${myconf} --with-pgsql" + fi + + econf ${myconf} +} + +src_install() { + dobin gld + + insinto /etc + newins gld.conf gld.conf.example + + dodoc HISTORY README* + + insinto /usr/share/${PN}/sql + doins *.pgsql *-whitelist.sql "${FILESDIR}"/tables.sql + + newinitd "${FILESDIR}"/gld.rc gld +} + +pkg_preinst() { + elog "Please read the README file in /usr/share/doc/${PF} for" + elog "details on how to setup gld." + elog + elog "The sql files have been installed to /usr/share/${PN}/sql." + if [[ $REPLACING_VERSIONS == "1.7-r1" ]]; then + elog "You might want to use the ALTER_TABLE command to change the" + elog "ip field width to 39 chars to accomodate ipv6 addresses." + elog "Please see your sql server documentation." + fi +} diff --git a/mail-filter/gld/metadata.xml b/mail-filter/gld/metadata.xml new file mode 100644 index 000000000000..9a6d80e5da48 --- /dev/null +++ b/mail-filter/gld/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="project"> + <email>net-mail@gentoo.org</email> + <name>Net-Mail</name> +</maintainer> +</pkgmetadata> |