From 9748064889d0ed7b2214d566125bd68e659e57ec Mon Sep 17 00:00:00 2001 From: Daniel B Date: Tue, 3 May 2016 19:35:43 +0200 Subject: [PATCH] Dmarc result note (#261) * Update data_post_headers documentation We cannot reject at this stage, which is only there to alter headers. Fix #258 * DMARC plugin: reject in data_post Followup of #258: we cannot reject a connection during data_post_headers. So add a new hook in data_post to do the real rejection * Add a note with dmarc_result So other plugins can easily check DMARC status. For example, a simple plugin can be added after DMARC when SPF hard failed, but no DMARC policy is published (so no rejection by the DMARC plugin). With this note, we can easily check the result of SPF and DMARC and reject if the first is failed, and the second is none --- plugins/dmarc | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/dmarc b/plugins/dmarc index b055335..b0437ce 100644 --- a/plugins/dmarc +++ b/plugins/dmarc @@ -154,6 +154,7 @@ sub check_dmarc { }; }; + $transaction->notes('dmarc_result', $dmarc->result); my $disposition = $dmarc->result->disposition; my $result = $dmarc->result->result; my $auth_str = "dmarc=$result";