public
nobgit
read
NobMail
Based on mailcow: dockerized
Languages
Repository composition by tracked source files.
PHP
49%
JavaScript
35%
HTML
9%
CSS
4%
Shell
2%
Python
1%
Lua
0%
Perl
0%
Ruby
0%
SCSS
0%
Create file
Wiki Documentation
Clone
https://nobgit.com/orgs/nobgit/nobmail.git
ssh://[email protected]:2222/orgs/nobgit/nobmail.git
Commit
rspamd: fixed dqs rbl insertion handling
b6c03649
data/Dockerfiles/rspamd/docker-entrypoint.sh | 46 +++++++++++++---------------
data/conf/rspamd/local.d/rbl.conf | 2 +-
2 files changed, 23 insertions(+), 25 deletions(-)
Diff
diff --git a/data/Dockerfiles/rspamd/docker-entrypoint.sh b/data/Dockerfiles/rspamd/docker-entrypoint.sh
index a6141c57..cf09ee48 100755
--- a/data/Dockerfiles/rspamd/docker-entrypoint.sh
+++ b/data/Dockerfiles/rspamd/docker-entrypoint.sh
@@ -128,7 +128,6 @@ done
if [[ ! -z ${SPAMHAUS_DQS_KEY} ]]; then
cat <<EOF > /etc/rspamd/custom/dqs-rbl.conf
# Autogenerated by mailcow. DO NOT TOUCH!
- rbls {
spamhaus {
rbl = "${SPAMHAUS_DQS_KEY}.zen.dq.spamhaus.net";
from = false;
@@ -221,7 +220,7 @@ if [[ ! -z ${SPAMHAUS_DQS_KEY} ]]; then
replyto = true;
emails_domainonly = true;
disable_monitoring = true;
- rbl = "${SPAMHAUS_DQS_KEY}.dbl.dq.spamhaus.net"
+ rbl = "${SPAMHAUS_DQS_KEY}.dbl.dq.spamhaus.net";
returncodes = {
SH_EMAIL_DBL = [
"127.0.1.2",
@@ -243,7 +242,7 @@ if [[ ! -z ${SPAMHAUS_DQS_KEY} ]]; then
replyto = true;
emails_domainonly = true;
disable_monitoring = true;
- rbl = "${SPAMHAUS_DQS_KEY}.zrd.dq.spamhaus.net"
+ rbl = "${SPAMHAUS_DQS_KEY}.zrd.dq.spamhaus.net";
returncodes = {
SH_EMAIL_ZRD_VERY_FRESH_DOMAIN = ["127.0.2.2", "127.0.2.3", "127.0.2.4"];
SH_EMAIL_ZRD_FRESH_DOMAIN = [
@@ -251,26 +250,26 @@ if [[ ! -z ${SPAMHAUS_DQS_KEY} ]]; then
];
SH_EMAIL_ZRD_DONT_QUERY_IPS = [ "127.0.2.255" ];
}
- }
- "DBL" {
- # override the defaults for DBL defined in modules.d/rbl.conf
- rbl = "${SPAMHAUS_DQS_KEY}.dbl.dq.spamhaus.net";
- disable_monitoring = true;
- }
- "ZRD" {
- ignore_defaults = true;
- rbl = "${SPAMHAUS_DQS_KEY}.zrd.dq.spamhaus.net";
- no_ip = true;
- dkim = true;
- emails = true;
- emails_domainonly = true;
- urls = true;
- returncodes = {
- ZRD_VERY_FRESH_DOMAIN = ["127.0.2.2", "127.0.2.3", "127.0.2.4"];
- ZRD_FRESH_DOMAIN = ["127.0.2.5", "127.0.2.6", "127.0.2.7", "127.0.2.8", "127.0.2.9", "127.0.2.10", "127.0.2.11", "127.0.2.12", "127.0.2.13", "127.0.2.14", "127.0.2.15", "127.0.2.16", "127.0.2.17", "127.0.2.18", "127.0.2.19", "127.0.2.20", "127.0.2.21", "127.0.2.22", "127.0.2.23", "127.0.2.24"];
- }
- }
- spamhaus_sbl_url {
+ }
+ "DBL" {
+ # override the defaults for DBL defined in modules.d/rbl.conf
+ rbl = "${SPAMHAUS_DQS_KEY}.dbl.dq.spamhaus.net";
+ disable_monitoring = true;
+ }
+ "ZRD" {
+ ignore_defaults = true;
+ rbl = "${SPAMHAUS_DQS_KEY}.zrd.dq.spamhaus.net";
+ no_ip = true;
+ dkim = true;
+ emails = true;
+ emails_domainonly = true;
+ urls = true;
+ returncodes = {
+ ZRD_VERY_FRESH_DOMAIN = ["127.0.2.2", "127.0.2.3", "127.0.2.4"];
+ ZRD_FRESH_DOMAIN = ["127.0.2.5", "127.0.2.6", "127.0.2.7", "127.0.2.8", "127.0.2.9", "127.0.2.10", "127.0.2.11", "127.0.2.12", "127.0.2.13", "127.0.2.14", "127.0.2.15", "127.0.2.16", "127.0.2.17", "127.0.2.18", "127.0.2.19", "127.0.2.20", "127.0.2.21", "127.0.2.22", "127.0.2.23", "127.0.2.24"];
+ }
+ }
+ spamhaus_sbl_url {
ignore_defaults = true
rbl = "${SPAMHAUS_DQS_KEY}.sbl.dq.spamhaus.net";
checks = ['urls'];
@@ -306,7 +305,6 @@ if [[ ! -z ${SPAMHAUS_DQS_KEY} ]]; then
SH_HBL_FILE_SUSPICIOUS = "127.0.3.15";
}
}
- }
EOF
else
rm -rf /etc/rspamd/custom/dqs-rbl.conf
diff --git a/data/conf/rspamd/local.d/rbl.conf b/data/conf/rspamd/local.d/rbl.conf
index 509435d5..7f2976a0 100644
--- a/data/conf/rspamd/local.d/rbl.conf
+++ b/data/conf/rspamd/local.d/rbl.conf
@@ -21,6 +21,6 @@ rbls {
}
}
-.include(try=true,priority=5) "$LOCAL_CONFDIR/custom/dqs-rbl.conf"
+.include(try=true,override=true,priority=5) "$LOCAL_CONFDIR/custom/dqs-rbl.conf"
}
\ No newline at end of file