MailAuth.DMARC.Result (MailAuth v0.1.0)

Copy Markdown View Source

The result of a DMARC check (RFC 9989).

Fields:

  • :result: :pass, :fail, :none, :temperror or :permerror
  • :reason: why it did not pass, as an atom. See the README
  • :from_domain: the domain of the From: address, in A-labels
  • :organizational_domain: the From domain's organizational domain
  • :record_domain: where the record that applies was found
  • :record: the MailAuth.DMARC.Record that applies
  • :policy: the policy that applies to this domain: p, sp or np
  • :testing?: true when the record has t=y
  • :disposition: what the domain asks a receiver to do with this message: :none on a pass, otherwise the policy, one step lower when testing?. The library reports it and never acts on it
  • :aligned_by: which checks aligned with the From domain, :dkim and :spf
  • :dkim_domain: the d= of the aligned DKIM signature, or of the first that passed
  • :spf_domain: the domain SPF checked
  • :warnings: such as :missing_policy

Summary

Types

t()

@type t() :: %MailAuth.DMARC.Result{
  aligned_by: [:dkim | :spf],
  disposition: MailAuth.DMARC.Record.policy(),
  dkim_domain: String.t() | nil,
  from_domain: String.t() | nil,
  organizational_domain: String.t() | nil,
  policy: MailAuth.DMARC.Record.policy() | nil,
  reason: atom() | nil,
  record: MailAuth.DMARC.Record.t() | nil,
  record_domain: String.t() | nil,
  result: :pass | :fail | :none | :temperror | :permerror,
  spf_domain: String.t() | nil,
  testing?: boolean(),
  warnings: [atom()]
}