[opendmarc-dev] Unit tests
Murray S. Kucherawy
msk at blackops.org
Mon Jul 2 13:27:35 PDT 2012
I've added a unit test framework for opendmarc. For the filter itself,
I copied the test framework from OpenDKIM. It runs a series of shell
scripts which in turn invoke miltertest (an OpenDKIM milter simluator) to
generate various test cases and ensure opendmarc does the right thing.
For the first test case, it injects a mail that claims to be from
paypal.com that contains no signatures and presents no
Authentication-Results fields. I would expect this result to fail the
DMARC test since paypal.com has a DMARC policy of "reject", but the result
from libopendmarc is a "pass".
The order of operations is something like this:
opendmarc_policy_connect_init()
opendmarc_policy_store_from_domain() receives the From: value
opendmarc_get_policy_to_enforce() returns DMARC_POLICY_PASS
Shouldn't this be returning DMARC_POLICY_REJECT?
-MSK
More information about the opendmarc-dev
mailing list