[afnog] Testing SPF records in DNS

Stephane Bortzmeyer bortzmeyer at nic.fr
Thu Jan 8 12:37:52 UTC 2009


On Thu, Jan 08, 2009 at 11:41:44AM -0000,
 Makan SIMAGA <msimaga at bvg-mali.org> wrote 
 a message of 128 lines which said:

> I want to know how to query SPF record in DNS.

They have nothing specific, you can query them with dig.

% dig +short TXT freebsd.org.      
"v=spf1 ip4:69.147.83.53 ip4:69.147.83.54 ip6:2001:4f8:fff6::35 ip6:2001:4f8:fff6::36 ~all"

TXT is by far the most common type for SPF records, although RFC 4408
recommands another type, SPF (code 99).

% dig +short SPF freebsd.org.   

If your dig is too old to recognize the type SPF, upgrade or use its
number:

% dig +short TYPE99 freebsd.org.   

If you want, not to *query* them but to test if your SPF records are
sound, the simplest solution is to send an email to
check-auth at verifier.port25.com which will send you back a nice report
with, among other things, the SPF status of your message.



More information about the afnog mailing list