[Rspamd-Users] Actions/negative...
Andrew Lewis
rspamd-users at judo.za.org
Mon Nov 10 07:24:48 UTC 2025
Hi Michelle,
On Sat, 2025-11-08 at 20:09 +1100, Michelle Sullivan wrote:
> But I thought came to mind is it possible to define an action with a
> negative score?
Something about that doesn't indeed work (but probably it should I
suppose).
> FWIW without using ‘force_actions’ (which I don;’t have a need for)
> this is supposed to work:
>
> malware = {
> flags = ["no_threshold"];
> }
>
> virus = {
> flags = ["no_threshold"];
> }
>
> hard-reject = {
> flags = ["no_threshold"];
> }
>
> discard = {
> flags = ["no_threshold"];
> }
>
> However, it’s hit and miss on whether I can get ‘hard-reject’ or
> ‘virus’ returned in 3.13…
For lack of thresholds, force_actions or similar mechanism would be the
only way these would get set. Unpredictability of which rule will win
is a likely issue, possibly we should better add support for relative
priority there.
> Does work though.. the only problem being if I set the action in a
> lua script it sets the score (and then might add to it)..
If actions are forced scores will generally be wrong.
> The idea of an ‘Action’ (correct me if I’m wrong) is a suggestion to
> the MTA (or caller) of what to do with a message.. these can be based
> on score (ie hitting a threshold) but what about if it’s a virus and
> you just want to tell the MTA it’s a virus (or has one onboard)
> regardless of score and without changing the score?
There could be other ways to signal such information (integration
dependent): such as added headers or returned symbols.
> FWIW a configtest here with the ‘no_threshold’ and no scores returns
> this:
It's unfortunate as that configuration is indeed fine.
Best,
-AL.
More information about the Users
mailing list