Skip to content

Commit

Permalink
Updated ARC
Browse files Browse the repository at this point in the history
  • Loading branch information
Spitfireap committed Dec 18, 2024
1 parent 7a9842b commit 8ebf7a1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 18 deletions.
3 changes: 3 additions & 0 deletions modoboa_installer/scripts/files/rspamd/local.d/arc.conf.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
try_fallback = false;
selector_map = "%selector_map_path";
path_map = "%key_map_path";
Original file line number Diff line number Diff line change
@@ -1,25 +1,8 @@
use = ["x-spam-status", "my-x-spam-score" ,"x-virus","authentication-results" ];
use = ["x-spam-status","x-virus","authentication-results" ];
extended_spam_headers = false;
skip_local = false;
skip_authenticated = false;

# Write the score as a header
custom {
my-x-spam-score = <<EOD
return function(task, common_meta)
local sc = common_meta['metric_score'] or task:get_metric_score()
-- return no error
return nil,
-- header(s) to add
{['X-Spam-Score'] = string.format('%%.2f', sc[1])},
-- header(s) to remove
{['X-Spam-Score'] = 1},
-- metadata to store
{}
end
EOD;
}

routines {
x-virus {
header = "X-Virus";
Expand Down

0 comments on commit 8ebf7a1

Please sign in to comment.