aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/lua/multimap.lua
diff options
context:
space:
mode:
authorAndrew Lewis <nerf@judo.za.org>2017-05-09 14:19:55 +0200
committerAndrew Lewis <nerf@judo.za.org>2017-05-09 14:19:55 +0200
commit27d6bffa5b295e0fbca6d3eda0ee17c834fede81 (patch)
tree045214894712eadbc0b74889eb7e5f422c6c10bf /src/plugins/lua/multimap.lua
parentc6770e9d07b5de9ade6578d09e4b9ca119e5a431 (diff)
downloadrspamd-27d6bffa5b295e0fbca6d3eda0ee17c834fede81.tar.gz
rspamd-27d6bffa5b295e0fbca6d3eda0ee17c834fede81.zip
[Fix] Multimap: Received IP filters with Redis
- Issue: #1623 - Reported by: @andryyy
Diffstat (limited to 'src/plugins/lua/multimap.lua')
-rw-r--r--src/plugins/lua/multimap.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/lua/multimap.lua b/src/plugins/lua/multimap.lua
index ae63b47bd..1db4b7967 100644
--- a/src/plugins/lua/multimap.lua
+++ b/src/plugins/lua/multimap.lua
@@ -373,7 +373,8 @@ local function multimap_callback(task, rule)
ret = r['cdb']:lookup(srch)
elseif r['redis_key'] then
local srch = value
- if r['type'] == 'ip' then
+ if r['type'] == 'ip' or (r['type'] == 'received' and
+ (r['filter'] == 'real_ip' or r['filter'] == 'from_ip' or not r['filter'])) then
srch = value:to_string()
end
ret = rspamd_redis_make_request(task,