How to fix: SPF redirect modifier ignored because all is present
The SPF record contains both an all mechanism and a redirect= modifier, so the redirect is dead. RFC 7208 section 6.1 says redirect is ignored whenever an all mechanism is present.
Why it matters
The policy that actually applies is the one before the all mechanism, not the redirected one. Whoever added the redirect believes the shared policy at the target domain is in force, so a sender added there, or removed from there, has no effect here. The gap between the intended policy and the evaluated one stays invisible until legitimate mail starts failing.
redirect= exists for the case where one domain defers entirely to another domain's policy, which is why it is only consulted when no mechanism matched and there is no all to produce a result first. To reuse another domain's senders while keeping your own default, use include: rather than redirect=: include pulls the other policy in as a mechanism and leaves your own all in charge of everything it does not match.
How to fix it
- 1Decide which behaviour you want: keep redirect= and remove the all mechanism, or keep all and change redirect= to include:.
- 2include: plus your own all is usually what was intended.
- 3Re-count the lookup budget after the change, since include and redirect both cost one.
Code examples
include instead of redirect
; the redirect here is dead code
; "v=spf1 include:_spf.google.com -all redirect=_spf.example.net"
example.com. IN TXT "v=spf1 include:_spf.google.com include:_spf.example.net -all"References
Detected automatically by VulnRadar. The check id is email-spf-redirect-ignored-with-all, stable across every scan so you can filter or diff on it.
More email checks
- LowDMARC Forensic Report URI (ruf=) Missing
- MediumDMARC Aggregate Report URI (rua=) Missing
- MediumMTA-STS (SMTP Strict Transport Security)
- LowTLS-RPT Record Missing rua= Reporting URI
- HighSPF Exceeds 10 DNS Lookup Limit
- HighSPF Redirect Loop
- LowDMARC pct= Below 100
- MediumDMARC Policy Set to Monitor-Only (p=none)
Questions
- How severe is SPF redirect modifier ignored because all is present?
- VulnRadar rates this low severity in the email category. The severity is fixed per check, not scored per site, so the same finding is the same severity on every scan.
- Does VulnRadar check for this automatically?
- Yes. It runs as part of every scan under the check id email-spf-redirect-ignored-with-all, which stays the same between runs so you can filter, diff, or gate CI on it.
- Which standards does SPF redirect modifier ignored because all is present map to?
- It maps to CWE-16. In the OWASP Top 10 it falls under A05:2021.
Missing a check?
The detection set is open. If you know a misconfiguration this does not catch, propose it: the issue template asks for the threat model, how to detect it, the false-positive risk, and a test fixture, which is the same thing a maintainer would have to work out anyway.