diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-01-18 14:55:00 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-01-18 14:55:00 +0000 |
commit | c361d5a35f5e64d3ea429f6358cdc078c29a15c8 (patch) | |
tree | ba97e3b0d8966e81b68510e8be92654759fdfd50 /src/plugins/lua/external_services.lua | |
parent | dd4ad1e446ebd8e804bd14714e3a4c565a8ddece (diff) | |
download | rspamd-c361d5a35f5e64d3ea429f6358cdc078c29a15c8.tar.gz rspamd-c361d5a35f5e64d3ea429f6358cdc078c29a15c8.zip |
[Minor] Lua_scanners: Various fixes in VadeSecure plugin
Diffstat (limited to 'src/plugins/lua/external_services.lua')
-rw-r--r-- | src/plugins/lua/external_services.lua | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/plugins/lua/external_services.lua b/src/plugins/lua/external_services.lua index 6ee0535ba..c5889112f 100644 --- a/src/plugins/lua/external_services.lua +++ b/src/plugins/lua/external_services.lua @@ -251,7 +251,25 @@ if opts and type(opts) == 'table' then group = N }) elseif type(sym) == 'table' then - reg_symbols(sym) + if sym.symbol then + rspamd_config:register_symbol({ + type = 'virtual', + name = sym.symbol, + parent = id, + group = N + }) + + if sym.score then + rspamd_config:set_metric_symbol({ + name = sym.symbol, + score = sym.score, + description = sym.description, + group = sym.group or N, + }) + end + else + reg_symbols(sym) + end end end end |