]> source.dussan.org Git - rspamd.git/commitdiff
[Conf] Preliminary try to add SURBL hashbl support (WIP)
authorVsevolod Stakhov <vsevolod@rspamd.com>
Sat, 17 Dec 2022 20:38:55 +0000 (20:38 +0000)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Sat, 17 Dec 2022 20:38:55 +0000 (20:38 +0000)
conf/modules.d/rbl.conf

index 94b3ee7c647c954affb4964c661139f6535b219b..a27f60c4a9bb979e533c7f5628a47cdcb0727a71 100644 (file)
@@ -23,6 +23,14 @@ rbl {
     "fallback+file://${CONFDIR}/maps.d/surbl-whitelist.inc"
   ];
 
+  attached_maps = [
+    {
+      selector_alias = "surbl_hashbl_map",
+      description = "SURBL hashbl map",
+      url = "regexp;http://sa-update.surbl.org/rspamd/surbl-hashbl-map.inc",
+    }
+  ]
+
   rbls {
 
     spamhaus {
@@ -206,6 +214,22 @@ rbl {
       }
     }
 
+    SURBL_HASHBL {
+      rbl = "hashbl.surbl.org";
+      ignore_defaults = true;
+      random_monitored = true,
+      selector = "specific_urls_filter_map('surbl_hashbl_map'):apply_methods('get_host', 'get_path').join_tables('/')",
+      hash = 'md5';
+      hash_len = 32;
+      returncodes = {
+        SURBL_HASHBL_PHISH = "127.0.0.8";
+        SURBL_HASHBL_MALWARE = "127.0.0.16";
+        SURBL_HASHBL_ABUSE = "127.0.0.64";
+        SURBL_HASHBL_CRACKED = "127.0.0.128";
+        SURBL_HASHBL_EMAIL = "127.0.1.%d+";
+      }
+    }
+
     "URIBL_MULTI" {
       ignore_defaults = true;
       rbl = "multi.uribl.com";