Method Matches
- Namespace
- MailFathom.Domain.Emails.Authentication
- Assembly
- MailFathom.Domain.dll
Matches(SenderDomain, EmailAddress?)
Answers whether this entry recognizes one message's authenticated author.
public bool Matches(SenderDomain authorDomain, EmailAddress? displayedSender)
Parameters
authorDomainSenderDomainThe domain of the author the receiving server's verdict established.
displayedSenderEmailAddress?The address the message's
Fromheader displays, where it wrote a usable one.
Returns
Remarks
A domain entry is held against the author's domain alone, which is the only identity established at all: what a
receiving server authenticates is a domain, never a mailbox — DKIM signs as d=, SPF answers for the
envelope sender's domain, and DMARC states that one of those held for the displayed domain.
An address entry therefore narrows an established domain by a local part nothing established. It matches
when the author's domain is the entry's own and the displayed address is exactly the entry's, so the claim it
makes is: this domain wrote the message, and it presents it as coming from this mailbox of its own. That is worth
something because a domain answerable for its own From is answerable for the whole address in it, and it
is worth less than a domain entry, because a domain that can authenticate can display any local part it likes.
What it never does is recognize a message whose displayed address is missing or unusable, which the caller cannot
rule out from the domain alone.