Bug#1026090: Incorrect counting of void dns lookups regarding IPv6

Stefan Anders anders at dfn.de
Wed Dec 14 14:56:07 GMT 2022


Package: libmail-spf-perl
Version: 2.9.0-5

In case of clients with IPv6 addresses, Mail::SPF counts non existing
AAAA-Records as void dns lookups, although valid A-Records does exist.
Correct behaviour would be to count only as void lookups, if neither
A- nor AAAA-Record exists.

Example:

    spftest.dfn.de      TXT     "v=spf1 a a:one.spftest.dfn.de a:two.spftest.dfn.de -all"
    spftest.dfn.de      A       194.94.252.247
    one.spftest.dfn.de  A       194.94.252.253
    two.spftest.dfn.de  A       194.94.252.254

Test 1:

$ echo "192.107.51.3 test at spftest.dfn.de mail.enea.it" | spfquery -f - -s mfrom
fail
Rejected by SPF record
spftest.dfn.de: Sender is not authorized by default to use 'test at spftest.dfn.de' in 'mfrom' identity (mechanism '-all' matched)
Received-SPF: fail (spftest.dfn.de: Sender is not authorized by default to use 'test at spftest.dfn.de' in 'mfrom' identity (mechanism '-all' matched)) receiver=mgw6-han.srv.dfn.de; identity=mailfrom; envelope-from="test at spftest.dfn.de"; helo=mail.enea.it; client-ip=192.107.51.3
$

Test 2:

$ echo "2a00:1450:4864:20::34a test at spftest.dfn.de mail-wm1-x34a.google.com" | spfquery -f - -s mfrom
permerror
spftest.dfn.de: Maximum void DNS look-ups limit (2) exceeded
spftest.dfn.de: Maximum void DNS look-ups limit (2) exceeded
Received-SPF: permerror (spftest.dfn.de: Maximum void DNS look-ups limit (2) exceeded) receiver=mgw6-han.srv.dfn.de; identity=mailfrom; envelope-from="test at spftest.dfn.de"; helo=mail-wm1-x34a.google.com; client-ip="2a00:1450:4864:20::34a"
$

Expectation: test 2 should give the same result as test 1.

Thanks
Stefan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4978 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-perl-maintainers/attachments/20221214/3a1870df/attachment.bin>


More information about the pkg-perl-maintainers mailing list