[Dnsmasq-discuss] It works: multiple dnsmasqs running

Simon Kelley simon at thekelleys.org.uk
Tue Oct 16 14:00:16 BST 2012


On 15/10/12 22:22, Gene Czarcinski wrote:

> The address we have is going to be ff00::1:2 so checking the address
> list against it is useless.  Scanning daemon->if_names is still needed.
> Also daemon->interfaces is lacking some info we need namely AF_INET or
> AF_INET6 but it seems to me that it could easily be added.

>
> We need to go through daemon->interfaces to find the ip6 addresses
> associated with the device name we have.  Then, that address needs to be
> compared with any IPv6 addresses specified in --listen-address.
>
> We could just do this check for dhcp6 ... would that break things?

That looks close to correct. It's interesting to compare it with the 
DHCPv4 code, which checks the --listen-address parameter against the 
primary address of the arrival interface and if that fails against all 
of them.

For IPv6, "primary address" is not a very useful concept, so the best 
solution is to compare the --listen-address parameter against all 
addresses of the arrival interface.
>
> Any favorite approaches: just dhcp6 .. or .. extra calling sequence
> parameter/flag ... or ... a new, separate function?  The last two are
> the "safest".

New code. the DHCPv4 check_listen_addrs() function is a good prototype.

I'll see if I can produce something later today.


Simon.

>
> Gene
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>




More information about the Dnsmasq-discuss mailing list