Skip to content

server: set lease time in DHCP response

Administrator requested to merge lease_expiration into master

Some clients (dhclient) reject responses if a lease is not configured, and that's a "must provide" in the spec that I missed previously. This responds with a lease time of ~45 days (to keep things simple), but this is only to appease picky clients since the server ignores the lease time.

Interestingly enough, networkmanager's built-in dhcp client didn't have this problem, so it's apparently not checking that the responses from the server follow the spec closely!

Also see: https://datatracker.ietf.org/doc/html/rfc2131#page-28 https://datatracker.ietf.org/doc/html/rfc1533#section-9.2

Merge request reports

Loading