One of the mechanisms in SPF is ptr
. This mechanism checks that a sender using some domain name connects from a (forward-confirmed) IP address pointing to a subdomain of that name.
For example, when sender [email protected]
connects from IP address 1.2.3.4, then the ptr
mechanism would first do a reverse lookup on 1.2.3.4. If the domain name returned by that lookup (eg mail.example.com
) also has IP address 1.2.3.4, and is a subdomain of example.com
, then the sender is authorised.
This seems like a useful feature. At the time of writing, the domain yahoo.com
uses this mechanism in its SPF records.
However, the SPF specification explicitly discourages using the ptr
mechanism (‘SHOULD NOT be published’ [= use may be acceptable in certain circumstances, but only after careful deliberation]). It gives the following explanation:
Note: This mechanism is slow, it is not as reliable as other mechanisms in cases of DNS errors, and it places a large burden on the .arpa name servers. If used, proper PTR records have to be in place for the domain's hosts and the "ptr" mechanism SHOULD be one of the last mechanisms checked. After many years of SPF deployment experience, it has been concluded that it is unnecessary and more reliable alternatives should be used instead.
This explanation seems rather fuzzy to me, or at least not strong enough to completely give up on this useful feature. Why is the mechanism ‘slow’ or ‘not reliable’, and how would it place a ‘large’ burden on name servers? Surely doing one additional DNS lookup in a mail server context cannot be a big issue?
Are there strong, practical reasons for not using ptr
, or can it be justified using it despite the RFC text?