summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-12-17 12:32:39 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-12-17 12:32:39 +0000
commitd6003a3997a914b9441a57281061dbaa3de26f08 (patch)
tree94cd143d6cf59dac85ae68642b81a56ac5447462
parent3f83c2f80c545daeb858801cbef6ad7c5a9c5198 (diff)
downloadrspamd-d6003a3997a914b9441a57281061dbaa3de26f08.tar.gz
rspamd-d6003a3997a914b9441a57281061dbaa3de26f08.zip
[Minor] Lua_task: Store raw header when getting full header data
-rw-r--r--src/lua/lua_task.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lua/lua_task.c b/src/lua/lua_task.c
index 737f86802..e9ac358d8 100644
--- a/src/lua/lua_task.c
+++ b/src/lua/lua_task.c
@@ -2108,6 +2108,12 @@ rspamd_lua_push_header (lua_State *L, struct rspamd_mime_header *rh,
rspamd_lua_table_set (L, "value", rh->value);
}
+ if (rh->raw_len > 0) {
+ lua_pushstring (L, "raw");
+ lua_pushlstring (L, rh->raw_value, rh->raw_len);
+ lua_settable (L, -3);
+ }
+
if (rh->decoded) {
rspamd_lua_table_set (L, "decoded", rh->decoded);
}