]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] received: filtering of artificial header 4367/head
authorKako, Chang <49464540+kakochang@users.noreply.github.com>
Thu, 12 Jan 2023 06:12:01 +0000 (14:12 +0800)
committerKako, Chang <49464540+kakochang@users.noreply.github.com>
Thu, 12 Jan 2023 06:12:01 +0000 (14:12 +0800)
rules/headers_checks.lua
src/plugins/lua/once_received.lua

index d8884700313c63b742506a5b9884f6c0e728ce55..7a02bc2ebc1531df6a61a4c730e6d13cd62860ae 100644 (file)
@@ -42,7 +42,7 @@ local rcvd_cb_id = rspamd_config:register_symbol{
     local nreceived = fun.reduce(function(acc, rcvd)
         return acc + 1
       end, 0, fun.filter(function(h)
-        return not h['artificial']
+        return not h['flags']['artificial']
       end, received))
 
     for k,v in pairs(cnts) do
index 0fe738d630148da016e014578dd7f1edbe5800d0..04e2168c15609179f855437416f672da4b467183 100644 (file)
@@ -44,7 +44,7 @@ local function check_quantity_received (task)
   local nreceived = fun.reduce(function(acc, _)
     return acc + 1
   end, 0, fun.filter(function(h)
-    return not h['artificial']
+    return not h['flags']['artificial']
   end, recvh))
 
   local function recv_dns_cb(_, to_resolve, results, err)