local received_total = #received
local check_conditions = gen_check_rcvd_conditions(rule, received_total)
+ local from_ip = task:get_from_ip()
for pos, rh in ipairs(received) do
if check_conditions(rh, pos) then
- add_dns_request(task, rh.real_ip, false, true,
- requests_table, 'received',
- whitelist)
+ if rh.real_ip ~= from_ip 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')
+ end
end
end