Browse Source

[Rework] Rbl: Rework defaults logic

tags/2.7
Vsevolod Stakhov 3 years ago
parent
commit
6598ceb596
2 changed files with 24 additions and 20 deletions
  1. 24
    11
      conf/modules.d/rbl.conf
  2. 0
    9
      src/plugins/lua/rbl.lua

+ 24
- 11
conf/modules.d/rbl.conf View File

# Module documentation can be found at https://rspamd.com/doc/modules/rbl.html # Module documentation can be found at https://rspamd.com/doc/modules/rbl.html


rbl { rbl {
default_from = true;
default_received = false;
default_exclude_users = true; default_exclude_users = true;
default_exclude_local = true;
default_unknown = true; default_unknown = true;
default_dkim_domainonly = true;
default_dkim_match_from = false;
default_ipv4 = true;
default_ipv6 = true;


url_whitelist = [ url_whitelist = [
"https://maps.rspamd.com/rspamd/surbl-whitelist.inc.zst", "https://maps.rspamd.com/rspamd/surbl-whitelist.inc.zst",
spamhaus { spamhaus {
symbol = "SPAMHAUS"; # Augmented by prefixes symbol = "SPAMHAUS"; # Augmented by prefixes
rbl = "zen.spamhaus.org"; rbl = "zen.spamhaus.org";
ipv6 = true;
# Check types
received = true; received = true;
from = true; from = true;

symbols_prefixes = { symbols_prefixes = {
received = 'RECEIVED', received = 'RECEIVED',
from = 'RBL', from = 'RBL',
symbol = "MAILSPIKE"; symbol = "MAILSPIKE";
rbl = "rep.mailspike.net"; rbl = "rep.mailspike.net";
is_whitelist = true; is_whitelist = true;
from = true; # Check source IP address
whitelist_exception = "MAILSPIKE"; whitelist_exception = "MAILSPIKE";
whitelist_exception = "RWL_MAILSPIKE_GOOD"; whitelist_exception = "RWL_MAILSPIKE_GOOD";
whitelist_exception = "RWL_MAILSPIKE_NEUTRAL"; whitelist_exception = "RWL_MAILSPIKE_NEUTRAL";


senderscore { senderscore {
symbol = "RBL_SENDERSCORE"; symbol = "RBL_SENDERSCORE";
from = true; # Check source IP address
rbl = "bl.score.senderscore.com"; rbl = "bl.score.senderscore.com";
} }


symbol = "RBL_SEM"; symbol = "RBL_SEM";
rbl = "bl.spameatingmonkey.net"; rbl = "bl.spameatingmonkey.net";
ipv6 = false; ipv6 = false;
from = true; # Check source IP address
} }


semIPv6 { semIPv6 {
rbl = "bl.ipv6.spameatingmonkey.net"; rbl = "bl.ipv6.spameatingmonkey.net";
ipv4 = false; ipv4 = false;
ipv6 = true; ipv6 = true;
from = true; # Check source IP address
} }


dnswl { dnswl {
symbol = "RCVD_IN_DNSWL"; symbol = "RCVD_IN_DNSWL";
rbl = "list.dnswl.org"; rbl = "list.dnswl.org";
ipv6 = true; ipv6 = true;
from = true; # Check source IP address
received = true; # Check source IP address
is_whitelist = true; is_whitelist = true;
whitelist_exception = "RCVD_IN_DNSWL"; whitelist_exception = "RCVD_IN_DNSWL";
whitelist_exception = "RCVD_IN_DNSWL_NONE"; whitelist_exception = "RCVD_IN_DNSWL_NONE";
symbol = "RBL_VIRUSFREE_UNKNOWN"; symbol = "RBL_VIRUSFREE_UNKNOWN";
rbl = "bip.virusfree.cz"; rbl = "bip.virusfree.cz";
ipv6 = true; ipv6 = true;
from = true; # Check source IP address
returncodes { returncodes {
RBL_VIRUSFREE_BOTNET = "127.0.0.2"; RBL_VIRUSFREE_BOTNET = "127.0.0.2";
} }
symbol = "RBL_NIXSPAM"; symbol = "RBL_NIXSPAM";
rbl = "ix.dnsbl.manitu.net"; rbl = "ix.dnsbl.manitu.net";
ipv6 = true; ipv6 = true;
from = true; # Check source IP address
} }


blocklistde { blocklistde {
from = true; from = true;
} }


# Dkim whitelist
dnswl_dwl { dnswl_dwl {
symbol = "DWL_DNSWL"; symbol = "DWL_DNSWL";
rbl = "dwl.dnswl.org"; rbl = "dwl.dnswl.org";
DWL_DNSWL_BLOCKED = "127.0.0.255"; DWL_DNSWL_BLOCKED = "127.0.0.255";
} }
} }
# Old emails module
RSPAMD_EMAILBL { RSPAMD_EMAILBL {
ignore_whitelist = true; ignore_whitelist = true;
ignore_defaults = true; ignore_defaults = true;
emails_delimiter = "."; emails_delimiter = ".";
emails = true;
hash_format = "base32"; hash_format = "base32";
hash_len = 32; hash_len = 32;
rbl = "email.rspamd.com"; rbl = "email.rspamd.com";
replyto = true;
emails = true; # Emails in body
replyto = true; # Email from reply-to header
hash = "blake2"; hash = "blake2";
returncodes = { returncodes = {
RSPAMD_EMAILBL = "127.0.0.2"; RSPAMD_EMAILBL = "127.0.0.2";
ignore_whitelist = true; ignore_whitelist = true;
ignore_defaults = true; ignore_defaults = true;
rbl = "ebl.msbl.org"; rbl = "ebl.msbl.org";
emails = true;
emails = true; # Emails in body
replyto = true; # Email from reply-to header
emails_domainonly = false; emails_domainonly = false;
replyto = true;
hash = "sha1"; hash = "sha1";
returncodes = { returncodes = {
MSBL_EBL = [ MSBL_EBL = [
rbl = "multi.surbl.org"; rbl = "multi.surbl.org";
dkim = true; dkim = true;
emails = true; emails = true;
emails_domainonly = true;
urls = true; urls = true;
emails_domainonly = true;


returnbits = { returnbits = {
CRACKED_SURBL = 128; # From February 2016 CRACKED_SURBL = 128; # From February 2016
rbl = "multi.uribl.com"; rbl = "multi.uribl.com";
dkim = true; dkim = true;
emails = true; emails = true;
emails_domainonly = true;
urls = true; urls = true;
emails_domainonly = true;


returnbits { returnbits {
URIBL_BLOCKED = 1; URIBL_BLOCKED = 1;
rbl = "uribl.rspamd.com"; rbl = "uribl.rspamd.com";
dkim = true; dkim = true;
emails = true; emails = true;
emails_domainonly = true;
urls = true; urls = true;
emails_domainonly = true;
hash = 'blake2'; hash = 'blake2';
hash_len = 32; hash_len = 32;
hash_format = 'base32'; hash_format = 'base32';

+ 0
- 9
src/plugins/lua/rbl.lua View File

['default_enabled'] = true, ['default_enabled'] = true,
['default_ipv4'] = true, ['default_ipv4'] = true,
['default_ipv6'] = true, ['default_ipv6'] = true,
['default_received'] = false,
['default_from'] = true,
['default_unknown'] = false, ['default_unknown'] = false,
['default_rdns'] = false,
['default_helo'] = false,
['default_dkim'] = false,
['default_dkim_domainonly'] = true, ['default_dkim_domainonly'] = true,
['default_emails'] = false,
['default_urls'] = false,
['default_emails_domainonly'] = false, ['default_emails_domainonly'] = false,
['default_exclude_private_ips'] = true, ['default_exclude_private_ips'] = true,
['default_exclude_users'] = false, ['default_exclude_users'] = false,
['default_exclude_local'] = true, ['default_exclude_local'] = true,
['default_no_ip'] = false, ['default_no_ip'] = false,
['default_images'] = false,
['default_replyto'] = false,
['default_dkim_match_from'] = false, ['default_dkim_match_from'] = false,
} }



Loading…
Cancel
Save