[Dnsmasq-discuss] [PATCH] DHCPv6 - Multiple reservations for single host

Harald Jensås hjensas at redhat.com
Tue Jan 7 12:57:02 GMT 2020


On Tue, 2020-01-07 at 10:51 +0100, Pali Rohár wrote:
> Hi Harald! What are differences between your patch and mine which
> adds
> support for it too (plus honor assignment based on MAC address)?
> http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/2019q4/013545.html
> 

My patch allow creating multiple IPv6 address reservations for the same
host (MAC address), your patch allow a single IPv6 address to be
reserved for multiple MAC addresses?

Also, Your patch allow dnsmasq to abandon a lease if a new request
using the same MAC address but a different IAID comes. My patch instead
makes it possible to configure multiple IPv6 addresses for a single MAC
address. The first request matching MAC will get leased to that
CLID/IAID combo. Another request from the same MAC using a different
CLID/IAID combo get's a lease using the second reservation, and so on.
No lease is abandoned before either the client does a release or the
lease_time is reached without the client renewing.

I came up with this approach after realizing Simon already expressed
that the approach of allowing the server to abandon a lease is a bad
idea. Quoting Simon from [1]:

""" Allowing the IDs to change is a bad idea,
    since in DHCPv6 they are the only thing
    that identifies a client. If you lease an
    address to a CLID/IAID combo, then you
    can't lease it to another CLID/IAID until
    that lease has expired. """


As I understand the RFC's your approach of allowing a lease to be
abandoned is not allowed. Personally and practically I like the `honor
assignment based on MAC address` patch, but it would also break
compatibility with a client that intentionally ask for multiple leases.
A client is allowed to do so according to RFC. Maby the `honor
assignment based on MAC address` patch need's an iteration that adds a
configuration flag enabling the behaviour + doc update that clarifies
the behaviour is breaking RFC complience?


--
Harald

[1] 
http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/2017q1/011289.html




More information about the Dnsmasq-discuss mailing list