diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-04-16 16:50:26 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-16 16:50:26 +0100 |
commit | 8b4df46cccb8b75338cdc389625501f6b1699b09 (patch) | |
tree | ef21f23f0e9fe3bcdc5670edabc84518a80a1072 | |
parent | a25407b19c0e5ad354f80f6c05a954c9addc4f26 (diff) | |
parent | e7879ae70d28af48a5a52a3cb31fdf81571c7012 (diff) | |
download | rspamd-8b4df46cccb8b75338cdc389625501f6b1699b09.tar.gz rspamd-8b4df46cccb8b75338cdc389625501f6b1699b09.zip |
Merge pull request #2134 from bjoe2k4/patch-4
[Minor] Improve AuthservID generation in AR-header
-rw-r--r-- | lualib/lua_auth_results.lua | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lualib/lua_auth_results.lua b/lualib/lua_auth_results.lua index 92f702950..fcde73e0a 100644 --- a/lualib/lua_auth_results.lua +++ b/lualib/lua_auth_results.lua @@ -16,6 +16,7 @@ limitations under the License. ]]-- local global = require "global_functions" +local rspamd_util = require "rspamd_util" local default_settings = { spf_symbols = { @@ -76,10 +77,9 @@ local function gen_auth_results(task, settings) symbols = {} } - local received = task:get_received_headers() or {} - local mxname = (received[1] or {}).by_hostname - if mxname then - table.insert(hdr_parts, mxname) + local hostname = rspamd_util.get_hostname() + if hostname then + table.insert(hdr_parts, hostname) end for auth_type, symbols in pairs(auth_types) do |