commit d23dfcf: [Fix] External_relay: Remove useless check of the map value

Vsevolod Stakhov vsevolod at highsecure.ru
Wed Feb 16 21:21:04 UTC 2022


Author: Vsevolod Stakhov
Date: 2022-02-16 21:18:47 +0000
URL: https://github.com/rspamd/rspamd/commit/d23dfcf2cd1fdec36e51268718f2e7b198900992 (HEAD -> master)

[Fix] External_relay: Remove useless check of the map value
Issue: #4080

---
 src/plugins/lua/external_relay.lua | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/src/plugins/lua/external_relay.lua b/src/plugins/lua/external_relay.lua
index 8b20bbe82..31f6a1037 100644
--- a/src/plugins/lua/external_relay.lua
+++ b/src/plugins/lua/external_relay.lua
@@ -159,11 +159,6 @@ strategies.hostname_map = function(rule)
       return
     end
 
-    if hostname_map:get_key(from_hn) ~= 'direct' then
-      lua_util.debugm(N, task, 'sending hostname (%s) is not a direct relay', from_hn)
-      return
-    end
-
     local rcvd_hdrs = task:get_received_headers()
     -- Try find sending hostname in Received headers
     for _, rcvd in ipairs(rcvd_hdrs) do


More information about the Commits mailing list