[ Headers & delivery errors ]

DKIM verification of a saved message versus the original delivery

Reverify saved bytes with explicit key provenance, and do not confuse a current local result with the original receiver’s decision.

By the EmailAuth research team · 3 min read

[ Key points ]

  • Reverify saved bytes with explicit key provenance, and do not confuse a current local result with the original receiver’s decision.
  • A current verification uses current bytes, keys and rules; it cannot silently replace the original receiver’s historical result.
On this page

A saved message is valuable evidence, but a new DKIM verification is a new event. It tests the saved representation and the available key under the verifier's rules at that time. Preserve the original receiver's reported result alongside the new test so an apparent disagreement can be investigated instead of silently overwritten.

Preserve the input before parsing

Save the message as bytes and compute a SHA-256 fingerprint before opening it in software that may rewrite headers, line endings or MIME structure. Keep any analysis or redaction in a derivative file. DKIM operates on canonicalized message material, not on a screenshot or a visually equivalent rendered message. RFC 6376 defines simple and relaxed canonicalization with specific tolerances. RFC 6376 section 3.4.

A relaxed signature tolerates certain whitespace differences; it does not authorize arbitrary rewriting. Changes to signed text can still invalidate it. Check the signed-header list and any body-length tag before describing what the signature protects. A signature with limited body coverage is different from one covering the entire canonicalized body.

Record the key and verifier context

The signature's d= and s= values identify the signing domain and selector used to find the public key. Record the queried name, response time, resolver context and retained key bytes when legitimately available. A current lookup may differ from the key that existed at delivery because of rotation, revocation or DNS change. Failure to obtain a key now is not proof that the receiver lacked it then. RFC 6376 sections 3.6 and 6.

Record verifier name, version, settings and the signature selected. Multiple signatures can yield different results. Do not describe a default check of one signature as verification of all signatures. Expiration, algorithm support and local policy can also affect an outcome, so retain the diagnostic rather than reducing every failure to “message tampered with.”

Compare a hypothetical old pass with a new failure

Suppose a trusted receiver recorded DKIM pass at delivery, but a later saved-file check cannot obtain the selector key. That new result establishes present verification limits, not an old failure. Retain the query name, lookup time and diagnostic; seek authorized historical key or DNS evidence if the question requires it.

In a different case, the current key is available but the analyst’s derivative has changed signed body text. Test the preserved original separately before blaming a relay or sender. If only the edited copy survives, the historical signature outcome remains unresolved. These are hypothetical diagnostic branches, not executed cryptographic operations or DNS replay.

If a public key is supplied through a local callback rather than obtained from DNS, label that input explicitly. A pass under an injected key does not establish that the signing domain published or authorized that key. Never include a private signing key in the evidence pack.

Explain disagreement without overclaiming

If the saved copy fails but a trusted receiver recorded pass, compare artifact provenance, transformations, key availability and verifier behavior. If the saved copy passes, that establishes the tested signature under the supplied key and rules, not inbox placement, sender intent or current DMARC policy. DKIM's signing identity and DMARC alignment are separate questions.

Close the evidence record with two lines: what the receiver reported at delivery, and what the independent check observed now. Include timestamps, artifact hashes, signature identity and unresolved differences. This preserves a useful audit trail even when the original environment cannot be reconstructed.

Keep verification scope distinct from DMARC

A passing signature establishes the selected DKIM result under the actual key source, bytes and verifier rules. DMARC also needs the signing domain’s alignment with From and an applicable policy evaluation. Use the current RFC 9989 sections 5.3 and 5.4 rather than treating every DKIM pass as DMARC pass or a statement of safe content.

Record historical and current results separately

  • Preserve the saved bytes and their fingerprint before parsing.
  • Identify the exact signature, d=, s=, canonicalization and signed coverage.
  • Retain public key source, lookup time, verifier version and diagnostic.
  • Compare transformations and key changes without assuming tampering.
  • Keep the original receiver report and the new evaluation as two timestamped observations.

[ Takeaway ]

Reverify saved bytes with explicit key provenance, and do not confuse a current local result with the original receiver’s decision.

[ By role ]

What this means for you

Choose your role for practical next steps.

IT / Mail Admin

Make the verification reproducible

Bytes and key provenance determine the test.

Next steps

  1. Hash the input first.
  2. Record verifier and selected signature.
  3. Retain the public key and diagnostics.

CISO / SecOps

Protect evidence and signing secrets

An investigation should not expose production credentials.

Next steps

  1. Restrict originals.
  2. Never share private DKIM keys.
  3. Review custody and retention.

Founder / Non-technical

Ask what the test can establish

A local check cannot replay an entire customer delivery.

Next steps

  1. Keep historical and current results separate.
  2. Request understandable limitations.
  3. Avoid attributing blame prematurely.

[ FAQs ]

Frequently asked questions

Does rechecking reproduce the original delivery?

No. It evaluates saved bytes and the key and verifier context available for the new test.

Can a visually identical export break DKIM?

Yes. Serialization changes can alter signed material.

Does relaxed mean all edits are harmless?

No. Only specified canonicalization differences are tolerated.

What identifies the key lookup?

The DKIM signing domain d= and selector s= determine the lookup name.

Does a missing current key prove an old failure?

No. The historical key may have differed or remained available then.

Does one passing signature establish all signatures pass?

No. Identify and test each signature relevant to the question.

Were the saved-file comparisons executed?

No. They are hypothetical diagnostic branches. No key generation, SMTP delivery, DNS replay or cryptographic verification was performed for this guide.

Does a local pass prove inbox delivery?

No. A local pass is limited to the tested signature, bytes, key source and rules. An injected key also does not establish historical DNS authorization.

[ Sources ]

Sources

  1. RFC 6376: DKIM Signatures

    Sections §3.4 · §3.6 · §5 · §6

  2. RFC 8601: Authentication-Results

    Sections §1.2 · §7

  3. RFC 9989: DMARC

    Sections §3.2.10 · §4.10.2 · §5.3 · §5.4

[ Glossary ]

Glossary

Canonicalization
The defined transformation of message material before DKIM signing or verification.
Selector
The DKIM value used with the signing domain to locate its public key.
Artifact fingerprint
A cryptographic hash identifying the exact bytes of a saved file.

Enterprise provenance

Why top financial institutions and governments retired their email security dashboards.

Traditional email authentication platforms sell you a dashboard and ask your engineers to do the labour. In high-stakes environments, manual oversight means delayed enforcement, configuration drift and unmonitored shadow domains.

EmailAuth is the agentic email provenance platform. Our agents enforce p=reject, keep third-party senders aligned and move your domains to full RFC 9989 compliance, the new DMARC standard,, with human-in-the-loop auditability.

Governments Large enterprises Tier-1 financial institutions

SaaS · Dedicated tenancy · Air-gapped on-prem · BYOK encryption

Knowledge Base