summaryrefslogtreecommitdiffhomepage
path: root/src/odhcpd.h
diff options
context:
space:
mode:
authorNick Hainke <vincent@systemli.org>2021-01-02 23:27:03 +0100
committerHans Dedecker <dedeckeh@gmail.com>2021-01-03 15:42:49 +0100
commit3bda90079ec5574ef469e2a7804808302f17769d (patch)
treea3a7e8ce9f1f25d211838631b31d587f9f293205 /src/odhcpd.h
parentb75bcad7bd5fd03f64011a532b9960d78e4aac22 (diff)
odhcpd: add option for setting preferred lifetime
"valid_lft" and "preferred_lft" are different. If the "preferred_lft" is expired the prefix should be avoided in source prefix selection. However, the interface is allowed to still receive downstream traffic. preferred_lfetime: Limit for preferred lifetime of a prefix If you want the old behavior, you have to set preferred_lifetime to the same value as leasetime. Signed-off-by: Nick Hainke <vincent@systemli.org> Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
Diffstat (limited to 'src/odhcpd.h')
-rw-r--r--src/odhcpd.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/odhcpd.h b/src/odhcpd.h
index 2f7dd25..45b6784 100644
--- a/src/odhcpd.h
+++ b/src/odhcpd.h
@@ -182,6 +182,7 @@ struct dhcp_assignment {
struct sockaddr_in6 peer;
time_t valid_until;
+ time_t preferred_until;
#define fr_timer reconf_timer
struct uloop_timeout reconf_timer;
@@ -286,6 +287,7 @@ struct interface {
uint32_t ra_retranstime;
uint32_t ra_hoplimit;
int ra_mtu;
+ uint32_t preferred_lifetime;
// DHCP
uint32_t dhcp_leasetime;