test(email): give the exact authserv-id pin rows a passing verdict
Every topmost row carried dmarc=fail, so it failed on its verdict no matter what the pin check did: restoring subdomain alignment on the topmost field kept the test green (gate 2ab Low finding). The subdomain and comment-smuggled rows now say dmarc=pass, so only the exact pin rejects them and that mutation goes red.
This commit is contained in:
@@ -1367,13 +1367,14 @@ class TestSenderAuthentication(unittest.TestCase):
|
||||
|
||||
|
||||
def test_only_topmost_exact_authserv_id_is_trusted(self):
|
||||
"""Never search below the authoritative field or relax an authserv-id pin."""
|
||||
"""Never search below the authoritative field or relax an authserv-id pin.
|
||||
The subdomain and comment-smuggled rows carry dmarc=pass, so only the exact pin rejects them."""
|
||||
forged_lower = "mx.ourserver.com; dmarc=pass header.from=example.com"
|
||||
for topmost in (
|
||||
"mx.ourserver.com; dmarc=fail header.from=example.com",
|
||||
"edge.receiver.test; dmarc=fail header.from=example.com",
|
||||
"child.mx.ourserver.com; dmarc=fail header.from=example.com",
|
||||
"(mx.ourserver.com) edge.receiver.test; dmarc=fail header.from=example.com",
|
||||
"child.mx.ourserver.com; dmarc=pass header.from=example.com",
|
||||
"(mx.ourserver.com) edge.receiver.test; dmarc=pass header.from=example.com",
|
||||
):
|
||||
with self.subTest(topmost=topmost):
|
||||
ok, reason = self._verify(
|
||||
|
||||
Reference in New Issue
Block a user