3 ms·
I can't really ready Ruby, but it seems to me that the code fragment for implementing domain name compression does not handle compression loops.
by fweimer 4y ago
I can't really ready Ruby, but it seems to me that the code fragment for implementing domain name compression does not handle compression loops.
- fanf2 4y agoYes, avoiding loops in DNS name decompression is the first thing I check in new DNS code. I think Julia updated this post after publication with a caveat about compression loops and other potential problems. (I think the only other missing thing is checking the name is not too long.) So from my point of view this tutorial passes with flying colours because it clearly says that name compression is the worst part of the DNS wire format, and that there are lurking dangers if you are writing something more serious than experimental code for learning.