[Rspamd] Fill module name for set_pre_result actions (#6630)

* [Rspamd] Fill module name for postmaster handler

* Update rspamd.local.lua
This commit is contained in:
Dmitriy Alekseev 2025-08-06 09:38:22 +02:00 committed by GitHub
parent e91d678bd1
commit 842cb235b6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -102,7 +102,7 @@ rspamd_config:register_symbol({
local rcpt_split = rspamd_str_split(rcpt['addr'], '@') local rcpt_split = rspamd_str_split(rcpt['addr'], '@')
if #rcpt_split == 2 then if #rcpt_split == 2 then
if rcpt_split[1] == 'postmaster' then if rcpt_split[1] == 'postmaster' then
task:set_pre_result('accept', 'whitelisting postmaster smtp rcpt') task:set_pre_result('accept', 'whitelisting postmaster smtp rcpt', 'postmaster')
return return
end end
end end
@ -167,7 +167,7 @@ rspamd_config:register_symbol({
for k,v in pairs(data) do for k,v in pairs(data) do
if (v and v ~= userdata and v == '1') then if (v and v ~= userdata and v == '1') then
rspamd_logger.infox(rspamd_config, "found ip in keep_spam map, setting pre-result") rspamd_logger.infox(rspamd_config, "found ip in keep_spam map, setting pre-result")
task:set_pre_result('accept', 'ip matched with forward hosts') task:set_pre_result('accept', 'ip matched with forward hosts', 'keep_spam')
end end
end end
end end