From 45a93b53b20a901db7cb2d473eb460083ae1e8a9 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Sun, 11 Jun 2017 11:59:17 +0100 Subject: [Fix] Fix arc count logic --- src/plugins/lua/arc.lua | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/plugins/lua/arc.lua b/src/plugins/lua/arc.lua index fc1c65769..c61423176 100644 --- a/src/plugins/lua/arc.lua +++ b/src/plugins/lua/arc.lua @@ -217,7 +217,9 @@ local function arc_callback(task) task:insert_result(arc_symbols['allow'], 1.0, 'i=' .. tostring(cbdata.checked)) else - task:insert_result(arc_symbols['reject'], 1.0, cbdata.errors) + task:insert_result(arc_symbols['reject'], 1.0, + rspamd_logger.slog('seal check failed: %s, %s', cbdata.res, + cbdata.errors)) end end end @@ -251,7 +253,9 @@ local function arc_callback(task) end end, cbdata.seals) else - task:insert_result(arc_symbols['reject'], 1.0, cbdata.errors) + task:insert_result(arc_symbols['reject'], 1.0, + rspamd_logger.slog('signature check failed: %s, %s', cbdata.res, + cbdata.errors)) end end end @@ -270,8 +274,10 @@ local function arc_callback(task) end end, cbdata.sigs) - if cbdata.checked == #arc_sig_headers then - task:insert_result(arc_symbols['reject'], 1.0, cbdata.errors) + if cbdata.checked ~= #arc_sig_headers then + task:insert_result(arc_symbols['reject'], 1.0, + rspamd_logger.slog('cannot verify %s of signatures: %s', + #arc_sig_headers - cbdata.checked, cbdata.errors)) end end -- cgit v1.2.3