summaryrefslogtreecommitdiff
path: root/mail-filter/spamassassin/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-06-21 17:50:24 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-06-21 17:50:24 +0100
commitfeb0daf81d888e9160f9f94502de09b66f2a63fd (patch)
treeb6e5c40ce2abef3da27ed50a023153f475e0ddef /mail-filter/spamassassin/files
parent9452a6e87b6c2c70513bc47a2470bf9f1168920e (diff)
gentoo resync : 21.06.2020
Diffstat (limited to 'mail-filter/spamassassin/files')
-rw-r--r--mail-filter/spamassassin/files/geoip.cf70
-rw-r--r--mail-filter/spamassassin/files/mention-geoip.cf-in-init.pre.patch11
2 files changed, 81 insertions, 0 deletions
diff --git a/mail-filter/spamassassin/files/geoip.cf b/mail-filter/spamassassin/files/geoip.cf
new file mode 100644
index 000000000000..733cba09ebc8
--- /dev/null
+++ b/mail-filter/spamassassin/files/geoip.cf
@@ -0,0 +1,70 @@
+# GeoIP / RelayCountry Config
+#
+# The RelayCountry SpamAssassin plugin needs to be enabled
+# in init.pre, but it's suggested that you make configuration
+# changes here.
+#
+# See Also:
+# - https://wiki.apache.org/spamassassin/RelayCountryPlugin
+# - man Mail::SpamAssassin::Plugin::RelayCountry
+#
+# NOTE: This is a Gentoo supplied config file.
+#
+
+###############################################################
+#
+# CONFIGURATION
+#
+
+# Which type of Geo database to use. Valid database types are
+# GeoIP, GeoIP2, DB_File and Fast. Defaults to Fast, GeoIP2 is
+# the suggested backend which uses dev-perl/GeoIP2.
+#
+#country_db_type GeoIP2
+
+# Where to find MaxMind GeoIP2 or IP::Country::DB_File database.
+# The default is to search several paths, see the RelayCountry
+# man page referenced at the top for details.
+#
+# It's suggested you use net-misc/geoipupdate to install and
+# update your GeoIP2 databases.
+#
+#country_db_path /usr/share/GeoIP/GeoLite2-Country.mmdb
+
+# The following will add a separate MIME header that shows all
+# the message's relay countries, independent of any site-
+# specific rules.
+#
+# It will show up in your MIME headers as:
+# X-Spam-Relay-Country: US CN RU
+#
+#add_header all Relay-Country _RELAYCOUNTRY_
+
+###############################################################
+#
+# SITE SPECIFIC RULES
+#
+
+# Country metadata will also be added to the Bayesian filtering
+# process, allowing it to learn information based on countries.
+# This will occur even if you don't define any site specific
+# rules.
+
+# NOTE: Many prefer placing custom rules in local.cf.
+
+# The following is an example of a rule that penalizes mail
+# that passed through China by increasing the spam score
+# of the message by 3 points.
+#
+#header RELAYCOUNTRY_BAD X-Relay-Countries =~ /CN/
+#describe RELAYCOUNTRY_BAD Relayed through China at some point
+#score RELAYCOUNTRY_BAD 3.0
+
+# And this is an example of a rule that rewards mail that
+# has first went through Finland or Sweden by reducing the
+# spam score of the message by 0.2 points.
+#
+#header RELAYCOUNTRY_GOOD X-Relay-Countries =~ /^(FI|SE)/
+#describe RELAYCOUNTRY_GOOD First untrusted relay is Finland or Sweden :-)
+#score RELAYCOUNTRY_GOOD -0.2
+
diff --git a/mail-filter/spamassassin/files/mention-geoip.cf-in-init.pre.patch b/mail-filter/spamassassin/files/mention-geoip.cf-in-init.pre.patch
new file mode 100644
index 000000000000..13921dc6eb93
--- /dev/null
+++ b/mail-filter/spamassassin/files/mention-geoip.cf-in-init.pre.patch
@@ -0,0 +1,11 @@
+--- Mail-SpamAssassin-3.4.4/rules/init.pre 2019-10-23 20:22:15.000000000 -0400
++++ Mail-SpamAssassin-3.4.4/rules/init.pre 2020-05-20 19:59:42.239544414 -0400
+@@ -17,7 +17,7 @@
+ # RelayCountry - add metadata for Bayes learning, marking the countries
+ # a message was relayed through
+ #
+-# Note: This requires the Geo::IP Perl module
++# Note: This requires geoip.cf to be edited.
+ #
+ # loadplugin Mail::SpamAssassin::Plugin::RelayCountry
+