]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] RBL: Fix behaviour of emails_domainonly
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 30 Sep 2019 15:07:22 +0000 (16:07 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 30 Sep 2019 15:07:22 +0000 (16:07 +0100)
src/plugins/lua/rbl.lua

index cf474f69c5e6ab5bd4382a084cd7b788498b8b8b..59ac8f7e1a6ef08e3a540aa329bdebf965cb2d34 100644 (file)
@@ -589,7 +589,7 @@ local function gen_rbl_callback(rule)
 
     for _,email in ipairs(emails) do
       local email_tbl = {
-        domain = email:get_tld(),
+        domain = (rule.emails_domainonly and email:get_tld()) or email:get_host(),
         user = email:get_user(),
         addr = tostring(email),
       }