Age | Commit message (Collapse) | Author |
|
In case multiple dhcp uci sections are configured and one section contains
RA config while the other section does not; the RA interface config of the
first section will be overwritten by the second section.
Fix this by setting the default values for ra_management and ndp_proxy_routing
uci parameters when the interface is created and by removing the overwrite check
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
The valid_until parameter which is set to 0 for static DHCPv6
assignments was overwritten depending on the received DHCPv6 message
which turned the assignment into having a finite lifetime and thus not
static anymore.
Fix this by checking if the valid_until parameter holds infinite
lifetime before updating it.
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Fix assignment of static DHCPv6 leases which was broken
by commit 6c3bc0141dacc88992583d6f2cdc8a360df7422d.
At the same time fix lifetime check of existing assignments
having a finite lifetime
Fixes FS#309
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Add a CMake FIND_PATH and INCLUDE_DIRECTORIES searching for
libubox/uloop.h. Some external toolchains which do not include standard
locations would fail to find the header otherwise.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
|
|
Display infinite valid lifetime as -1 both in ubus
and statefile
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
The "ignore" option is correctly loaded. Actually observe it as
documented.
Signed-off-by: Karl Palsson <karlp@etactica.com>
|
|
Currently the loglevel is hardcoded to LOG_WARNING, even though there is
debug log messages. Allow setting the loglevel via cli option.
Include basic help text because we're adding command line options.
Signed-off-by: Karl Palsson <karlp@etactica.com>
|
|
Add support for DHCPv4 clients proposing a leasetime;
proposed leasetime will be accepted if it does not
exceed either the pool or configured lease leastime.
Further rework the duplicated leasetime logic which
was in place.
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Fix ubus valid parameter being displayed as a negative number;
also display infinite lifetime as INT32_MAX
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Keep the valid_until assignment parameter in sync with the
leasetime assigned to the DHCP client when handling DHCP
request message.
This guarantees the contents of the ubus dhcp ipv4leases valid
parameter is in sync with the client leasetime
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Add support for infinite leasetime value; this can be done by
specifying "infinite" as leasetime value which is similar to
dnsmasq infinite leasetime support.
Specifying "infinite" as leasetime is valid for both the host
and dhcp uci sections.
A DHCPv4/DHCPv6 assignment is now considered infinite if valid_unil
holds the value 0.
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
|
|
Drop pointless syslog. The single line just doubles the amount of lines
logged to syslog without adding any value.
Signed-off-by: Karl Palsson <karlp@etactica.com>
|
|
Patch by Daniel Dickinson
Signed-off-by: Steven Barth <steven@midlink.org>
|
|
config: blobmsg_check_attr expects bool type as last argument
|
|
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Fix interface ifname overwrite in case UCI dhcp section contains ifname or networkid parameter
|
|
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
|
|
|
|
|
|
Clamp router lifetime per RFC 4861
|
|
When a prefix lifetime was greater than UINT16_MAX, we would advertise a
shorter router lifetime (even potentially 0). Saturate instead.
|
|
Correctly byteswap DNS lifetimes in RAs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Revert "RFC: dhcpv4 support openwrt alias ip addr"
|
|
|
|
Fixes compile issues and infinite lifetimes
|
|
RFC: dhcpv4 support openwrt alias ip addr
|
|
|
|
Fix compile issue due to comparison between signed and unsigned integers
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|