In my research, I ran across a sample that sends random data over UDP port 53,
and dpkt.dns.DNS was raising IndexError when this happened. I sat down and
improved the unpack_name implementation.
The new implementation:
* is not recursive.
* detects pointer loops as soon as possible and raises UnpackError.
* always raises dpkt.UnpackError when the packet is malformed in some way.
* uses '.'.join() to build the return value instead of repeatedly appending to a string.
This resulted in a series of patches (unit tests and the actual implementation).
Original issue reported on code.google.com by george.m...@gmail.com on 15 Jan 2014 at 2:41
Original issue reported on code.google.com by
george.m...@gmail.com
on 15 Jan 2014 at 2:41Attachments: