Email posture hardening checklist

    SPF, DKIM and DMARC decide whether a stranger can send mail that appears to come from your domain. Most organisations have all three and are still spoofable, because the records are published but not enforced. This checklist goes in deployment order and ends where it matters — moving DMARC to enforcement without losing legitimate mail.

    Step 0 — find every system that sends as you

    This step is skipped more often than any other, and skipping it is why DMARC enforcement breaks mail. Your mail platform is rarely the only sender. Payroll, the CRM, the ticketing system, invoicing, the marketing tool, the monitoring alerts and the recruitment portal all send as your domain, often through third parties nobody in IT chose. List them before you touch a record. Anything you miss here is what stops working the day you turn enforcement on.

    Step 1 — SPF, and the ten-lookup limit

    SPF lists the servers allowed to send for your domain. Publish exactly one SPF record per domain — two records is not stricter, it is a permanent error that makes SPF fail entirely. End with a hard fail once your inventory is complete. The trap is the ten-DNS-lookup limit: each include counts, and each include can contain its own includes. Exceed ten and evaluation returns permerror, which most receivers treat as no SPF at all.

    • Start at ~all (soft fail) while you validate, then move to -all. Do not stay on ~all forever — it is close to publishing nothing.
    • Never publish two SPF records on one domain. Merge them into one.
    • Do not use ptr. It is deprecated and unreliable, and receivers may ignore it.
    • Publish SPF on domains that send no mail at all, so they cannot be used against you.
    ; One TXT record at the domain apex. -all = hard fail, ~all = soft fail.
    example.com.  IN  TXT  "v=spf1 include:_spf.google.com include:sendgrid.net -all"
    
    ; Count your lookups before publishing (include, a, mx, ptr, exists, redirect).
    ; The record above costs 2 of the 10 permitted.

    Step 2 — DKIM, one selector per sender

    DKIM signs the message so a receiver can verify it was not altered and that the signing domain authorised it. Give each sending system its own selector — that way you can rotate or revoke one without touching the others, and a compromised third party costs you one selector rather than your whole mail flow. Use a 2048-bit key where your provider supports it, and rotate on a schedule you actually keep.

    ; Selector "s1" for your mail platform, "mktg" for the marketing tool, and so on.
    s1._domainkey.example.com.    IN  TXT  "v=DKIM1; k=rsa; p=MIIBIjANBgkqh...IDAQAB"
    mktg._domainkey.example.com.  IN  TXT  "v=DKIM1; k=rsa; p=MIIBIjANBgkqh...IDAQAB"
    
    ; Verify a selector resolves before you rely on it:
    ;   dig +short TXT s1._domainkey.example.com

    Step 3 — DMARC, and the alignment that actually matters

    DMARC ties the two together and tells receivers what to do when they fail. Its real contribution is alignment: SPF and DKIM validate technical envelope domains, which an attacker can satisfy with their own domain while still displaying yours in the From header. DMARC requires the authenticated domain to match the visible one. That is the property that stops display-name spoofing, and it is the reason a domain with valid SPF and DKIM but p=none is still spoofable.

    ; Phase 1 — observe only. Nothing is rejected; you collect data.
    _dmarc.example.com.  IN  TXT  "v=DMARC1; p=none; rua=mailto:dmarc@example.com; fo=1"
    
    ; Phase 2 — quarantine a slice, then raise pct over several weeks.
    _dmarc.example.com.  IN  TXT  "v=DMARC1; p=quarantine; pct=25; rua=mailto:dmarc@example.com"
    
    ; Phase 3 — enforcement, with strict alignment once every sender is clean.
    _dmarc.example.com.  IN  TXT  "v=DMARC1; p=reject; adkim=s; aspf=s; rua=mailto:dmarc@example.com"
    
    ; Parked domains that never send mail:
    _dmarc.parked-example.com.  IN  TXT  "v=DMARC1; p=reject;"
    parked-example.com.         IN  TXT  "v=spf1 -all"

    Step 4 — reaching p=reject without losing mail

    Move in stages and let each one run long enough to cover a full business cycle, including monthly and quarterly senders that are invisible in a two-week sample. Point rua at a mailbox or an analyser you control and read what arrives — that traffic is how you discover the senders your inventory missed. The common mistake is jumping from p=none straight to p=reject after a quiet fortnight; the payroll run at month end is what breaks, and it breaks loudly.

    • p=none for at least one full month, reading what rua returns.
    • p=quarantine at pct=25, then 50, then 100, pausing at each step.
    • p=reject once a full cycle passes with no legitimate sender failing.
    • Tighten adkim and aspf to strict last, not first — strict alignment breaks subdomain senders.
    • Set sp= explicitly if subdomains should inherit a different policy from the parent.

    Step 5 — the domains you forgot you owned

    Attackers prefer the domain you are not watching: the old brand, the country variant bought defensively, the campaign domain from three years ago. None of them send mail, all of them can be spoofed, and mail from them looks plausible to your own staff precisely because the name is familiar. Publish a null SPF record and a reject policy on every one. It costs two DNS entries per domain and closes the route entirely.

    Troubleshooting — what actually goes wrong

    • Mail suddenly failing SPF after no change: an include upstream grew and pushed you past ten lookups. Count them again.
    • DMARC passes in tests but fails in production: forwarding and mailing lists break SPF alignment. DKIM survives forwarding — this is why you need both.
    • One department's mail rejected after enforcement: a shadow sender nobody listed. Check what rua reported before assuming a record is wrong.
    • Everything passes but you are still impersonated: check the display name and the lookalike domain — DMARC protects your domain, not a domain that merely resembles it.
    • Record edited but nothing changes: DNS TTL. Wait it out before editing again, or you will be debugging a cached answer.