Day 3 · Sender authentication
DMARC explained: alignment, policies, RFC 9989 and reading reports
Course contents
SPF checks the envelope sender. DKIM checks whichever domain signed. Neither checks the one address a human actually reads: the From header. DMARC (Domain-based Message Authentication, Reporting and Conformance) closes that gap. A domain publishes a DMARC record that says three things: “mail with my domain in From must pass SPF or DKIM for my domain”, “here’s what to do with mail that doesn’t”, and “send me reports about all the mail you see using my domain”. It is the protocol that actually stops exact-domain spoofing, and the reports are the best map you’ll ever get of who sends mail as your domain.
Where DMARC stands in 2026
DMARC was first published in 2015 as RFC 7489, an informational document. In May 2026 the IETF replaced it with a proper standard in three parts: RFC 9989 (the protocol), RFC 9990 (aggregate reports) and RFC 9991 (failure reports). Existing records keep working (they still start with v=DMARC1), but a few things changed, and this lesson teaches the current version while pointing out what’s different from older guides:
- The
pcttag is gone (along with the rarely usedrfandri). A newttag (testing) replaces its only common use. - The organizational domain is found with a DNS tree walk instead of the Public Suffix List.
- New tags
np(policy for non-existent subdomains) andpsd(for public suffix operators) are now part of the standard.
DMARC is also no longer optional for senders at scale: Gmail and Yahoo have required it from bulk senders since February 2024, and Outlook.com since May 2025 (lesson 13).
Alignment: the core idea
DMARC passes when at least one of these is true:
- SPF passes, and the domain SPF checked (the MAIL FROM domain) aligns with the From domain, or
- DKIM passes for a signature whose
d=domain aligns with the From domain.
“Aligns” comes in two modes, set separately for SPF (aspf) and DKIM (adkim):
- relaxed (the default): the two domains have the same organizational domain.
bounces.example.comaligns withexample.com, andmail.example.comaligns withnews.example.com. - strict: the two domains must be identical.
| From domain | Passing domain | Relaxed | Strict |
|---|---|---|---|
example.com | SPF: example.com | aligned | aligned |
example.com | SPF: bounces.example.com | aligned | not aligned |
news.example.com | DKIM: d=example.com | aligned | not aligned |
example.com | DKIM: d=sendgrid.info | not aligned | not aligned |
example.com | SPF: example.net | not aligned | not aligned |
example.co.uk | DKIM: d=other.co.uk | not aligned (co.uk is a public suffix) | not aligned |
The organizational domain is the domain just below a public suffix: example.com, example.co.uk. Under RFC 9989, receivers find it with a tree walk: they look for DMARC records from the domain upward (_dmarc.a.b.example.com, _dmarc.b.example.com, _dmarc.example.com, …), using psd=y records published by public suffix operators to know where to stop, instead of a downloaded list of suffixes.
The DMARC record
DMARC lives in a TXT record at _dmarc.<domain>:
_dmarc.example.com. TXT "v=DMARC1; p=reject; sp=reject; np=reject; adkim=r; aspf=r; rua=mailto:dmarc-reports@example.com"
| Tag | Meaning |
|---|---|
v=DMARC1 | Version. Must come first |
p= | Policy for the domain: none, quarantine or reject |
sp= | Policy for existing subdomains (defaults to p) |
np= | Policy for non-existent subdomains (random123.example.com), a favorite of spoofers. Defaults to sp, then p |
adkim=, aspf= | Alignment mode for DKIM and SPF: r (relaxed, default) or s (strict) |
rua= | Where to send aggregate reports: mailto: addresses, comma-separated |
ruf= | Where to send failure reports (per message; few providers send them) |
fo= | When to send failure reports: 0 (all mechanisms failed, default), 1 (any failed), d, s |
t= | Testing (new in RFC 9989): t=y asks receivers to apply one level less than p (quarantine → none, reject → quarantine) |
psd= | For public suffix operators (y), or n to declare “I am an organizational domain” |
pct=, rf=, ri= | Historic since RFC 9989. Old receivers may still honor pct; new ones ignore all three |
What the three policies mean in practice:
p=none: monitor only. Receivers apply their usual filtering and send you reports. Every DMARC deployment starts here, but it protects nothing.p=quarantine: treat failing mail as suspicious: usually the spam folder.p=reject: refuse failing mail during the SMTP session. Gmail, for example, answers550 5.7.26 Unauthenticated email from example.com is not accepted due to domain's DMARC policy.
Receivers may still override your policy with local knowledge (a trusted forwarder, a mailing list with valid ARC), and they report when they do.
Here are some real records:
dig +short _dmarc.paypal.com TXT
dig +short _dmarc.yahoo.com TXT
dig +short _dmarc.gmail.com TXT
dig +short _dmarc.outlook.com TXT
"v=DMARC1; p=reject; rua=mailto:d@rua.agari.com,mailto:dmarc_agg@vali.email; ruf=mailto:d@ruf.agari.com,mailto:MTc4Mzcw@ruf.vali.email"
"v=DMARC1; p=reject; pct=100; rua=mailto:d@rua.agari.com; ruf=mailto:d@ruf.agari.com;"
"v=DMARC1; p=none; sp=quarantine; rua=mailto:mailauth-reports@google.com"
"v=DMARC1; p=none; sp=quarantine; pct=100; rua=mailto:rua@dmarc.microsoft; ruf=mailto:ruf@dmarc.microsoft; fo=1"
PayPal, the most phished brand for years, rejects everything that fails. Yahoo was the first big mailbox provider to publish p=reject, in 2014. Gmail and Outlook.com keep p=none on their consumer domains, where millions of people’s addresses are used in all kinds of third-party systems, but quarantine their subdomains. Several records use outside companies (Agari, Valimail) to collect and analyze reports.
Reports
Aggregate reports (rua)
Every receiver that supports DMARC reporting (Google, Microsoft, Yahoo, and many others) sends, usually once a day, a compressed XML file summarizing all the mail it saw with your domain in From: grouped by sending IP, with counts and the SPF, DKIM and DMARC results. No message content, no recipient addresses. These reports are how you find every system that sends as your domain, including the ones nobody told IT about.
Reports for a big domain are too many to read by hand. Send them to a DMARC reporting service (many have free tiers) or run an open-source parser such as parsedmarc, which feeds the results into Elasticsearch or similar for dashboards.
If rua points to a mailbox at another domain (a reporting vendor), that domain must publish a record authorizing it, or receivers won’t send: example.com._report._dmarc.vendor.example TXT "v=DMARC1". Vendors handle this for their customers.
Failure reports (ruf)
Failure reports (RFC 9991) describe individual failing messages, sometimes with headers or content. Because they can contain personal data, Gmail and most large providers don’t send them at all. Don’t count on them.
Rolling out DMARC without breaking mail
- Publish
p=nonewithrua. Nothing changes for delivery; reports start arriving within a day or two. - Collect for two to four weeks, long enough to see monthly senders (invoicing runs, newsletters).
- Make every legitimate source align. For each sender in the reports: enable DKIM with your domain (hosted providers, ESPs, CRMs, helpdesks), set a custom return-path where possible, add it to SPF. Sources that can’t do either should send from their own domain or through your systems.
- Move to quarantine, carefully. With RFC 9989,
p=quarantine; t=yasks receivers to only monitor (one level down) while you check the reports with the new policy in place; then removet=y. (Older guides usepct=10,pct=50and so on for a gradual ramp; that tag is historic now and new receivers ignore it.) - Move to
p=rejectonce the reports show only legitimate, aligned mail failing nothing that matters. Addsp=reject(or rely on the default) andnp=reject. - Keep reading reports forever: new SaaS tools, a new marketing agency, a misconfigured server. Monitoring is not a phase.
For domains that never send mail, skip all of this and go straight to p=reject (lesson 5).
Mailing lists and forwarding
DMARC’s weak spot is legitimate mail that changes along the way. A mailing list that adds a footer breaks the DKIM signature, and resends from its own server, so SPF doesn’t align either: a message from alice@yahoo.com to a list would fail DMARC for every list subscriber. When Yahoo and AOL moved to p=reject in 2014, mailing lists across the Internet had to adapt. The standard fixes, both on the list’s side:
- From rewriting: the list sends the message as
From: "Alice via Gardening List" <gardening@lists.example.org>withReply-To: alice@yahoo.com. Mailman, Google Groups and others do this automatically for domains with strict policies. - ARC (next lesson): the list records the authentication results it saw, signs them, and receivers that trust the list can accept the message despite the DMARC failure.
What the receiver writes
Authentication-Results: mx.google.com;
dkim=pass header.i=@example.com header.s=google header.b=Ab3dEf9h;
spf=pass (google.com: domain of alice@example.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=alice@example.com;
dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=example.com
dmarc=pass, the policy the receiver found (p=REJECT), the action it took (dis=NONE: delivered normally) and header.from, the domain it protected. When you troubleshoot, put smtp.mailfrom, header.i (or d= in the signature) and header.from side by side: alignment problems jump out.