commit 59b5ff6: [Minor] lua_scanners - icap check empty key
Carsten Rosenberg
c.rosenberg at heinlein-support.de
Mon Jan 28 12:35:07 UTC 2019
Author: Carsten Rosenberg
Date: 2019-01-26 13:49:02 +0100
URL: https://github.com/rspamd/rspamd/commit/59b5ff6ccc8182a23beaf5774263f175e8cf7cef (refs/pull/2736/head)
[Minor] lua_scanners - icap check empty key
---
lualib/lua_scanners/icap.lua | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/lualib/lua_scanners/icap.lua b/lualib/lua_scanners/icap.lua
index 801db72f6..6ddd5fee6 100644
--- a/lualib/lua_scanners/icap.lua
+++ b/lualib/lua_scanners/icap.lua
@@ -69,7 +69,9 @@ local function icap_check(task, content, digest, rule)
end
if string.find(s, '[%a%d-+]-:') then
local _,_,key,value = tostring(s):find("([%a%d-+]-):%s?(.+)")
- icap_headers[key] = value
+ if key ~= nil then
+ icap_headers[key] = value
+ end
end
end
lua_util.debugm(rule.name, task, '%s: icap_headers: %s',
More information about the Commits
mailing list