In message <[email protected]>, Dave Lawrence writes:
> Tony Finch writes:
> > Wouldn't it be much simpler to use the normal fixed address length, so
> > that serializers and parsers can just choose a bcopy based on the address
> > family?
>
> Simple in its way, yes, but of course there still has to be packet
> parsing checks based on declared lengths. That's where I'm not seeing
> that SHOULD versus MUST is making any sort of meaningful
> implementation complexity difference.
>
> Also, when every byte counts for possibly having to end up doing tcp
> fallback, saving one might make a difference of not having to do that.
bytes = (bits + 7) / 8
/* check lsb bits are zero */
if (bits % 8 != 0) {
mask = ~0 << (8 - bits % 8);
if ((x[bytes - 1] & mask) != x[bytes - 1])
FORMERR;
}
/* check additional octets allowed by SHOULD are zero */
for (i = bytes; i < length; i++)
if (x[i] != 0)
FORMERR;
> _______________________________________________
> DNSOP mailing list
> [email protected]
> https://www.ietf.org/mailman/listinfo/dnsop
--
Mark Andrews, ISC
1 Seymour St., Dundas Valley, NSW 2117, Australia
PHONE: +61 2 9871 4742 INTERNET: [email protected]
_______________________________________________
DNSOP mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/dnsop