diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-10-23 16:08:24 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-10-23 16:33:06 +0100 |
commit | 01036d24ca7794ac7ad7be407798806f4eac54ce (patch) | |
tree | dd6a3ecb15d2b28f4efbe5b1f369f61e6827f2c2 /src/plugins | |
parent | 5fd920c6deed2953a49ceca2ba6fe6be1ce50181 (diff) | |
download | rspamd-01036d24ca7794ac7ad7be407798806f4eac54ce.tar.gz rspamd-01036d24ca7794ac7ad7be407798806f4eac54ce.zip |
[Feature] Fold b= value when doing arc sealing
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/lua/arc.lua | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/plugins/lua/arc.lua b/src/plugins/lua/arc.lua index e066613e9..d5ee1b514 100644 --- a/src/plugins/lua/arc.lua +++ b/src/plugins/lua/arc.lua @@ -483,9 +483,15 @@ local function arc_sign_seal(task, params, header) sha_ctx:update(s) lua_util.debugm(N, task, 'initial update signature with header: %s', s) + local nl_type = 'crlf' + if task:has_flag("milter") then + nl_type = "lf" + else + nl_type = task:get_newlines_type() + end local sig = rspamd_rsa.sign_memory(privkey, sha_ctx:bin()) cur_arc_seal = string.format('%s%s', cur_arc_seal, - sig:base64()) + sig:base64(70, nl_type)) task:set_milter_reply({ add_headers = { |