summaryrefslogtreecommitdiffstats
path: root/lualib/lua_scanners
diff options
context:
space:
mode:
authorCarsten Rosenberg <c.rosenberg@heinlein-support.de>2019-01-13 16:05:13 +0100
committerCarsten Rosenberg <c.rosenberg@heinlein-support.de>2019-01-13 16:05:13 +0100
commitd68a5f42a33d8830d268c2cc581469fa0381fa6c (patch)
tree9a9727168693a48583fba1bcbf4d8a0af3ba25fb /lualib/lua_scanners
parent92ec1c97019c4a5547c115a90e00b257399a8a47 (diff)
downloadrspamd-d68a5f42a33d8830d268c2cc581469fa0381fa6c.tar.gz
rspamd-d68a5f42a33d8830d268c2cc581469fa0381fa6c.zip
[Fix] lua_scanners - fix luacheck
Diffstat (limited to 'lualib/lua_scanners')
-rw-r--r--lualib/lua_scanners/common.lua2
-rw-r--r--lualib/lua_scanners/oletools.lua1
-rw-r--r--lualib/lua_scanners/sophos.lua4
3 files changed, 3 insertions, 4 deletions
diff --git a/lualib/lua_scanners/common.lua b/lualib/lua_scanners/common.lua
index 1fe82fabb..43400c375 100644
--- a/lualib/lua_scanners/common.lua
+++ b/lualib/lua_scanners/common.lua
@@ -180,7 +180,7 @@ local function save_av_cache(task, digest, rule, to_save, dyn_weight)
return false
end
-local function create_regex_table(task, patterns)
+local function create_regex_table(patterns)
local regex_table = {}
if patterns[1] then
for i, p in ipairs(patterns) do
diff --git a/lualib/lua_scanners/oletools.lua b/lualib/lua_scanners/oletools.lua
index fd2775775..814fe368e 100644
--- a/lualib/lua_scanners/oletools.lua
+++ b/lualib/lua_scanners/oletools.lua
@@ -27,7 +27,6 @@ local upstream_list = require "rspamd_upstream_list"
local rspamd_logger = require "rspamd_logger"
local ucl = require "ucl"
local common = require "lua_scanners/common"
-local fun = require "fun"
local module_name = 'oletools'
diff --git a/lualib/lua_scanners/sophos.lua b/lualib/lua_scanners/sophos.lua
index 0f874e756..d0297fa97 100644
--- a/lualib/lua_scanners/sophos.lua
+++ b/lualib/lua_scanners/sophos.lua
@@ -129,9 +129,9 @@ local function sophos_check(task, content, digest, rule)
else
if string.find(data, 'DONE OK') then
if rule['log_clean'] then
- rspamd_logger.infox(task, '%s [%s]: message or mime_part is clean', rule['symbol'], rule['type'])
+ rspamd_logger.infox(task, '%s: message or mime_part is clean', rule.log_prefix)
else
- lua_util.debugm(rule.module_name, task, '%s [%s]: message or mime_part is clean', rule['symbol'], rule['type'])
+ lua_util.debugm(rule.module_name, task, '%s: message or mime_part is clean', rule.log_prefix)
end
common.save_av_cache(task, digest, rule, 'OK')
-- not finished - continue