Some example of different reject threshold for different recipients ?

58 views
Skip to first unread message

Håkon Alstadheim

unread,
Mar 30, 2017, 7:03:47 PM3/30/17
to rspamd
Fresh convert from dSpam here.

I run a small mailing-list, and I would like to reject spam outright
just for that list, but still keep "actions { reject = 900 .. " for my
regular users (i.e. all spam is delivered, marked as spam).


Background: List-admin is on gmail, so even though I can get mailman to
withhold mail that has been marked as spam, I can not inform the
list-admin of this, since gmail blocks mail with attached spam message.
Can't seem to find a way to make mailman NOT attach the withheld spam
when it tries to inform the admin that mail has been witheld. I end up
with undeliverable admin messages in postfix' outgoing queue.

Research so far: I'm fairly sure this
<https://rspamd.com/doc/configuration/settings.html> could be used to
set a reject threshold specific for mail adressed to the list, but that
document is sorely lacking in examples.

I have no idea which file I would enter those custom settings into, and
I'm only GUESSING that e.g. thelist@mydomain would involve

"settings { list_recip { id = "maillist" rcpt = "thelist" ...."

Anybody got an example ?

P.S: I _could_ implement a quarantine, but as that involves installing
code that is not packaged for debian jessie, I want to try all other
avenues first.

Andrew Lewis

unread,
Mar 30, 2017, 7:23:20 PM3/30/17
to rsp...@googlegroups.com

Hi,

> Research so far: I'm fairly sure this
> <https://rspamd.com/doc/configuration/settings.html> could be used
> to set a reject threshold specific for mail adressed to the list,
> but that document is sorely lacking in examples.
> I have no idea which file I would enter those custom settings into,
> and I'm only GUESSING that e.g. thelist@mydomain would involve
> "settings { list_recip { id = "maillist" rcpt = "thelist" ...."
> Anybody got an example ?

It may be helpful to review the general config information:
https://rspamd.com/doc/quickstart.html#configuring-rspamd

As settings doesn't feature in default configuration, we can add it to
rspamd.conf.override (or rspamd.conf.local).

Settings can be hardcoded in configuration, eg:

settings {
ml {
rcpt = "m...@example.net"
apply "default" {
actions {
reject = 15;
}
}
}
}

or set to a map:

settings = "/some/file"
or:
settings = "http://example.net/some.file"

where content of the file is the stuff *inside* settings {} block as
shown above. In this case settings will be periodically checked &
updated.

Best,
-AL.

Håkon Alstadheim

unread,
Mar 31, 2017, 2:34:29 AM3/31/17
to rsp...@googlegroups.com


Den 31. mars 2017 01:23, skrev Andrew Lewis:
>
> Hi,
>
>> Research so far: I'm fairly sure this
>> <https://rspamd.com/doc/configuration/settings.html> could be used to
>> set a reject threshold specific for mail adressed to the list, but
>> that document is sorely lacking in examples.
>> I have no idea which file I would enter those custom settings into,
>> and I'm only GUESSING that e.g. thelist@mydomain would involve
>> "settings { list_recip { id = "maillist" rcpt = "thelist" ...."
>> Anybody got an example ?
>
> It may be helpful to review the general config information:
> https://rspamd.com/doc/quickstart.html#configuring-rspamd

Yes, that is where I started, but I was far from sure where "settings"
belonged in this overall picture :-) . Searching for "settings" does not
exactly narrow it down ...

>
> As settings doesn't feature in default configuration, we can add it to
> rspamd.conf.override (or rspamd.conf.local).
>
> Settings can be hardcoded in configuration, eg:
>
> settings {
> ml {
> rcpt = "m...@example.net"
> apply "default" {
> actions {
> reject = 15;
> }
> }
> }
> }
>

Thanks! Will try, and thanks for quick response.

---
Håkon

Reply all
Reply to author
Forward
0 new messages