diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-09-09 16:37:27 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-09 16:37:27 +0100 |
commit | 04abba6b321214191d9f3d1e87695d14405af196 (patch) | |
tree | 26e1974f7b6583504eea4f9eba7ba4411ea40c6b /src | |
parent | c029c744d276bc900b1a11132d118f66190b684d (diff) | |
parent | e3a75b43e5d59de7bccc1795757f648c5598ff8a (diff) | |
download | rspamd-04abba6b321214191d9f3d1e87695d14405af196.tar.gz rspamd-04abba6b321214191d9f3d1e87695d14405af196.zip |
Merge pull request #939 from fatalbanana/hfilter
[Minor] Mostly disable Hfilter for local networks as well
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/lua/hfilter.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/lua/hfilter.lua b/src/plugins/lua/hfilter.lua index 34a679641..c1d0e22b2 100644 --- a/src/plugins/lua/hfilter.lua +++ b/src/plugins/lua/hfilter.lua @@ -294,14 +294,14 @@ local function hfilter(task) end end - --No more checks for auth user - if task:get_user() ~= nil then + --No more checks for auth user or local network + local rip = task:get_from_ip() + if task:get_user() or (rip and rip:is_local()) then return false end --local message = task:get_message() local ip = false - local rip = task:get_from_ip() if rip and rip:is_valid() then ip = rip:to_string() end |