]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
Skipping check_received function for ip address if RBL use botch checks, 'from' and...
authorMike Teplynin <mike@teplynin.com>
Fri, 13 Dec 2024 17:20:15 +0000 (20:20 +0300)
committerMike Teplynin <mike@teplynin.com>
Fri, 13 Dec 2024 17:20:15 +0000 (20:20 +0300)
src/plugins/lua/rbl.lua

index 8126e9c8f73a08801603efe7da6ebc4c2b00be4b..a5c8346c82c1ba074013c74435abf9b1abdaf1db 100644 (file)
@@ -693,12 +693,12 @@ local function gen_rbl_callback(rule)
 
     for pos, rh in ipairs(received) do
       if check_conditions(rh, pos) then
-        if rh.real_ip ~= from_ip then
+        if rh.real_ip ~= from_ip or (rh.real_ip == from_ip and not rule.from) then
           add_dns_request(task, rh.real_ip, false, true,
               requests_table, 'received',
               whitelist)
         else
-          lua_util.debugm(N, task, 'Received IP same as From IP, skipping extra check')
+          lua_util.debugm(N, task, 'rbl %s; skip check_received for %s: Received IP same as From IP and will be checked only in check_from function', rule.symbol, rh.real_ip)
         end
       end
     end