MaddieM4 / pymads

A fork of the pymds authoritative DNS server, designed for asynchronous lookup without domain restrictions.
GNU Lesser General Public License v3.0
4 stars 2 forks source link

Bad response packets #9

Closed MaddieM4 closed 11 years ago

MaddieM4 commented 11 years ago
philip@philip-desktop:~/projects/pymads$ dig @localhost -p 8990 sushi.org
;; Got bad packet: extra input data
55 bytes
97 7a 84 00 00 01 00 01 00 00 00 00 05 73 75 73          .z...........sus
68 69 03 6f 72 67 00 00 01 00 01 05 73 75 73 68          hi.org......sush
69 03 6f 72 67 00 00 01 00 01 00 00 07 08 00 07          i.org...........
35 2e 34 2e 33 2e 32                                     5.4.3.2

I suspect it has something to do with rdata length. Investigating now.

MaddieM4 commented 11 years ago

Turns out the problem is that A addresses are formatted as 4 octets, not text as I misunderstood the standard. Am doing a bit of overhaul to fix.

MaddieM4 commented 11 years ago

Will probably need to do similar fixes for AAAA and such. Anything where the fallback behavior of "just byteify it and hope for the best" is insufficient. In other news, JESUS CHRIST we need some Persei up in this place.