Hey. I have the smtp filter with Rspamd, how do I add addresses to black list and white list. If the addresses of about 2000 ?
I didn’t try this, but this might be an option: https://gist.github.com/kvaps/25507a87dc287e6a620e1eec2d60ebc1
I mean Rspamd in the implementation of the nethserver. In rspamd itself, this is done through the web interface. But in the plug-in to the nethserver. The file is read-only and can only be added to 1 address through the nethserver interface. Long addition will be))))
@davidep sometime ago did a script to learn email to spam from a imap folder…need to find it again…some clue ?
Oups a misunderstood your issue…you want to add email adresses manually from a file…let me check…we could create a second map for this purpose.
The first blacklist map is a template created from db properties, we need another map for this
My Communigate mail server is located on a separate Server, it would be nice to hook up the spam folder with NS to it. But you can still manually add. But I already have a large list of addresses and would like to add it immediately.
Ok not tested, we could do something for you
in the file
/etc/rspamd/local.d/multimap.conf you have declaration for the map we use for instance
# whitelist the senders
type = "from";
map = [
prefilter = true;
filter = "email:addr";
action = "accept";
description = "Accepted list of FROM email address";
symbol = "FROM_WHITELIST";
the idea is to add the path to a new map
map = [
the path is
/etc/rspamd, be sure of the permission on the new file
manual_whitelist_from.map and add inside one address per line
Restart rspamd after :
systemctl restart rspamd
Your work will be overwritten by the next time you save a setting in the filter panel, we need to find a way to add it probably by a db property.
@davidep what do you think, the idea is to create blacklist/whitelist from a file for those who have a long list, here around 2000
@kelevra can you test it by adding the maps needed, one by whithelist and blacklist
Card created in issue tracker
I don’t know… A long list seems hard to maintain
We have two ways but first I would like to do it by a hidden prop, once enabled you could either add manually with vim, or by the web UI
Ok just tested now…do not waste your time if you want to blacklist a gmail address…gmail wants to be different
email@example.com => firstname.lastname@example.org
maybe we should do a documentation on this
I did an issue
IMO, this is a very special case and it doesn’t worth an implementation inside the package.
We can just document here, or somewhere else, how to do it using a template-custom.
Why not to follow @giacomo’s approach?
@kelevra’s request seems a typical template-custom use case which does not require additional code!
Maybe I’m wrong but the two templates to customize are:
Yep it is just one way, but then the system administrator is on his own to follow the modifications we can push.
cp /etc/e-smith/templates/etc/rspamd/local.d/multimap.conf/10base /etc/e-smith/templates-custom/etc/rspamd/local.d/multimap.conf
and add the map you need for example
map = [
And that’s fine: not everything should be added to a package.
More code, more bugs, more things to maintain.
IMO, configuration corner cases should be always demanded to custom-templates.