local fun = require "fun"
local auth_results = require "lua_auth_results"
local hash = require "rspamd_cryptobox_hash"
+local lua_mime = require "lua_mime"
if confighelp then
return
cur_arc_seal = string.format('%s%s', cur_arc_seal,
sig:base64(70, nl_type))
- task:set_milter_reply({
- add_headers = {
+ lua_mime.modify_headers(task, {
+ add = {
['ARC-Authentication-Results'] = {order = 1, value = cur_auth_results},
['ARC-Message-Signature'] = {order = 1, value = header},
['ARC-Seal'] = {order = 1, value = lua_util.fold_header(task,
- 'ARC-Seal', cur_arc_seal) }
+ 'ARC-Seal', cur_arc_seal) }
}
})
task:insert_result(settings.sign_symbol, 1.0,
local rspamd_logger = require "rspamd_logger"
local dkim_sign_tools = require "lua_dkim_tools"
local lua_redis = require "lua_redis"
+local lua_mime = require "lua_mime"
if confighelp then
return
local function insert_sign_results(task, ret, hdr, dkim_params)
if settings.use_milter_headers then
- task:set_milter_reply({
- add_headers = {
+ lua_mime.modify_headers(task, {
+ add = {
['DKIM-Signature'] = {order = 1, value = hdr},
}
})
local N = 'milter_headers'
local lua_util = require "lua_util"
local lua_maps = require "lua_maps"
+local lua_mime = require "lua_mime"
local ts = require("tableshape").types
local E = {}
if not next(add) then add = nil end
if not next(remove) then remove = nil end
if add or remove then
- task:set_milter_reply({
- add_headers = add,
- remove_headers = remove
+
+ lua_mime.modify_headers(task, {
+ add = add,
+ remove = remove
})
end
end