summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /mail-filter/mailfilter
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'mail-filter/mailfilter')
-rw-r--r--mail-filter/mailfilter/Manifest1
-rw-r--r--mail-filter/mailfilter/files/0.8.2-gcc44.patch26
-rw-r--r--mail-filter/mailfilter/files/0.8.2-gcc46.patch20
-rw-r--r--mail-filter/mailfilter/files/0.8.2-openssl-1.patch16
-rw-r--r--mail-filter/mailfilter/files/rcfile.example1127
-rw-r--r--mail-filter/mailfilter/files/rcfile.example2133
-rw-r--r--mail-filter/mailfilter/mailfilter-0.8.2.ebuild34
-rw-r--r--mail-filter/mailfilter/metadata.xml8
8 files changed, 365 insertions, 0 deletions
diff --git a/mail-filter/mailfilter/Manifest b/mail-filter/mailfilter/Manifest
new file mode 100644
index 000000000000..7287278f8c08
--- /dev/null
+++ b/mail-filter/mailfilter/Manifest
@@ -0,0 +1 @@
+DIST mailfilter-0.8.2.tar.gz 382966 SHA256 4822fdfc4c7db543539a96429086b4d01ac22629396896ee7e52e6edce43fdec SHA512 fc988fe8e36204e4041ce10d6a87f06c8fd48c311aee0d838c2eec08c0d26c13c082fb44a63e7d9c0610d8be52dbf69e340247241f3c76a209319391969ec387 WHIRLPOOL 678c3bd237fa79840f1296ec70b79110bed4fe843ab0894d2e55abdb910302c3096924e897cebaa49b6284ea3df1e9f6c70ef0ad2443a371873581d29648084f
diff --git a/mail-filter/mailfilter/files/0.8.2-gcc44.patch b/mail-filter/mailfilter/files/0.8.2-gcc44.patch
new file mode 100644
index 000000000000..f1545d5b9118
--- /dev/null
+++ b/mail-filter/mailfilter/files/0.8.2-gcc44.patch
@@ -0,0 +1,26 @@
+diff -ur mailfilter-0.8.2_orig/src/header.cc mailfilter-0.8.2/src/header.cc
+--- mailfilter-0.8.2_orig/src/header.cc 2009-06-07 03:49:57.000000000 +0200
++++ mailfilter-0.8.2/src/header.cc 2009-08-15 13:05:05.968397778 +0200
+@@ -63,7 +63,6 @@
+ * domain-literal = "[" *(dtext / quoted-pair) "]"
+ */
+
+- char* dom;
+ unsigned int l, i;
+
+ if (!msgid || !*msgid)
+@@ -74,12 +73,12 @@
+ return -1;
+ if (msgid[0] != '<' || msgid[l-1] != '>')
+ return -1;
+- if (!(dom = strrchr (msgid, '@')))
++ if (!(strrchr (msgid, '@')))
+ return -1;
+
+ /* TODO: complete parser */
+ for (i = 0; i < l; i++)
+- if (msgid[i] > 127)
++ if ((unsigned char)msgid[i] > 127)
+ return -1;
+
+ return 0;
diff --git a/mail-filter/mailfilter/files/0.8.2-gcc46.patch b/mail-filter/mailfilter/files/0.8.2-gcc46.patch
new file mode 100644
index 000000000000..ef1ebe45ebac
--- /dev/null
+++ b/mail-filter/mailfilter/files/0.8.2-gcc46.patch
@@ -0,0 +1,20 @@
+Fix building with gcc-4.6
+
+https://bugs.gentoo.org/show_bug.cgi?id=366191
+
+Part of debian patch by Ricardo Mones <mones@debian.org>
+Fix invalid conversion and addded Ubuntu patch (thanks Ilya Barygin <barygin@gmail.com>)
+
+--- a/src/preferences.cc
++++ b/src/preferences.cc
+@@ -82,8 +82,8 @@
+
+ void Preferences :: init (void)
+ {
+- ((Size_score)(Preferences :: size_score)).score = 0;
+- ((Size_score)(Preferences :: size_score)).size = 0;
++ size_score.score = 0;
++ size_score.size = 0;
+ }
+
+ void Preferences :: kill (void)
diff --git a/mail-filter/mailfilter/files/0.8.2-openssl-1.patch b/mail-filter/mailfilter/files/0.8.2-openssl-1.patch
new file mode 100644
index 000000000000..ad58bbb561f8
--- /dev/null
+++ b/mail-filter/mailfilter/files/0.8.2-openssl-1.patch
@@ -0,0 +1,16 @@
+http://bugs.gentoo.org/330717
+
+--- src/socket.cc
++++ src/socket.cc
+@@ -64,7 +64,11 @@
+ #ifdef USE_SSL
+ SSL* ssl;
+ BIO* sbio;
++ #if OPENSSL_VERSION_NUMBER >= 0x10000000L
++ const SSL_METHOD* ssl_meth;
++ #else
+ SSL_METHOD* ssl_meth;
++ #endif
+ SSL_CTX* ssl_ctx;
+ #endif
+
diff --git a/mail-filter/mailfilter/files/rcfile.example1 b/mail-filter/mailfilter/files/rcfile.example1
new file mode 100644
index 000000000000..85d3a519cf02
--- /dev/null
+++ b/mail-filter/mailfilter/files/rcfile.example1
@@ -0,0 +1,127 @@
+# -----------------------------------------------------------
+# Example rcfile from the INSTALL document
+# -----------------------------------------------------------
+
+
+# -----------------------------------------------------------
+# Logile path (be sure you have write permission in this
+# directory; you MUST specify a logfile)
+
+LOGFILE = "$HOME/logs/mailfilter.log"
+
+
+# -----------------------------------------------------------
+# Level of verbosity
+#
+# 0 Silent, show nothing at all
+# 1 Only show errors
+# 2 Only show "Deleted..." messages and errors
+# 3 Default; Show "Deleted..." messages, errors
+# and "Examining..." messages
+# 4 Like (3), except this also shows the current
+# account's username
+# 5 Like (4), except this also shows which filter
+# matched which string of an e-mail header
+# 6 Debugging mode; prints almost everything
+
+VERBOSE = 3
+
+
+# -----------------------------------------------------------
+# Server list (Do not change the order of the fields!!)
+# Note: Port 110 is usually the port APOP and POP3 servers use,
+# port 995 is required if (say) POP3/SSL is specified.
+
+SERVER = "pop.server.com"
+USER = "username"
+PASS = "password"
+PROTOCOL = "pop3"
+PORT = 110
+
+SERVER = "pop.secondserver.com"
+USER = "anotherusername"
+PASS = "anotherusername"
+PROTOCOL = "pop3/ssl"
+PORT = 995
+
+
+# -----------------------------------------------------------
+# Do you want case sensitive e-mail filters? { yes | no }
+
+REG_CASE = "no"
+
+
+# -----------------------------------------------------------
+# Sets the type of Regular Expression used { extended | basic }
+#
+# (The default is 'basic', don't change unless you know what you
+# are doing. Extended REs are more complex to set up.)
+
+REG_TYPE = "basic"
+
+
+# -----------------------------------------------------------
+# Maximum e-mail size in bytes that should not be exceeded.
+
+MAXSIZE_DENY = 1000000
+
+
+# -----------------------------------------------------------
+# Set maximum line length of any field in the message header
+
+MAXLENGTH = 998
+
+
+# ----------------------------------------------------------
+# Filter rules for detecting spam (each rule must be placed
+# in a separate line)
+
+# These filters detect certain unpleasant e-mail subjects:
+DENY = "^Subject:.*Get penis enlargement"
+DENY = "^Subject:.*WIN MONEY"
+
+# This one filters mail from a certain person:
+DENY = "^From:.*spammer@any_spam_organisation\.com"
+
+# This one filters mail from everyone at a certain organisation:
+DENY = "^From:.*@any_provider_that_spams\.org"
+
+# We don't want any of those 'LEGAL' messages either
+# while stuff with 'legal' in the subject still interests us:
+DENY_CASE = "^Subject:.*LEGAL"
+
+
+# -----------------------------------------------------------
+# Normalises the subject strings before parsing, e.g.
+# ',L.E-G,A.L; ,C.A-B`L`E, +.B-O`X` ;D`E`S,C;R,A.MB;L,E.R-]'
+# becomes 'LEGAL CABLE BOX DESCRAMBLER' which can be filtered.
+#
+# If NORMAL is switched on, Mailfilter tries to apply filters
+# to both the normalised and the original subject.
+
+NORMAL = "yes"
+
+
+# -----------------------------------------------------------
+# The maximum e-mail size in bytes that messages from friends
+# should not exceed. Set this to 0 if all your friends (ALLOW)
+# can send messages as long as they want.
+
+MAXSIZE_ALLOW = 0
+
+
+# ----------------------------------------------------------
+# Set list of friends that always pass, if they do not
+# exceed the message length of MAXSIZE_ALLOW
+
+# This rule allows all mail from a friend who was unlucky enough
+# to have signed up with a spam organisation. With DENY we
+# block everyone else from that domain though! See above!
+ALLOW = "^From:.*a_friend_with_account@any_provider_that_spams.org"
+
+# Of course we allow e-mail from anyone who has something to say about
+# mailfilter:
+ALLOW = "^Subject:.*mailfilter"
+
+# We also let our girlfriend send any e-mail she wants:
+ALLOW = "^From:.*my_girlfriend@any_provider\.com"
diff --git a/mail-filter/mailfilter/files/rcfile.example2 b/mail-filter/mailfilter/files/rcfile.example2
new file mode 100644
index 000000000000..d4fab0f01a4c
--- /dev/null
+++ b/mail-filter/mailfilter/files/rcfile.example2
@@ -0,0 +1,133 @@
+# -----------------------------------------------------------
+# Example rcfile from the INSTALL document
+# Example configuration based upon the INSTALL document, but
+# showing some advanced features such as 'Negative Filters',
+# extended Regular Expressions, etc.
+# -----------------------------------------------------------
+
+
+# -----------------------------------------------------------
+# Logile path (be sure you have write permission in this
+# directory; you MUST specify a logfile)
+
+LOGFILE = "$HOME/logs/mailfilter.log"
+
+
+# -----------------------------------------------------------
+# Level of verbosity
+#
+# 0 Silent, show nothing at all
+# 1 Only show errors
+# 2 Only show "Deleted..." messages and errors
+# 3 Default; Show "Deleted..." messages, errors
+# and "Examining..." messages
+# 4 Like (3), except this also shows the current
+# account's username
+# 5 Like (4), except this also shows which filter
+# matched which string of an e-mail header
+# 6 Debugging mode; prints almost everything
+
+VERBOSE = 4
+
+
+# -----------------------------------------------------------
+# Server list (Do not change the order of the fields!!)
+# Note: Port 110 is usually the port APOP and POP3 servers use,
+# port 995 is required if (say) POP3/SSL is specified.
+
+SERVER = "pop.server.com"
+USER = "username"
+PASS = "password"
+PROTOCOL = "pop3"
+PORT = 110
+
+SERVER = "pop.secondserver.com"
+USER = "anotherusername"
+PASS = "anotherusername"
+PROTOCOL = "pop3/ssl"
+PORT = 995
+
+
+# -----------------------------------------------------------
+# Do you want case sensitive e-mail filters? { yes | no }
+
+REG_CASE = "no"
+
+
+# -----------------------------------------------------------
+# Sets the type of Regular Expression used { extended | basic }
+#
+# (The default is 'basic', don't change unless you know what you
+# are doing. Extended REs are more complex to set up.)
+
+# We want some additional smartness in our rules. That's why only
+# extended Regular Expressions work for this sample set-up.
+REG_TYPE = "extended"
+
+
+# -----------------------------------------------------------
+# Maximum e-mail size in bytes that should not be exceeded.
+
+# Accept only 250 KBytes message size. Friends can send more though.
+# (See MAXSIZE_ALLOW for further information.)
+MAXSIZE_DENY = 250000
+
+
+# -----------------------------------------------------------
+# Set maximum line length of any field in the message header
+
+MAXLENGTH = 998
+
+
+# This one filters mail from a certain person.
+# (We need the back slash before the '.com' since we are using
+# extended Regular Expressions.)
+DENY="^From:.*spammer@any_spam_organisation\.com"
+
+# This one filters mail from everyone at a certain organisation:
+DENY = "^From:.*@any_provider_that_spams\.org"
+
+# We don't want any of those 'LEGAL' messages either
+# while stuff with 'legal' in the subject still interests us:
+DENY_CASE = "^Subject:.*LEGAL"
+
+# This one demonstrates the use of 'Negative Filters' and the
+# logical OR '|' in Regular Expressions.
+# (Again, the example works only with extended Regular Expressions.)
+# Kill everything not directly addressed to own account:
+DENY<>"(^To|^Cc):(.*username@server\.com|.*anotherusername@secondserver\.com)"
+
+# -----------------------------------------------------------
+# Normalises the subject strings before parsing, e.g.
+# ',L.E-G,A.L; ,C.A-B`L`E, +.B-O`X` ;D`E`S,C;R,A.MB;L,E.R-]'
+# becomes 'LEGAL CABLE BOX DESCRAMBLER' which can be filtered.
+#
+# If NORMAL is switched on, Mailfilter tries to apply filters
+# to both the normalised and the original subject.
+
+NORMAL = "yes"
+
+
+# -----------------------------------------------------------
+# The maximum e-mail size in bytes that messages from friends
+# should not exceed. Set this to 0 if all your friends (ALLOW)
+# can send messages as long as they want.
+
+MAXSIZE_ALLOW = 0
+
+
+# ----------------------------------------------------------
+# Set list of friends that always pass, if they do not
+# exceed the message length of MAXSIZE_ALLOW
+
+# This rule allows all mail from a friend who was unlucky enough
+# to have signed up with a spam organisation. With DENY we
+# block everyone else from that domain though! See above!
+ALLOW = "^From:.*a_friend_with_account@any_provider_that_spams\.org"
+
+# Of course we allow e-mail from anyone who has something to say about
+# mailfilter:
+ALLOW = "^Subject:.*mailfilter"
+
+# We also let our girlfriend send any e-mail she wants:
+ALLOW = "^From:.*my_girlfriend@any_provider\.com"
diff --git a/mail-filter/mailfilter/mailfilter-0.8.2.ebuild b/mail-filter/mailfilter/mailfilter-0.8.2.ebuild
new file mode 100644
index 000000000000..d857bfb85383
--- /dev/null
+++ b/mail-filter/mailfilter/mailfilter-0.8.2.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=2
+inherit eutils
+
+DESCRIPTION="Mailfilter is a utility to get rid of unwanted spam mails"
+HOMEPAGE="http://mailfilter.sourceforge.net/"
+SRC_URI="mirror://sourceforge/mailfilter/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ppc sparc x86 ~x86-fbsd"
+IUSE=""
+
+DEPEND="sys-devel/flex"
+RDEPEND=""
+
+src_prepare() {
+ epatch "${FILESDIR}"/0.8.2-gcc44.patch \
+ "${FILESDIR}"/0.8.2-openssl-1.patch \
+ "${FILESDIR}"/${PV}-gcc46.patch
+}
+
+src_compile() {
+ emake -j1 || die #281069
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die
+ dodoc INSTALL doc/FAQ "${FILESDIR}"/rcfile.example{1,2} \
+ README THANKS ChangeLog AUTHORS NEWS || die
+}
diff --git a/mail-filter/mailfilter/metadata.xml b/mail-filter/mailfilter/metadata.xml
new file mode 100644
index 000000000000..35ed8f5cefd6
--- /dev/null
+++ b/mail-filter/mailfilter/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>net-mail</herd>
+ <upstream>
+ <remote-id type="sourceforge">mailfilter</remote-id>
+ </upstream>
+</pkgmetadata>