From: Vsevolod Stakhov Date: Tue, 17 Jul 2018 13:40:20 +0000 (+0100) Subject: [Fix] Prefer 'MTA-Name' when producing authentication results X-Git-Tag: 1.7.9~105 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=c5663c16fe578d09487c1402d2c2ccc5350d94e5;p=rspamd.git [Fix] Prefer 'MTA-Name' when producing authentication results --- diff --git a/lualib/lua_auth_results.lua b/lualib/lua_auth_results.lua index 3f604d760..4f4736ff1 100644 --- a/lualib/lua_auth_results.lua +++ b/lualib/lua_auth_results.lua @@ -78,7 +78,8 @@ local function gen_auth_results(task, settings) symbols = {} } - local mta_hostname = task:get_request_header('MTA-Tag') + local mta_hostname = task:get_request_header('MTA-Name') or + task:get_request_header('MTA-Tag') if mta_hostname then table.insert(hdr_parts, tostring(mta_hostname)) else diff --git a/src/libserver/milter.c b/src/libserver/milter.c index b6294d999..b44856028 100644 --- a/src/libserver/milter.c +++ b/src/libserver/milter.c @@ -1318,11 +1318,6 @@ rspamd_milter_macro_http (struct rspamd_milter_session *session, } } - IF_MACRO("{daemon_name}") { - rspamd_http_message_add_header_len (msg, MTA_TAG_HEADER, - found->begin, found->len); - } - IF_MACRO("{v}") { rspamd_http_message_add_header_len (msg, USER_AGENT_HEADER, found->begin, found->len);