You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Luigi Lauro <lu...@gmail.com> on 2010/03/05 08:27:00 UTC

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

> Weird indeed. Which version of IO::Socket::INET6 do you have?

marvin% perl -le 'use IO::Socket::INET6; print IO::Socket::INET6->VERSION'
2.57


> Try capturing your traffic on a loopback interface for port 53:

This is the output with -vv for protocol decode with my recursive
local DNS on 127.0.0.1 and my authorative DNS on listening on
2002:4e2e:3890::1 and 78.46.56.144

marvin% cat logtcp.log
08:12:36.235450 IP (tos 0x0, ttl 64, id 40217, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->df9e)!)
    localhost.45390 > localhost.domain: [udp sum ok] 32759+ A? 256.1. (23)
08:12:36.235511 IP (tos 0x0, ttl 64, id 40218, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->df9d)!)
    localhost.domain > localhost.45390: [udp sum ok] 32759 NXDomain*
q: A? 256.1. 0/0/0 (23)
08:12:36.235571 IP (tos 0x0, ttl 64, id 40219, offset 0, flags [none],
proto UDP (17), length 65, bad cksum 0 (->df8e)!)
    localhost.55868 > localhost.domain: [udp sum ok] 32760+ A?
256.1.luigilauro.it. (37)
08:12:36.235606 IP (tos 0x0, ttl 64, id 40220, offset 0, flags [none],
proto UDP (17), length 81, bad cksum 0 (->df7d)!)
    localhost.domain > localhost.55868: [udp sum ok] 32760 q: A?
256.1.luigilauro.it. 1/0/0 256.1.luigilauro.it. A 78.46.56.144 (53)
08:12:36.370027 IP (tos 0x0, ttl 64, id 40240, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->df85)!)
    localhost.20826 > localhost.domain: [udp sum ok] 32761+ AAAA? 0.0.0.0. (25)
08:12:36.370079 IP (tos 0x0, ttl 64, id 40241, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->df84)!)
    localhost.domain > localhost.20826: [udp sum ok] 32761 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:36.370121 IP (tos 0x0, ttl 64, id 40242, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->df75)!)
    localhost.52422 > localhost.domain: [udp sum ok] 32762+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:36.370173 IP (tos 0x0, ttl 64, id 40243, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->df58)!)
    localhost.domain > localhost.52422: [udp sum ok] 32762 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:36.370264 IP (tos 0x0, ttl 64, id 40244, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->df81)!)
    localhost.24531 > localhost.domain: [udp sum ok] 32763+ AAAA? 0.0.0.0. (25)
08:12:36.370293 IP (tos 0x0, ttl 64, id 40245, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->df80)!)
    localhost.domain > localhost.24531: [udp sum ok] 32763 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:36.370329 IP (tos 0x0, ttl 64, id 40246, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->df71)!)
    localhost.26186 > localhost.domain: [udp sum ok] 32764+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:36.370361 IP (tos 0x0, ttl 64, id 40247, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->df54)!)
    localhost.domain > localhost.26186: [udp sum ok] 32764 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:37.290121 IP (tos 0x0, ttl 64, id 40435, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->dec2)!)
    localhost.50361 > localhost.domain: [udp sum ok] 32765+ AAAA? 0.0.0.0. (25)
08:12:37.290171 IP (tos 0x0, ttl 64, id 40436, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->dec1)!)
    localhost.domain > localhost.50361: [udp sum ok] 32765 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:37.290209 IP (tos 0x0, ttl 64, id 40437, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->deb2)!)
    localhost.24761 > localhost.domain: [udp sum ok] 32766+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:37.290242 IP (tos 0x0, ttl 64, id 40438, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->de95)!)
    localhost.domain > localhost.24761: [udp sum ok] 32766 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:37.290316 IP (tos 0x0, ttl 64, id 40439, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->debe)!)
    localhost.57357 > localhost.domain: [udp sum ok] 32767+ AAAA? 0.0.0.0. (25)
08:12:37.290342 IP (tos 0x0, ttl 64, id 40440, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->debd)!)
    localhost.domain > localhost.57357: [udp sum ok] 32767 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:37.290377 IP (tos 0x0, ttl 64, id 40441, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->deae)!)
    localhost.14897 > localhost.domain: [udp sum ok] 32768+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:37.290430 IP (tos 0x0, ttl 64, id 40442, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->de91)!)
    localhost.domain > localhost.14897: [udp sum ok] 32768 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:37.291147 IP (tos 0x0, ttl 64, id 40443, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->deba)!)
    localhost.19958 > localhost.domain: [udp sum ok] 32769+ AAAA? 0.0.0.0. (25)
08:12:37.291174 IP (tos 0x0, ttl 64, id 40444, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->deb9)!)
    localhost.domain > localhost.19958: [udp sum ok] 32769 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:37.291208 IP (tos 0x0, ttl 64, id 40445, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->deaa)!)
    localhost.30249 > localhost.domain: [udp sum ok] 32770+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:37.291238 IP (tos 0x0, ttl 64, id 40446, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->de8d)!)
    localhost.domain > localhost.30249: [udp sum ok] 32770 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:37.291327 IP (tos 0x0, ttl 64, id 40447, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->deb4)!)
    localhost.13073 > localhost.domain: [udp sum ok] 32771+ AAAA?
127.0.0.1. (27)
08:12:37.291354 IP (tos 0x0, ttl 64, id 40448, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->deb3)!)
    localhost.domain > localhost.13073: [udp sum ok] 32771 q: AAAA?
127.0.0.1. 0/0/0 (27)
08:12:37.291389 IP (tos 0x0, ttl 64, id 40449, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->dea4)!)
    localhost.52409 > localhost.domain: [udp sum ok] 32772+ AAAA?
127.0.0.1.luigilauro.it. (41)
08:12:37.291419 IP (tos 0x0, ttl 64, id 40450, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->de87)!)
    localhost.domain > localhost.52409: [udp sum ok] 32772 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
08:12:37.292040 IP6 (flowlabel 0xc157c, hlim 64, next-header UDP (17)
payload length: 36) 2002:4e2e:3890::1.6973 > 2002:4e2e:3890::1.domain:
[udp sum ok] 6361+ NS? kernel.org. (28)
08:12:37.292080 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.domain > 2002:4e2e:3890::1.6973: [udp sum ok] 6361
Refused- [0q] 0/0/0 (12)
08:12:37.916382 IP (tos 0x0, ttl 64, id 40459, offset 0, flags [none],
proto UDP (17), length 118, bad cksum 0 (->de69)!)
    localhost.60951 > localhost.domain: [udp sum ok] 3650+ PTR?
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.9.8.3.e.2.e.4.2.0.0.2.ip6.arpa.
(90)
08:12:37.916490 IP (tos 0x0, ttl 64, id 40460, offset 0, flags [none],
proto UDP (17), length 118, bad cksum 0 (->de68)!)
    localhost.domain > localhost.60951: [udp sum ok] 3650 NXDomain* q:
PTR? 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.9.8.3.e.2.e.4.2.0.0.2.ip6.arpa.
0/0/0 (90)
08:12:40.312274 IP6 (flowlabel 0xc157c, hlim 64, next-header UDP (17)
payload length: 33) 2002:4e2e:3890::1.6973 > 2002:4e2e:3890::1.domain:
[udp sum ok] 60792+ NS? gmx.net. (25)
08:12:40.312399 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.domain > 2002:4e2e:3890::1.6973: [udp sum ok] 60792
Refused- [0q] 0/0/0 (12)
08:12:43.333145 IP6 (flowlabel 0xc157c, hlim 64, next-header UDP (17)
payload length: 38) 2002:4e2e:3890::1.6973 > 2002:4e2e:3890::1.domain:
[udp sum ok] 58331+ NS? adelphia.net. (30)
08:12:43.333275 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.domain > 2002:4e2e:3890::1.6973: [udp sum ok] 58331
Refused- [0q] 0/0/0 (12)
08:12:46.355588 IP (tos 0x0, ttl 64, id 40493, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->de88)!)
    localhost.51426 > localhost.domain: [udp sum ok] 32773+ AAAA? 0.0.0.0. (25)
08:12:46.355645 IP (tos 0x0, ttl 64, id 40494, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->de87)!)
    localhost.domain > localhost.51426: [udp sum ok] 32773 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:12:46.355685 IP (tos 0x0, ttl 64, id 40495, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->de78)!)
    localhost.38707 > localhost.domain: [udp sum ok] 32774+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:12:46.355730 IP (tos 0x0, ttl 64, id 40496, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->de5b)!)
    localhost.domain > localhost.38707: [udp sum ok] 32774 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:12:46.355849 IP (tos 0x0, ttl 64, id 40497, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->de82)!)
    localhost.29798 > localhost.domain: [udp sum ok] 32775+ AAAA?
127.0.0.1. (27)
08:12:46.355887 IP (tos 0x0, ttl 64, id 40498, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->de81)!)
    localhost.domain > localhost.29798: [udp sum ok] 32775 q: AAAA?
127.0.0.1. 0/0/0 (27)
08:12:46.355921 IP (tos 0x0, ttl 64, id 40499, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->de72)!)
    localhost.17202 > localhost.domain: [udp sum ok] 32776+ AAAA?
127.0.0.1.luigilauro.it. (41)
08:12:46.355963 IP (tos 0x0, ttl 64, id 40500, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->de55)!)
    localhost.domain > localhost.17202: [udp sum ok] 32776 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
08:12:46.839832 IP (tos 0x0, ttl 64, id 40528, offset 0, flags [none],
proto UDP (17), length 64, bad cksum 0 (->de5a)!)
    localhost.55322 > localhost.domain: [udp sum ok] 32777+ A?
c301.cloudmark.com. (36)
08:12:46.839885 IP (tos 0x0, ttl 64, id 40529, offset 0, flags [none],
proto UDP (17), length 80, bad cksum 0 (->de49)!)
    localhost.domain > localhost.55322: [udp sum ok] 32777 q: A?
c301.cloudmark.com. 1/0/0 c301.cloudmark.com. A 208.83.137.114 (52)
08:12:47.331830 IP (tos 0x0, ttl 64, id 40550, offset 0, flags [none],
proto UDP (17), length 62, bad cksum 0 (->de46)!)
    localhost.43547 > localhost.domain: [udp sum ok] 58436+ A?
public.pyzor.org. (34)
08:12:47.331886 IP (tos 0x0, ttl 64, id 40551, offset 0, flags [none],
proto UDP (17), length 78, bad cksum 0 (->de35)!)
    localhost.domain > localhost.43547: [udp sum ok] 58436 q: A?
public.pyzor.org. 1/0/0 public.pyzor.org. A 188.40.77.236 (50)



This is the output with -vv for protocol decode with my recursive
local DNS on 127.0.0.1 (I stopped MaraDNS).

marvin% cat logtcp2.log
08:23:16.890113 IP (tos 0x0, ttl 64, id 50600, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->b70f)!)
    localhost.59598 > localhost.domain: [udp sum ok] 29337+ A? 256.1. (23)
08:23:16.890271 IP (tos 0x0, ttl 64, id 50601, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->b70e)!)
    localhost.domain > localhost.59598: [udp sum ok] 29337 NXDomain*
q: A? 256.1. 0/0/0 (23)
08:23:16.890428 IP (tos 0x0, ttl 64, id 50602, offset 0, flags [none],
proto UDP (17), length 65, bad cksum 0 (->b6ff)!)
    localhost.43421 > localhost.domain: [udp sum ok] 29338+ A?
256.1.luigilauro.it. (37)
08:23:16.890525 IP (tos 0x0, ttl 64, id 50603, offset 0, flags [none],
proto UDP (17), length 81, bad cksum 0 (->b6ee)!)
    localhost.domain > localhost.43421: [udp sum ok] 29338 q: A?
256.1.luigilauro.it. 1/0/0 256.1.luigilauro.it. A 78.46.56.144 (53)
08:23:17.085263 IP (tos 0x0, ttl 64, id 50615, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6fe)!)
    localhost.62042 > localhost.domain: [udp sum ok] 29339+ AAAA? 0.0.0.0. (25)
08:23:17.085313 IP (tos 0x0, ttl 64, id 50616, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6fd)!)
    localhost.domain > localhost.62042: [udp sum ok] 29339 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:17.085356 IP (tos 0x0, ttl 64, id 50617, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b6ee)!)
    localhost.39722 > localhost.domain: [udp sum ok] 29340+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:17.085409 IP (tos 0x0, ttl 64, id 50618, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b6d1)!)
    localhost.domain > localhost.39722: [udp sum ok] 29340 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:17.085502 IP (tos 0x0, ttl 64, id 50619, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6fa)!)
    localhost.13441 > localhost.domain: [udp sum ok] 29341+ AAAA? 0.0.0.0. (25)
08:23:17.085527 IP (tos 0x0, ttl 64, id 50620, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6f9)!)
    localhost.domain > localhost.13441: [udp sum ok] 29341 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:17.085561 IP (tos 0x0, ttl 64, id 50621, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b6ea)!)
    localhost.27428 > localhost.domain: [udp sum ok] 29342+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:17.085588 IP (tos 0x0, ttl 64, id 50622, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b6cd)!)
    localhost.domain > localhost.27428: [udp sum ok] 29342 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:17.990584 IP (tos 0x0, ttl 64, id 50648, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6dd)!)
    localhost.33531 > localhost.domain: [udp sum ok] 29343+ AAAA? 0.0.0.0. (25)
08:23:17.990635 IP (tos 0x0, ttl 64, id 50649, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6dc)!)
    localhost.domain > localhost.33531: [udp sum ok] 29343 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:17.990671 IP (tos 0x0, ttl 64, id 50650, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b6cd)!)
    localhost.37314 > localhost.domain: [udp sum ok] 29344+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:17.990703 IP (tos 0x0, ttl 64, id 50651, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b6b0)!)
    localhost.domain > localhost.37314: [udp sum ok] 29344 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:17.990776 IP (tos 0x0, ttl 64, id 50652, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6d9)!)
    localhost.58657 > localhost.domain: [udp sum ok] 29345+ AAAA? 0.0.0.0. (25)
08:23:17.990800 IP (tos 0x0, ttl 64, id 50653, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6d8)!)
    localhost.domain > localhost.58657: [udp sum ok] 29345 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:17.990834 IP (tos 0x0, ttl 64, id 50654, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b6c9)!)
    localhost.34071 > localhost.domain: [udp sum ok] 29346+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:17.990878 IP (tos 0x0, ttl 64, id 50655, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b6ac)!)
    localhost.domain > localhost.34071: [udp sum ok] 29346 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:17.991615 IP (tos 0x0, ttl 64, id 50656, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6d5)!)
    localhost.45318 > localhost.domain: [udp sum ok] 29347+ AAAA? 0.0.0.0. (25)
08:23:17.991644 IP (tos 0x0, ttl 64, id 50657, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6d4)!)
    localhost.domain > localhost.45318: [udp sum ok] 29347 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:17.991678 IP (tos 0x0, ttl 64, id 50658, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b6c5)!)
    localhost.62134 > localhost.domain: [udp sum ok] 29348+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:17.991706 IP (tos 0x0, ttl 64, id 50659, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b6a8)!)
    localhost.domain > localhost.62134: [udp sum ok] 29348 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:17.991794 IP (tos 0x0, ttl 64, id 50660, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->b6cf)!)
    localhost.30714 > localhost.domain: [udp sum ok] 29349+ AAAA?
127.0.0.1. (27)
08:23:17.991818 IP (tos 0x0, ttl 64, id 50661, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->b6ce)!)
    localhost.domain > localhost.30714: [udp sum ok] 29349 q: AAAA?
127.0.0.1. 0/0/0 (27)
08:23:17.991851 IP (tos 0x0, ttl 64, id 50662, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->b6bf)!)
    localhost.43608 > localhost.domain: [udp sum ok] 29350+ AAAA?
127.0.0.1.luigilauro.it. (41)
08:23:17.991879 IP (tos 0x0, ttl 64, id 50663, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->b6a2)!)
    localhost.domain > localhost.43608: [udp sum ok] 29350 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
08:23:17.992511 IP6 (flowlabel 0x778d9, hlim 64, next-header UDP (17)
payload length: 41) 2002:4e2e:3890::1.56920 >
2002:4e2e:3890::1.domain: [udp sum ok] 55979+ NS? doubleclick.com.
(33)
08:23:18.024575 IP (tos 0x0, ttl 64, id 50664, offset 0, flags [none],
proto UDP (17), length 118, bad cksum 0 (->b68c)!)
    localhost.11588 > localhost.domain: [udp sum ok] 45361+ PTR?
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.9.8.3.e.2.e.4.2.0.0.2.ip6.arpa.
(90)
08:23:18.024688 IP (tos 0x0, ttl 64, id 50665, offset 0, flags [none],
proto UDP (17), length 118, bad cksum 0 (->b68b)!)
    localhost.domain > localhost.11588: [udp sum ok] 45361 NXDomain*
q: PTR? 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.9.8.3.e.2.e.4.2.0.0.2.ip6.arpa.
0/0/0 (90)
08:23:21.016289 IP6 (flowlabel 0x778d9, hlim 64, next-header UDP (17)
payload length: 33) 2002:4e2e:3890::1.56920 >
2002:4e2e:3890::1.domain: [udp sum ok] 54002+ NS? mit.edu. (25)
08:23:24.038920 IP6 (flowlabel 0x778d9, hlim 64, next-header UDP (17)
payload length: 33) 2002:4e2e:3890::1.56920 >
2002:4e2e:3890::1.domain: [udp sum ok] 49650+ NS? msn.com. (25)
08:23:27.059292 IP (tos 0x0, ttl 64, id 50701, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6a8)!)
    localhost.13786 > localhost.domain: [udp sum ok] 29351+ AAAA? 0.0.0.0. (25)
08:23:27.059354 IP (tos 0x0, ttl 64, id 50702, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->b6a7)!)
    localhost.domain > localhost.13786: [udp sum ok] 29351 q: AAAA?
0.0.0.0. 0/0/0 (25)
08:23:27.059408 IP (tos 0x0, ttl 64, id 50703, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->b698)!)
    localhost.34544 > localhost.domain: [udp sum ok] 29352+ AAAA?
0.0.0.0.luigilauro.it. (39)
08:23:27.059453 IP (tos 0x0, ttl 64, id 50704, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->b67b)!)
    localhost.domain > localhost.34544: [udp sum ok] 29352 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
08:23:27.059588 IP (tos 0x0, ttl 64, id 50705, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->b6a2)!)
    localhost.46118 > localhost.domain: [udp sum ok] 29353+ AAAA?
127.0.0.1. (27)
08:23:27.059625 IP (tos 0x0, ttl 64, id 50706, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->b6a1)!)
    localhost.domain > localhost.46118: [udp sum ok] 29353 q: AAAA?
127.0.0.1. 0/0/0 (27)
08:23:27.059670 IP (tos 0x0, ttl 64, id 50707, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->b692)!)
    localhost.55295 > localhost.domain: [udp sum ok] 29354+ AAAA?
127.0.0.1.luigilauro.it. (41)
08:23:27.059710 IP (tos 0x0, ttl 64, id 50708, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->b675)!)
    localhost.domain > localhost.55295: [udp sum ok] 29354 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
08:23:27.511647 IP (tos 0x0, ttl 64, id 50730, offset 0, flags [none],
proto UDP (17), length 64, bad cksum 0 (->b680)!)
    localhost.31027 > localhost.domain: [udp sum ok] 29355+ A?
c303.cloudmark.com. (36)
08:23:27.511701 IP (tos 0x0, ttl 64, id 50731, offset 0, flags [none],
proto UDP (17), length 80, bad cksum 0 (->b66f)!)
    localhost.domain > localhost.31027: [udp sum ok] 29355 q: A?
c303.cloudmark.com. 1/0/0 c303.cloudmark.com. A 208.83.139.204 (52)
08:23:27.966089 IP (tos 0x0, ttl 64, id 50761, offset 0, flags [none],
proto UDP (17), length 62, bad cksum 0 (->b663)!)
    localhost.45475 > localhost.domain: [udp sum ok] 17609+ A?
public.pyzor.org. (34)
08:23:27.966149 IP (tos 0x0, ttl 64, id 50762, offset 0, flags [none],
proto UDP (17), length 78, bad cksum 0 (->b652)!)
    localhost.domain > localhost.45475: [udp sum ok] 17609 q: A?
public.pyzor.org. 1/0/0 public.pyzor.org. A 188.40.77.236 (50)

> then we can decide whether the fault lies with SpamAssassin and
> its underlying inet sockets module, or with your DNS server(s),
> or even with your TCP stack implementation. Btw, what OS is that?

Stack implementation I seriously doubt, this is one of the most solid ones.

It's a FreeBSD 8.0-STABLE, so serious business ;-)

My best guess is that for some reason spamassassin or Net:DNS are
trying the IPv6 of my local machine instead of the GIVEN 127.0.0.1

If you need any more info just ask and I'll give you everything (full
spamassassin debug, etc...).

-- 
Luigi Lauro

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Mark Martinec <Ma...@ijs.si>.
myself wrote:
> - contact the maintainer of IO::Socket::INET6 and sort out the problem;
> - avoid mapping AAAA 127.0.0.1 query into an IPv6 address of your
>   nonrecursive DNS server.
> (preferably both).

Actually there are more options:
- allow your IPv6 DNS server to answer recursive queries from inside;
- use option --ipv4 on spamd or deinstall IO::Socket::INET6

Mark

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Luigi Lauro <lu...@gmail.com>.
BTW: https://rt.cpan.org/Public/Bug/Display.html?id=55278

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Luigi Lauro <lu...@gmail.com>.
On Fri, Mar 5, 2010 at 16:46, Mark Martinec <Ma...@ijs.si> wrote:
> Your options are:
> - contact the maintainer of IO::Socket::INET6 and sort out the problem;

I just did and filed a bug report. Let's hope they can treat
127.0.0.1/0.0.0.0 as special cases and NOT query them against local
domain.

No one but insane people would ever give 127.0.0.1.mydomain.com or
0.0.0.0.mydomain.com as valid DNS names...

> - avoid mapping AAAA 127.0.0.1 query into an IPv6 address of your
>  nonrecursive DNS server.

I just did... I left the * wildcarding, but added explicitly 0.0.0.0
and 127.0.0.1 on my domain, resolving them only as A to 127.0.0.1.

Ugly, crazy and unneeded, but harmless and it's the only stop gap
solution I can do while waiting for the real fix on the perl library.

> - allow your IPv6 DNS server to answer recursive queries from inside;

If DNS history teaches us something (=BIND security notices), it's
that having a DNS server which is both authoritative and recursive is
wrong and it's asking for security troubles.

I would never ever have an authoritative DNS server as a caching
recursive server. They are very different thing with very different
uses and policies.

I personally use djbdns dnscache as my local recursive cache, and
MaraDNS as my authoritative DNS, compiled as auth only.

> - use option --ipv4 on spamd or deinstall IO::Socket::INET6

I really cannot, i need and want IPV6 ;-)

Thank you Mark, you solved my problem for what it could be done, now
it's up to perl mantainer to fix the bug for real ;-)

-- 
Luigi Lauro

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Mark Martinec <Ma...@ijs.si>.
Luigi,

>     127.0.0.1.53 > 127.0.0.1.15896: [udp sum ok] 12915 q: AAAA?
> 0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
> 2002:4e2e:3890::1 (67)

>     127.0.0.1.53 > 127.0.0.1.24312: [udp sum ok] 12919 q: AAAA?
> 127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
> 2002:4e2e:3890::1 (69)


> > Why does your resolver map an AAAA query 0.0.0.0.luigilauro.it to
> > 2002:4e2e:3890::1 ?
> 
> This is perfectly fine, my authoritative DNS is set up for resolving
> any *.luigilauro.it to my A and AAAA public addresses (78.46.56.144
> and 2002:4e2e:3890::1).
> 
> This is what I want and need and have been using with no problems with
> any software for years, not to mention it's a 'standard' widely
> used... ;-)

> I wish I could just make spamassassin do what he should do: query the
> dns on the IPv4 127.0.0.1 for the needed addresses, not try to resolve
> 127.0.0.1 as a name against my domain or other weird, wrong and
> unneeded things :-)

> It's not a MISconfiguration, really :-)
> It's a wanted, needed, standard DNS configuration, to use wildcard in
> domains.
> 
> What is a 'misconfiguration' is spamassassin trying to resolve
> 127.0.0.1 as a domain name instead of treating it for what it is: an
> ipv4 to call for DNS requests :-)

Well, you are asking for trouble with that wildcarding!

The actual bug lies in module IO::Socket::INET6 in sub configure.
Your nameserver entry in /etc/resolv.conf is 127.0.0.1 .
The configure() is trying to figure out which protocol family to use,
so it tries both, the AF_INET6, then AF_INET. Code near line 192 is:

192:  @rres = getaddrinfo(
193:    $raddr,$rport,$fam,$type,$proto,AI_PASSIVE
194:  );

Since getaddrinfo is told to try AF_INET6 first but is given 127.0.0.1
as $raddr, it decides it is not an IPv6 address, and tries to resolve it!
Instead of receiving a usual NXDOMAIN, you are supplying it with an
address 2002:4e2e:3890::1, letting all hell break loose from here on.

I don't think there is anything the Net::DNS or SpamAssassin can do
about it. Your options are:
- contact the maintainer of IO::Socket::INET6 and sort out the problem;
- avoid mapping AAAA 127.0.0.1 query into an IPv6 address of your
  nonrecursive DNS server.

(preferably both).

  Mark

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Luigi Lauro <lu...@gmail.com>.
> Forgot option -n, makes it unknown whether 'localhost' is 127.0.0.1 or ::1.

13:57:40.287618 IP (tos 0x0, ttl 64, id 30469, offset 0, flags [none],
proto UDP (17), length 66, bad cksum 0 (->5a4)!)
    127.0.0.1.36192 > 127.0.0.1.53: [udp sum ok] 45090+ A?
marvin.luigilauro.it. (38)
13:57:40.287817 IP (tos 0x0, ttl 64, id 30470, offset 0, flags [none],
proto UDP (17), length 66, bad cksum 0 (->5a3)!)
    127.0.0.1.53 > 127.0.0.1.36192: [udp sum ok] 45090 q: A?
marvin.luigilauro.it. 0/0/0 (38)
13:57:40.287992 IP (tos 0x0, ttl 64, id 30471, offset 0, flags [none],
proto UDP (17), length 66, bad cksum 0 (->5a2)!)
    127.0.0.1.36488 > 127.0.0.1.53: [udp sum ok] 45091+ AAAA?
marvin.luigilauro.it. (38)
13:57:40.288120 IP (tos 0x0, ttl 64, id 30472, offset 0, flags [none],
proto UDP (17), length 94, bad cksum 0 (->585)!)
    127.0.0.1.53 > 127.0.0.1.36488: [udp sum ok] 45091 q: AAAA?
marvin.luigilauro.it. 1/0/0 marvin.luigilauro.it. AAAA
2002:4e2e:3890::1 (66)
13:57:40.582706 IP (tos 0x0, ttl 64, id 30473, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->5af)!)
    127.0.0.1.32588 > 127.0.0.1.53: [udp sum ok] 12906+ A? 256.1. (23)
13:57:40.582774 IP (tos 0x0, ttl 64, id 30474, offset 0, flags [none],
proto UDP (17), length 51, bad cksum 0 (->5ae)!)
    127.0.0.1.53 > 127.0.0.1.32588: [udp sum ok] 12906 NXDomain* q: A?
256.1. 0/0/0 (23)
13:57:40.582856 IP (tos 0x0, ttl 64, id 30475, offset 0, flags [none],
proto UDP (17), length 65, bad cksum 0 (->59f)!)
    127.0.0.1.39760 > 127.0.0.1.53: [udp sum ok] 12907+ A?
256.1.luigilauro.it. (37)
13:57:40.582907 IP (tos 0x0, ttl 64, id 30476, offset 0, flags [none],
proto UDP (17), length 81, bad cksum 0 (->58e)!)
    127.0.0.1.53 > 127.0.0.1.39760: [udp sum ok] 12907 q: A?
256.1.luigilauro.it. 1/0/0 256.1.luigilauro.it. A 78.46.56.144 (53)
13:57:40.774019 IP (tos 0x0, ttl 64, id 30490, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->59c)!)
    127.0.0.1.55919 > 127.0.0.1.53: [udp sum ok] 12908+ AAAA? 0.0.0.0. (25)
13:57:40.774079 IP (tos 0x0, ttl 64, id 30491, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->59b)!)
    127.0.0.1.53 > 127.0.0.1.55919: [udp sum ok] 12908 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:40.774131 IP (tos 0x0, ttl 64, id 30492, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->58c)!)
    127.0.0.1.49922 > 127.0.0.1.53: [udp sum ok] 12909+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:40.774178 IP (tos 0x0, ttl 64, id 30493, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->56f)!)
    127.0.0.1.53 > 127.0.0.1.49922: [udp sum ok] 12909 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:40.774313 IP (tos 0x0, ttl 64, id 30494, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->598)!)
    127.0.0.1.22170 > 127.0.0.1.53: [udp sum ok] 12910+ AAAA? 0.0.0.0. (25)
13:57:40.774349 IP (tos 0x0, ttl 64, id 30495, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->597)!)
    127.0.0.1.53 > 127.0.0.1.22170: [udp sum ok] 12910 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:40.774397 IP (tos 0x0, ttl 64, id 30496, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->588)!)
    127.0.0.1.19121 > 127.0.0.1.53: [udp sum ok] 12911+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:40.774439 IP (tos 0x0, ttl 64, id 30497, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->56b)!)
    127.0.0.1.53 > 127.0.0.1.19121: [udp sum ok] 12911 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:41.685514 IP (tos 0x0, ttl 64, id 30568, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->54e)!)
    127.0.0.1.52521 > 127.0.0.1.53: [udp sum ok] 12912+ AAAA? 0.0.0.0. (25)
13:57:41.685564 IP (tos 0x0, ttl 64, id 30569, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->54d)!)
    127.0.0.1.53 > 127.0.0.1.52521: [udp sum ok] 12912 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:41.685607 IP (tos 0x0, ttl 64, id 30570, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->53e)!)
    127.0.0.1.61587 > 127.0.0.1.53: [udp sum ok] 12913+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:41.685664 IP (tos 0x0, ttl 64, id 30571, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->521)!)
    127.0.0.1.53 > 127.0.0.1.61587: [udp sum ok] 12913 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:41.685741 IP (tos 0x0, ttl 64, id 30572, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->54a)!)
    127.0.0.1.26792 > 127.0.0.1.53: [udp sum ok] 12914+ AAAA? 0.0.0.0. (25)
13:57:41.685767 IP (tos 0x0, ttl 64, id 30573, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->549)!)
    127.0.0.1.53 > 127.0.0.1.26792: [udp sum ok] 12914 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:41.685799 IP (tos 0x0, ttl 64, id 30574, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->53a)!)
    127.0.0.1.15896 > 127.0.0.1.53: [udp sum ok] 12915+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:41.685827 IP (tos 0x0, ttl 64, id 30575, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->51d)!)
    127.0.0.1.53 > 127.0.0.1.15896: [udp sum ok] 12915 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:41.686562 IP (tos 0x0, ttl 64, id 30576, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->546)!)
    127.0.0.1.45727 > 127.0.0.1.53: [udp sum ok] 12916+ AAAA? 0.0.0.0. (25)
13:57:41.686587 IP (tos 0x0, ttl 64, id 30577, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->545)!)
    127.0.0.1.53 > 127.0.0.1.45727: [udp sum ok] 12916 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:41.686620 IP (tos 0x0, ttl 64, id 30578, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->536)!)
    127.0.0.1.31647 > 127.0.0.1.53: [udp sum ok] 12917+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:41.686647 IP (tos 0x0, ttl 64, id 30579, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->519)!)
    127.0.0.1.53 > 127.0.0.1.31647: [udp sum ok] 12917 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:41.686721 IP (tos 0x0, ttl 64, id 30580, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->540)!)
    127.0.0.1.28638 > 127.0.0.1.53: [udp sum ok] 12918+ AAAA? 127.0.0.1. (27)
13:57:41.686744 IP (tos 0x0, ttl 64, id 30581, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->53f)!)
    127.0.0.1.53 > 127.0.0.1.28638: [udp sum ok] 12918 q: AAAA?
127.0.0.1. 0/0/0 (27)
13:57:41.686780 IP (tos 0x0, ttl 64, id 30582, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->530)!)
    127.0.0.1.24312 > 127.0.0.1.53: [udp sum ok] 12919+ AAAA?
127.0.0.1.luigilauro.it. (41)
13:57:41.686830 IP (tos 0x0, ttl 64, id 30583, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->513)!)
    127.0.0.1.53 > 127.0.0.1.24312: [udp sum ok] 12919 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
13:57:41.687457 IP6 (flowlabel 0x402fb, hlim 64, next-header UDP (17)
payload length: 33) 2002:4e2e:3890::1.2511 > 2002:4e2e:3890::1.53:
[udp sum ok] 50405+ NS? gmx.net. (25)
13:57:41.687497 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.53 > 2002:4e2e:3890::1.2511: [udp sum ok] 50405
Refused- [0q] 0/0/0 (12)
13:57:44.711135 IP6 (flowlabel 0x402fb, hlim 64, next-header UDP (17)
payload length: 36) 2002:4e2e:3890::1.2511 > 2002:4e2e:3890::1.53:
[udp sum ok] 12720+ NS? kernel.org. (28)
13:57:44.711271 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.53 > 2002:4e2e:3890::1.2511: [udp sum ok] 12720
Refused- [0q] 0/0/0 (12)
13:57:47.737360 IP6 (flowlabel 0x402fb, hlim 64, next-header UDP (17)
payload length: 35) 2002:4e2e:3890::1.2511 > 2002:4e2e:3890::1.53:
[udp sum ok] 26174+ NS? intel.com. (27)
13:57:47.737498 IP6 (hlim 64, next-header UDP (17) payload length: 20)
2002:4e2e:3890::1.53 > 2002:4e2e:3890::1.2511: [udp sum ok] 26174
Refused- [0q] 0/0/0 (12)
13:57:50.758742 IP (tos 0x0, ttl 64, id 30966, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->3c0)!)
    127.0.0.1.13879 > 127.0.0.1.53: [udp sum ok] 12920+ AAAA? 0.0.0.0. (25)
13:57:50.758802 IP (tos 0x0, ttl 64, id 30967, offset 0, flags [none],
proto UDP (17), length 53, bad cksum 0 (->3bf)!)
    127.0.0.1.53 > 127.0.0.1.13879: [udp sum ok] 12920 q: AAAA?
0.0.0.0. 0/0/0 (25)
13:57:50.758840 IP (tos 0x0, ttl 64, id 30968, offset 0, flags [none],
proto UDP (17), length 67, bad cksum 0 (->3b0)!)
    127.0.0.1.15898 > 127.0.0.1.53: [udp sum ok] 12921+ AAAA?
0.0.0.0.luigilauro.it. (39)
13:57:50.758882 IP (tos 0x0, ttl 64, id 30969, offset 0, flags [none],
proto UDP (17), length 95, bad cksum 0 (->393)!)
    127.0.0.1.53 > 127.0.0.1.15898: [udp sum ok] 12921 q: AAAA?
0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
2002:4e2e:3890::1 (67)
13:57:50.758997 IP (tos 0x0, ttl 64, id 30970, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->3ba)!)
    127.0.0.1.47528 > 127.0.0.1.53: [udp sum ok] 12922+ AAAA? 127.0.0.1. (27)
13:57:50.759031 IP (tos 0x0, ttl 64, id 30971, offset 0, flags [none],
proto UDP (17), length 55, bad cksum 0 (->3b9)!)
    127.0.0.1.53 > 127.0.0.1.47528: [udp sum ok] 12922 q: AAAA?
127.0.0.1. 0/0/0 (27)
13:57:50.759063 IP (tos 0x0, ttl 64, id 30972, offset 0, flags [none],
proto UDP (17), length 69, bad cksum 0 (->3aa)!)
    127.0.0.1.14953 > 127.0.0.1.53: [udp sum ok] 12923+ AAAA?
127.0.0.1.luigilauro.it. (41)
13:57:50.759101 IP (tos 0x0, ttl 64, id 30973, offset 0, flags [none],
proto UDP (17), length 97, bad cksum 0 (->38d)!)
    127.0.0.1.53 > 127.0.0.1.14953: [udp sum ok] 12923 q: AAAA?
127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
2002:4e2e:3890::1 (69)
13:57:55.408180 IP (tos 0x0, ttl 64, id 31169, offset 0, flags [none],
proto UDP (17), length 64, bad cksum 0 (->2ea)!)
    127.0.0.1.32716 > 127.0.0.1.53: [udp sum ok] 12924+ A?
c302.cloudmark.com. (36)
13:57:55.408232 IP (tos 0x0, ttl 64, id 31170, offset 0, flags [none],
proto UDP (17), length 80, bad cksum 0 (->2d9)!)
    127.0.0.1.53 > 127.0.0.1.32716: [udp sum ok] 12924 q: A?
c302.cloudmark.com. 1/0/0 c302.cloudmark.com. A 208.83.137.115 (52)
13:57:55.905779 IP (tos 0x0, ttl 64, id 31191, offset 0, flags [none],
proto UDP (17), length 62, bad cksum 0 (->2d6)!)
    127.0.0.1.17539 > 127.0.0.1.53: [udp sum ok] 949+ A? public.pyzor.org. (34)
13:57:55.905833 IP (tos 0x0, ttl 64, id 31192, offset 0, flags [none],
proto UDP (17), length 78, bad cksum 0 (->2c5)!)
    127.0.0.1.53 > 127.0.0.1.17539: [udp sum ok] 949 q: A?
public.pyzor.org. 1/0/0 public.pyzor.org. A 188.40.77.236 (50)


> Why does your resolver map an AAAA query 0.0.0.0.luigilauro.it to 2002:4e2e:3890::1 ?

This is perfectly fine, my authoritative DNS is set up for resolving
any *.luigilauro.it to my A and AAAA public addresses (78.46.56.144
and 2002:4e2e:3890::1).

This is what I want and need and have been using with no problems with
any software for years, not to mention it's a 'standard' widely
used... ;-)

>Where does this query for AAAA on 127.0.0.1 come from?

Don't really know, I'm not querying anything, I just asked
spamassassin to use nameserver 127.0.0.1 which is an IPv4, not a
server name to be resolved.

I wish I could just make spamassassin do what he should do: query the
dns on the IPv4 127.0.0.1 for the needed addresses, not try to resolve
127.0.0.1 as a name against my domain or other weird, wrong and
unneeded things :-)

> This one above is probably the most bizarre, and possibly a cause
> of all the remaining trouble. Do you have some DNS wildcarding
> or other misconfiguration in your DNS server?

It's not a MISconfiguration, really :-)

It's a wanted, needed, standard DNS configuration, to use wildcard in domains.

What is a 'misconfiguration' is spamassassin trying to resolve
127.0.0.1 as a domain name instead of treating it for what it is: an
ipv4 to call for DNS requests :-)

> Check also your /etc/hosts file.

domain luigilauro.it
::1             localhost
127.0.0.1       localhost

> Good, one thing less to worry about :)

Indeed.

Thanks for the help Mark, you are really kind.

-- 
Luigi Lauro

Re: Weird problem with Spamassassin and Net::DNS, using ipv6 and failing - more info

Posted by Mark Martinec <Ma...@ijs.si>.
Luigi,

> marvin% perl -le 'use IO::Socket::INET6; print IO::Socket::INET6->VERSION'
> 2.57

Good.

> > Try capturing your traffic on a loopback interface for port 53:
> 
> This is the output with -vv for protocol decode with my recursive
> local DNS on 127.0.0.1 and my authorative DNS on listening on
> 2002:4e2e:3890::1 and 78.46.56.144

Forgot option -n, makes it unknown whether 'localhost' is 127.0.0.1 or ::1.

>     localhost.domain > localhost.52422: [udp sum ok] 32762 q: AAAA?
> 0.0.0.0.luigilauro.it. 1/0/0 0.0.0.0.luigilauro.it. AAAA
> 2002:4e2e:3890::1 (67)

Why does your resolver map an AAAA query 0.0.0.0.luigilauro.it to 2002:4e2e:3890::1 ?

>     localhost.13073 > localhost.domain: [udp sum ok] 32771+ AAAA?
> 127.0.0.1. (27)

Where does this query for AAAA on 127.0.0.1 come from?

>     localhost.domain > localhost.52409: [udp sum ok] 32772 q: AAAA?
> 127.0.0.1.luigilauro.it. 1/0/0 127.0.0.1.luigilauro.it. AAAA
> 2002:4e2e:3890::1 (69)

This one above is probably the most bizarre, and possibly a cause
of all the remaining trouble. Do you have some DNS wildcarding
or other misconfiguration in your DNS server?

Check also your /etc/hosts file.

> > then we can decide whether the fault lies with SpamAssassin and
> > its underlying inet sockets module, or with your DNS server(s),
> > or even with your TCP stack implementation. Btw, what OS is that?
>
> Stack implementation I seriously doubt, this is one of the most solid ones.
> It's a FreeBSD 8.0-STABLE, so serious business ;-)

Good, one thing less to worry about :)

  Mark