diff options
author | Lennart Poettering <lennart@poettering.net> | 2015-08-05 22:20:36 +0300 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-08-05 22:20:36 +0300 |
commit | b5a306ef73f9c31499f2d97f8b9d3db514b56a09 (patch) | |
tree | 9f1970d84dc720b7bc86824242d95cdedee784e1 /src/libsystemd-network/dhcp-lease-internal.h | |
parent | 8dbf626535136b6fe6e1cf7d4ff251b2f505087c (diff) | |
parent | 9b57d9aee48e78bb591baecea1c3dbafd974759f (diff) |
Merge pull request #877 from crawford/dhcp-private-options-v4
networkd: save private-zone DHCP options
Diffstat (limited to 'src/libsystemd-network/dhcp-lease-internal.h')
-rw-r--r-- | src/libsystemd-network/dhcp-lease-internal.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/libsystemd-network/dhcp-lease-internal.h b/src/libsystemd-network/dhcp-lease-internal.h index 6e00b1ad30..5a3fcddb1b 100644 --- a/src/libsystemd-network/dhcp-lease-internal.h +++ b/src/libsystemd-network/dhcp-lease-internal.h @@ -27,6 +27,7 @@ #include "refcnt.h" #include "util.h" +#include "list.h" #include "dhcp-protocol.h" @@ -38,6 +39,14 @@ struct sd_dhcp_route { unsigned char dst_prefixlen; }; +struct sd_dhcp_raw_option { + LIST_FIELDS(struct sd_dhcp_raw_option, options); + + uint8_t tag; + uint8_t length; + void *data; +}; + struct sd_dhcp_lease { RefCount n_ref; @@ -74,11 +83,14 @@ struct sd_dhcp_lease { size_t client_id_len; uint8_t *vendor_specific; size_t vendor_specific_len; + LIST_HEAD(struct sd_dhcp_raw_option, private_options); }; int dhcp_lease_new(sd_dhcp_lease **ret); int dhcp_lease_parse_options(uint8_t code, uint8_t len, const uint8_t *option, void *user_data); +int dhcp_lease_insert_private_option(sd_dhcp_lease *lease, uint8_t tag, + const uint8_t *data, uint8_t len); int dhcp_lease_set_default_subnet_mask(sd_dhcp_lease *lease); |