diff options
author | Carsten Rosenberg <c.rosenberg@heinlein-support.de> | 2019-01-16 20:44:01 +0100 |
---|---|---|
committer | Carsten Rosenberg <c.rosenberg@heinlein-support.de> | 2019-01-16 20:44:01 +0100 |
commit | 44de7f58793a846a36b9eaf4c459c035e7d9cfb2 (patch) | |
tree | baa0be9a0dc38fc66fbae6793c9d34b6b5a1e143 /lualib/lua_scanners/fprot.lua | |
parent | 42bde308e2975fc02f41ce348cd857eff46c70fb (diff) | |
download | rspamd-44de7f58793a846a36b9eaf4c459c035e7d9cfb2.tar.gz rspamd-44de7f58793a846a36b9eaf4c459c035e7d9cfb2.zip |
[FIX] lua_scanners - using N is much smarter ;)
Diffstat (limited to 'lualib/lua_scanners/fprot.lua')
-rw-r--r-- | lualib/lua_scanners/fprot.lua | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lualib/lua_scanners/fprot.lua b/lualib/lua_scanners/fprot.lua index b56187c8c..2004d8aa0 100644 --- a/lualib/lua_scanners/fprot.lua +++ b/lualib/lua_scanners/fprot.lua @@ -25,13 +25,13 @@ local upstream_list = require "rspamd_upstream_list" local rspamd_logger = require "rspamd_logger" local common = require "lua_scanners/common" -local module_name = "fprot" +local N = "fprot" local default_message = '${SCANNER}: virus found: "${VIRUS}"' local function fprot_config(opts) local fprot_conf = { - module_name = module_name, + N = N, scan_mime_parts = true, scan_text_mime = false, scan_image_mime = false, @@ -69,7 +69,7 @@ local function fprot_config(opts) fprot_conf.default_port) if fprot_conf['upstreams'] then - lua_util.add_debug_alias('antivirus', fprot_conf.module_name) + lua_util.add_debug_alias('antivirus', fprot_conf.N) return fprot_conf end @@ -103,7 +103,7 @@ local function fprot_check(task, content, digest, rule) upstream = rule.upstreams:get_upstream_round_robin() addr = upstream:get_addr() - lua_util.debugm(rule.module_name, task, '%s [%s]: retry IP: %s', rule['symbol'], rule['type'], addr) + lua_util.debugm(rule.N, task, '%s [%s]: retry IP: %s', rule['symbol'], rule['type'], addr) tcp.request({ task = task, @@ -175,5 +175,5 @@ return { description = 'fprot antivirus', configure = fprot_config, check = fprot_check, - name = module_name + name = N } |