disable some unnecessary rspamd modules

This commit is contained in:
missytake
2023-10-15 23:11:55 +02:00
committed by link2xt
parent faf8ffe678
commit 67062677b0
5 changed files with 26 additions and 0 deletions

View File

@@ -396,6 +396,26 @@ def _configure_rspamd(dkim_selector: str, mail_domain: str) -> bool:
"""Configures rspamd for Rate Limiting."""
need_restart = False
phishing_conf = files.put(
name="disable phishing rspamd plugin",
src=importlib.resources.files(__package__).joinpath("rspamd/phishing.conf"),
dest="/etc/rspamd/local.d/phishing.conf",
user="root",
group="root",
mode="644",
)
need_restart |= phishing_conf.changed
hfilter = files.put(
name="disable hfilter rspamd plugin",
src=importlib.resources.files(__package__).joinpath("rspamd/hfilter.conf"),
dest="/etc/rspamd/local.d/hfilter.conf",
user="root",
group="root",
mode="644",
)
need_restart |= hfilter.changed
dkim_directory = "/var/lib/rspamd/dkim/"
dkim_key_path = f"{dkim_directory}{mail_domain}.{dkim_selector}.key"

View File

@@ -0,0 +1,5 @@
helo_enabled = false;
hostname_enabled = false;
url_enabled = false;
from_enabled = false;
rcpt_enabled = false;

View File

@@ -0,0 +1 @@
phishtank_enabled = false;