[Dnsmasq-discuss] Adding Route Information Option to prefixes in RA

Ilya Ponetaev iponetaev at dlink.ru
Mon Sep 1 07:59:14 BST 2014


The RFC is definitely unclear about size of prefix to be sended, but as 
I concluded from it the only restriction is that we must set net and 
host bits of prefix to zero. But on the other hand previous approach 
leads to wasting resources, so I reworked code to send only necessary data.

On 08/31/2014 01:59 AM, Simon Kelley wrote:

>
> In principle, this is fine.
>
> Just based on reading the RFC (which isn't very clear) I think the
> strategy of always sending the prefix as full-sized may not be valid, or
> at least may confuse some hosts.
>
>
>
> Prefix Length
>                 8-bit unsigned integer.  The number of leading bits in
>                 the Prefix that are valid.  The value ranges from 0 to
>                 128.  The Prefix field is 0, 8, or 16 octets depending on
>                 Length.
>
> I read this as saying that if the prefix length is <= 64, then the
> Prefix field should be 8 octets long and the total option length should
> be 2*8 octets, and if the prefix-length is zero, the total option length
> should be 1 unit if 8 octets, just for the header.
>
> So I don't think it's necessarily legit to always make the option length
> 24 octets, certainly reducing the option length for short prefix is
> definitely OK, so we should do that, to confirm to the principle of "be
> conservative about what you send"
>
> Cheers,
>
> Simon.
>

-- 
Best regards,
Ilya Ponetaev
D-Link Corp.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dnsmasq_ra_ri_v2.diff
Type: text/x-patch
Size: 1665 bytes
Desc: not available
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20140901/1b98599d/attachment.bin>


More information about the Dnsmasq-discuss mailing list