Skip to content

Commit

Permalink
Add the dmarc_reject note on the transaction
Browse files Browse the repository at this point in the history
It's probably possible to have one valid email after an invalid one using the same connection (even if not common)
  • Loading branch information
Daniel Berteaud committed May 3, 2016
1 parent d3bc142 commit 4468c32
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/dmarc
Original file line number Diff line number Diff line change
Expand Up @@ -191,12 +191,12 @@ sub check_dmarc {

$self->adjust_karma(-3);
# Add a mark now so the data_post hook can do the real reject
$self->connection->notes('reject_dmarc', '1');
$transaction->notes('reject_dmarc', '1');
}

sub reject_dmarc {
my ($self, $transaction) = @_;
return $self->get_reject("failed DMARC policy")
if ($self->connection->notes('reject_dmarc'));
if ($transaction->notes('reject_dmarc'));
return DECLINED;
}

0 comments on commit 4468c32

Please sign in to comment.