From: Vsevolod Stakhov Date: Sat, 14 Nov 2015 14:17:07 +0000 (+0000) Subject: Allow logging of recipients for a message X-Git-Tag: 1.1.0~557 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b2dd82531c75b396dfffd1814bb33987f18adfe4;p=rspamd.git Allow logging of recipients for a message --- diff --git a/src/libserver/cfg_file.h b/src/libserver/cfg_file.h index 6e87acafe..c70ecddae 100644 --- a/src/libserver/cfg_file.h +++ b/src/libserver/cfg_file.h @@ -180,6 +180,10 @@ enum rspamd_log_format_type { RSPAMD_LOG_DNS_REQ, RSPAMD_LOG_SMTP_FROM, RSPAMD_LOG_MIME_FROM, + RSPAMD_LOG_SMTP_RCPT, + RSPAMD_LOG_MIME_RCPT, + RSPAMD_LOG_SMTP_RCPTS, + RSPAMD_LOG_MIME_RCPTS, RSPAMD_LOG_TIME_REAL, RSPAMD_LOG_TIME_VIRTUAL, RSPAMD_LOG_LUA diff --git a/src/libserver/cfg_utils.c b/src/libserver/cfg_utils.c index acdf8979e..b85534dd7 100644 --- a/src/libserver/cfg_utils.c +++ b/src/libserver/cfg_utils.c @@ -346,6 +346,18 @@ rspamd_config_process_var (struct rspamd_config *cfg, const rspamd_ftok_t *var, else if (rspamd_ftok_cstr_equal (&tok, "mime_from", TRUE)) { type = RSPAMD_LOG_MIME_FROM; } + else if (rspamd_ftok_cstr_equal (&tok, "smtp_rcpt", TRUE)) { + type = RSPAMD_LOG_SMTP_RCPT; + } + else if (rspamd_ftok_cstr_equal (&tok, "mime_rcpt", TRUE)) { + type = RSPAMD_LOG_MIME_RCPT; + } + else if (rspamd_ftok_cstr_equal (&tok, "smtp_rcpts", TRUE)) { + type = RSPAMD_LOG_SMTP_RCPTS; + } + else if (rspamd_ftok_cstr_equal (&tok, "mime_rcpts", TRUE)) { + type = RSPAMD_LOG_MIME_RCPTS; + } else if (rspamd_ftok_cstr_equal (&tok, "time_real", TRUE)) { type = RSPAMD_LOG_TIME_REAL; }