summaryrefslogtreecommitdiff
path: root/src/libsystemd-network/dhcp-lease-internal.h
diff options
context:
space:
mode:
authorEugene Yakubovich <eyakubovich@gmail.com>2014-06-27 15:00:06 -0700
committerTom Gundersen <teg@jklm.no>2014-06-29 15:18:21 +0200
commite1ea665edac17d75fce01b72dadfa3211b60df2c (patch)
tree9f1d4c8ae93862cf5ebae973cd48d053ef34c0dd /src/libsystemd-network/dhcp-lease-internal.h
parented942a9eb22d50f667909ad6184b45015d28d054 (diff)
downloadsystemd-e1ea665edac17d75fce01b72dadfa3211b60df2c.tar.gz
Add support for DHCP static route options
This adds support for DHCP options 33 and 121: Static Route and Classless Static Route. To enable this feature, set UseRoutes=true in .network file. Returned routes are added to the routing table.
Diffstat (limited to 'src/libsystemd-network/dhcp-lease-internal.h')
-rw-r--r--src/libsystemd-network/dhcp-lease-internal.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/libsystemd-network/dhcp-lease-internal.h b/src/libsystemd-network/dhcp-lease-internal.h
index ff09583604..d4675f3e47 100644
--- a/src/libsystemd-network/dhcp-lease-internal.h
+++ b/src/libsystemd-network/dhcp-lease-internal.h
@@ -32,6 +32,12 @@
#include "sd-dhcp-client.h"
+struct sd_dhcp_route {
+ struct in_addr dst_addr;
+ struct in_addr gw_addr;
+ uint8_t dst_prefixlen;
+};
+
struct sd_dhcp_lease {
RefCount n_ref;
@@ -52,8 +58,9 @@ struct sd_dhcp_lease {
size_t ntp_size;
struct in_addr *policy_filter;
size_t policy_filter_size;
- struct in_addr *static_route;
+ struct sd_dhcp_route *static_route;
size_t static_route_size;
+ size_t static_route_allocated;
uint16_t boot_file_size;
uint16_t mdr;
uint16_t mtu;