summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2007-10-17 08:47:41 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2007-10-17 08:47:41 +0000
commit236832f403b4f754669487a6a8ce73d90003173a (patch)
tree8ae145851cab7e672bc5059f50401ad1b7343e60 /dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing
parentanother slotmove for gtksourceview, should be fine this time (diff)
downloadgentoo-2-236832f403b4f754669487a6a8ce73d90003173a.tar.gz
gentoo-2-236832f403b4f754669487a6a8ce73d90003173a.tar.bz2
gentoo-2-236832f403b4f754669487a6a8ce73d90003173a.zip
Initial commit. Ebuild by Robin H. Johnnson <robbat2@gentoo.org>.
(Portage version: 2.1.3.14)
Diffstat (limited to 'dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing')
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/ChangeLog12
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild44
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Manifest28
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/24_google_safebrowsing.cf18
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.033
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/init_google_safebrowsing.pre3
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/update_google_safebrowsing.sh17
-rw-r--r--dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/metadata.xml9
8 files changed, 134 insertions, 0 deletions
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/ChangeLog b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/ChangeLog
new file mode 100644
index 000000000000..4bba7889e76a
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/ChangeLog
@@ -0,0 +1,12 @@
+# ChangeLog for dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing
+# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/ChangeLog,v 1.1 2007/10/17 08:47:40 robbat2 Exp $
+
+*Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03 (17 Oct 2007)
+
+ 17 Oct 2007; Robin H. Johnson <robbat2@gentoo.org>
+ +files/24_google_safebrowsing.cf, +files/init_google_safebrowsing.pre,
+ +files/update_google_safebrowsing.sh, +metadata.xml,
+ +Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild:
+ Initial commit. Ebuild by Robin H. Johnnson <robbat2@gentoo.org>.
+
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild
new file mode 100644
index 000000000000..1788a5787d70
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild,v 1.1 2007/10/17 08:47:40 robbat2 Exp $
+
+MODULE_AUTHOR="DANBORN"
+inherit perl-module
+
+DESCRIPTION="SpamAssassin plugin to score mail based on Google blocklists."
+
+IUSE="test"
+
+SLOT="0"
+LICENSE="Apache-2.0"
+KEYWORDS="~amd64 ~x86 ~ppc"
+RDEPEND="dev-perl/Net-Google-SafeBrowsing-Blocklist
+ dev-perl/Net-Google-SafeBrowsing-UpdateRequest
+ mail-filter/spamassassin"
+DEPEND="${RDEPEND}
+ test? ( dev-perl/Test-Pod )"
+
+SRC_TEST="do"
+
+src_install() {
+ perl-module_src_install
+ insinto /etc/mail/spamassassin
+ doins "${FILESDIR}"/init_google_safebrowsing.pre
+ doins "${FILESDIR}"/24_google_safebrowsing.cf
+ exeinto /etc/cron.d/
+ doexe "${FILESDIR}"/update_google_safebrowsing.sh
+ keepdir /var/lib/spamassassin/google_safebrowsing/
+}
+
+pkg_postinst() {
+ elog "To use this package:"
+ elog "1. You MUST apply for a free apikey at:"
+ elog " http://code.google.com/apis/safebrowsing/key_signup.html"
+ elog "2. Place the key into /etc/mail/spamassassin/24_google_safebrowsing.cf"
+ elog "3. Manually run the cronjob /etc/cron.d/update_google_safebrowsing.sh"
+ elog "4. Configure the cronjob to run every 25-30 minutes. "
+ elog " Don't choose round numbers!"
+ elog "5. Enable the plugin by uncommenting the loadplugin entry in"
+ elog " /etc/mail/spamassassin/init_google_safebrowsing.pre"
+ elog "6. Restart spamd"
+}
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Manifest b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Manifest
new file mode 100644
index 000000000000..8c6a577854b5
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/Manifest
@@ -0,0 +1,28 @@
+AUX 24_google_safebrowsing.cf 698 RMD160 a4813aa90b7baecee7850436513e021e06c6d9b6 SHA1 bf90a80a6c7c93ec9af74f481978c9cb4907758e SHA256 4012ef68f1d14048b24a61c32f9e3ee912a520b549c85c19b4ad8fc8f17904b8
+MD5 5d36b578ad1978d20fc9570830ab4732 files/24_google_safebrowsing.cf 698
+RMD160 a4813aa90b7baecee7850436513e021e06c6d9b6 files/24_google_safebrowsing.cf 698
+SHA256 4012ef68f1d14048b24a61c32f9e3ee912a520b549c85c19b4ad8fc8f17904b8 files/24_google_safebrowsing.cf 698
+AUX init_google_safebrowsing.pre 266 RMD160 6c14069d83b6dd88b42a3d26f75fa7ab3f257e14 SHA1 9698e0d9a08be400a0ce2fe0fd588a75a369d422 SHA256 cd1b112c672cd7e49a5b4e8dc007b646ab84e090c30bc16d78e0ee2f0723fe8d
+MD5 dfdb1d27087e50d70c3735f4487aa3fc files/init_google_safebrowsing.pre 266
+RMD160 6c14069d83b6dd88b42a3d26f75fa7ab3f257e14 files/init_google_safebrowsing.pre 266
+SHA256 cd1b112c672cd7e49a5b4e8dc007b646ab84e090c30bc16d78e0ee2f0723fe8d files/init_google_safebrowsing.pre 266
+AUX update_google_safebrowsing.sh 877 RMD160 a388535863590236803408e7d58bc6ee69cc145c SHA1 ae8311304043fdfa561a8818bc14d3b63cb7f37c SHA256 0a50b46e805227678f7f35aad5c31b5e2090e0ee692609455b4b2bbdb8796e9c
+MD5 dc7c02a4d60a954b72e039aec8cd9ce7 files/update_google_safebrowsing.sh 877
+RMD160 a388535863590236803408e7d58bc6ee69cc145c files/update_google_safebrowsing.sh 877
+SHA256 0a50b46e805227678f7f35aad5c31b5e2090e0ee692609455b4b2bbdb8796e9c files/update_google_safebrowsing.sh 877
+DIST Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.tar.gz 4253 RMD160 3169cc45221608abf6a79f8208776e8bc01390f1 SHA1 66f029c5bde1d7c8a9180b7eca04c56ea1d55e77 SHA256 39d1ddc4f539411a1c34cd96f6d0a84b4f4651c2aa08b7e596a09d4b1b718fa7
+EBUILD Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild 1499 RMD160 f22e3b40cdfc18adc729e6c92d7a4458b34f9483 SHA1 8fc58d5a3a8193ed40cab71a27292a2beac7b978 SHA256 6c608c6ace5b424e3c49d4e491e7f7ce0980fddb8c061256e11d56bc21cd62ed
+MD5 7897d10fbe07f7f076ab971ff968e3c5 Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild 1499
+RMD160 f22e3b40cdfc18adc729e6c92d7a4458b34f9483 Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild 1499
+SHA256 6c608c6ace5b424e3c49d4e491e7f7ce0980fddb8c061256e11d56bc21cd62ed Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.ebuild 1499
+MISC ChangeLog 528 RMD160 fb70627809ea07f7edc71f2fc997c051ce1a1bf6 SHA1 7963eceb66b81e48237c7416e2a9f0c8c327e302 SHA256 d4390093abe29bb2e98ce16df0df996ff9b250d442216658a28f28da8dd23398
+MD5 52382aa653f577998bbdab22180f5e99 ChangeLog 528
+RMD160 fb70627809ea07f7edc71f2fc997c051ce1a1bf6 ChangeLog 528
+SHA256 d4390093abe29bb2e98ce16df0df996ff9b250d442216658a28f28da8dd23398 ChangeLog 528
+MISC metadata.xml 271 RMD160 33d1e6d38b3ecde19f2a3a873476e4fc03fd0a41 SHA1 1b49b2ba691f42cbf4f86231769f560b7232453a SHA256 0670df6d1cf19fc80b5a9b574234d0d260f42c2c1889155d94922b0d63976ac2
+MD5 2df9d8023d665f58666b098375350645 metadata.xml 271
+RMD160 33d1e6d38b3ecde19f2a3a873476e4fc03fd0a41 metadata.xml 271
+SHA256 0670df6d1cf19fc80b5a9b574234d0d260f42c2c1889155d94922b0d63976ac2 metadata.xml 271
+MD5 82cde717ee651f19497d9efb5d9fd9ef files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03 340
+RMD160 8a7fa952e99a4a1db2e918a9227354d2951a62f3 files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03 340
+SHA256 8186bfc483bbda2d2d16288717e1b8c391b35bb68b1882d5cc8752c6de3db540 files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03 340
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/24_google_safebrowsing.cf b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/24_google_safebrowsing.cf
new file mode 100644
index 000000000000..82098023bf80
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/24_google_safebrowsing.cf
@@ -0,0 +1,18 @@
+# $Header: /var/cvsroot/gentoo-x86/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/24_google_safebrowsing.cf,v 1.1 2007/10/17 08:47:41 robbat2 Exp $
+ifplugin Mail::SpamAssassin::Plugin::GoogleSafeBrowsing
+
+# Replace DEADBEEF with your API key
+# from http://code.google.com/apis/safebrowsing/key_signup.html
+google_safebrowsing_apikey DEADBEEF
+
+# Change these scores if you want
+google_safebrowsing_blocklist goog-black-hash 0.2
+google_safebrowsing_blocklist goog-malware-hash 0.1
+
+# Do not change these two lines!
+body GOOGLE_SAFEBROWSING eval:check_google_safebrowsing_blocklists()
+google_safebrowsing_dir /var/lib/spamassassin/google_safebrowsing/
+
+endif # Mail::SpamAssassin::Plugin::GoogleSafeBrowsing
+
+# vim: ft=conf:
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03 b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03
new file mode 100644
index 000000000000..babd02b00872
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/digest-Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03
@@ -0,0 +1,3 @@
+MD5 76b25e037d7b293631aa88ceb59e90be Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.tar.gz 4253
+RMD160 3169cc45221608abf6a79f8208776e8bc01390f1 Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.tar.gz 4253
+SHA256 39d1ddc4f539411a1c34cd96f6d0a84b4f4651c2aa08b7e596a09d4b1b718fa7 Mail-SpamAssassin-Plugin-GoogleSafeBrowsing-1.03.tar.gz 4253
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/init_google_safebrowsing.pre b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/init_google_safebrowsing.pre
new file mode 100644
index 000000000000..be174ff5eab2
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/init_google_safebrowsing.pre
@@ -0,0 +1,3 @@
+# $Header: /var/cvsroot/gentoo-x86/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/init_google_safebrowsing.pre,v 1.1 2007/10/17 08:47:41 robbat2 Exp $
+# You need to uncomment this after you have an API key and the cronjob is active!
+#loadplugin Mail::SpamAssassin::Plugin::GoogleSafeBrowsing
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/update_google_safebrowsing.sh b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/update_google_safebrowsing.sh
new file mode 100644
index 000000000000..72b89fcabce9
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/update_google_safebrowsing.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/files/update_google_safebrowsing.sh,v 1.1 2007/10/17 08:47:41 robbat2 Exp $
+# This cron script updates the Google SafeBrowsing lists for the use of the
+# Mail-SpamAssassin-Plugin-GoogleSafeBrowsing plugin.
+# It should be run every 25-30 minutes! http://code.google.com/apis/safebrowsing/developers_guide.html#AcceptableUsage
+CONFFILE="/etc/mail/spamassassin/24_google_safebrowsing.cf"
+OUTDIR="$(awk '/^google_safebrowsing_dir/{print $2}' "${CONFFILE}")"
+APIKEY="$(awk '/^google_safebrowsing_apikey/{print $2}' "${CONFFILE}")"
+LISTS="$(awk '/^google_safebrowsing_blocklist/{printf "%s ",$2}' "${CONFFILE}")"
+# Wait a little while, to avoid hammering the server
+sleep $(($RANDOM % 120))
+# Use LISTS unquoted!
+for LIST in ${LISTS}; do
+ blocklist_updater --apikey "$APIKEY" --blocklist ${LIST} --dbfile ${OUTDIR}/${LIST}-db
+done
diff --git a/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/metadata.xml b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/metadata.xml
new file mode 100644
index 000000000000..8ac7a1c994df
--- /dev/null
+++ b/dev-perl/Mail-SpamAssassin-Plugin-GoogleSafeBrowsing/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>perl</herd>
+ <maintainer>
+ <email>robbat2@gentoo.org</email>
+ <description>Primary Maintainer</description>
+ </maintainer>
+</pkgmetadata>