Viktor Dukhovni <[email protected]> wrote:
>
> c. The most recent pointer expands to a domain that moves
> past the location of the pointer, without arriving at that
> pointer, because it is just part of the data of some label.
> For example:
>
> ... 10 05 l a r r y 10 m o e NNN MMM c u r l y [...]
> | initial length 10 label |ptr 10 back|
> |len 5 label |len 10 pointer-skipping label |
>
> yielding the domain name:
>
> \005larry\010moe.larry.moe\NNN\MMMcurly.[...]
That's disgusting :-)
The high-water-mark algorithm forbids it, though, because the "ptr 10
back" does not go back before the HWM, which is the initial octet
with value 10. (BIND and Net::DNS use the HWM algorithm, for example.)
But you can pull a similar overlap trick if you reach back a little
further, like this:
#!/usr/bin/perl
use Net::DNS;
my $buffer = "\x06\x03foo\xc0\x00\x03bar\x00";
my $dn = decode Net::DNS::DomainName (\$buffer, 1);
printf "%s\n", $dn->string;
output is:
foo.\003foo\192\000.bar.
Tony.
--
f.anthony.n.finch <[email protected]> http://dotat.at/
Humber: West or northwest 4 or 5, occasionally 6 until later. Moderate or
rough. Mainly fair. Moderate or good.
_______________________________________________
DNSOP mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/dnsop