From 28d3143551376428e17505ddbd43326662445734 Mon Sep 17 00:00:00 2001 From: Andrew Lewis Date: Mon, 13 Feb 2017 18:45:02 +0200 Subject: [Minor] Filter artificial Received header in multimap by default - Also filter headers in CHECK_RECEIVED rule --- src/plugins/lua/multimap.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/plugins/lua') diff --git a/src/plugins/lua/multimap.lua b/src/plugins/lua/multimap.lua index bdd9d3069..5afada789 100644 --- a/src/plugins/lua/multimap.lua +++ b/src/plugins/lua/multimap.lua @@ -712,6 +712,11 @@ local function multimap_callback(task, rule) received = function() local hdrs = task:get_received_headers() if hdrs and hdrs[1] then + if not rule['artificial'] then + hdrs = fun.filter(function(h) + return not h['artificial'] + end, hdrs):totable() + end for pos, h in ipairs(hdrs) do match_received_header(rule, pos, #hdrs, h) end -- cgit v1.2.3