[Rspamd-Users] Error adding custom rules (SENDER_DOMAIN_BLACKLIST)

Andreas rspamd at linuxmaker.com
Tue May 20 10:37:48 UTC 2025


Hello Florian

The $ sign at the end of my blacklist map file is only displayed as a test by
"cat -A"
; it shows me that there's nothing in it with Windows line breaks.
That's not the problem. When I run "cat -A" on the other maps, I also see a $ 
sign at the end of each line.

Regards

Andreas


> Hello all,
> 
> is the $ part of a regexp expression and if yes, then you did not define
> 
> regexp = true;
> 
> in the rule setting.
> 
> If you omit the $ a the end of your blacklist map file, maybe that works?
> 
> Florian
> 
> > I'm trying to block unwanted domains and have made this entry in my
> > /etc/rspamd/local.d/multimap.conf
> > 
> > SENDER_DOMAIN_BLACKLIST {
> > 
> >      type = "smtp_from";
> >      filter = "email:domain";
> >      map = "${LOCAL_CONFDIR}/local.d/maps.d/sender_domain_blacklist.map";
> >      action = "reject";
> >      prefilter = true;
> >      priority = 100;
> >      messages = "This sender domain is blocked!";
> >      symbol = "BLACKLISTED_DOMAIN";
> > 
> > }
> > 
> > 
> > and the map file exists with valid line breaks:
> > 
> > cat -A /etc/rspamd/local.d/maps.d/sender_domain_blacklist.map
> > 
> > ...tagroup.online.tc$
> > inkilsane.de$
> > tiimab.or.mg$
> > toonaca.or.mg$
> > agentur.de$
> > ...
> > 
> > But when I test the multimap I get this error message.
> > rspamadm configdump multimap
> > cannot add rule: "SENDER_DOMAIN_BLACKLIST"
> > redefining fallback backend from /etc/rspamd/maps.d/surbl-whitelist.inc to
> > / etc/rspamd/maps.d/surbl-whitelist.inc
> > 
> > All other rules are accepted. Does anyone see why this isn't working?
> > 
> > Best regards






More information about the Users mailing list