Bug 14361 - udhcpc ignores T1 and T2 values
Summary: udhcpc ignores T1 and T2 values
Status: NEW
Alias: None
Product: Busybox
Classification: Unclassified
Component: Networking (show other bugs)
Version: unspecified
Hardware: All Linux
: P5 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-20 00:17 UTC by luke-jr+busyboxbugs
Modified: 2021-11-20 00:17 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description luke-jr+busyboxbugs 2021-11-20 00:17:12 UTC
It seems the code just hard-coded T1 at half the lease time

https://git.busybox.net/busybox/tree/networking/udhcp/dhcpc.c?h=1_34_stable#n1802

Values provided by the DHCP server (opt 58, 59) just get ignored...

Use case: I issue 24 hour leases, and want the lease to be used that long if necessary (eg, if router is down), but I also want DHCP renewals every minute so: 1) I can rapidly give static IP leases and have the clients pick up on them; and 2) router reboots can quickly rebuild their lease table without persistent state.