[systemd-devel] [PATCH 00/11] DHCPv6 DNS and NTP information

Patrik Flykt patrik.flykt at linux.intel.com
Fri Jul 10 05:30:24 PDT 2015


	Hi,

This patch set adds support for DNS and NTP DHCPv6 options. The information
obtained is written to file in link_save() in systemd-networkd in order
to be used by others.

The first patch is a bug fix triggered when going from Information request
to the full DHCPv6 address lease in the test case when the lease was also
stored as a part of the information request exchange in patch two.

Two helper functions are introduced and used when extracting DNS, NTP
address, domain search list and NTP host name options. Support was added
also for the deprecated SNTP option, it can still be discovered in some
semi-ancient networks.

The test case is improved to look for the DNS and NTP information and
ystemd-networkd is enhanced with the functionality to write this information
nto the link state file. I might be missing something with systemd-networkd
n this area, though.

I do feel a bit rusty with systemd, some conventions may have changed since
last time.

Please review,

       Patrik


Patrik Flykt (11):
  sd-dhcp6-client: Fix unreferencing DHCPv6 lease on client reset
  sd-dhcp6-client: Save a DHCPv6 lease also with Information Reply
  dhcp6-option: Add helper function for fetching IPv6 addresses
  dhcp6-option: Add helper function for uncompressed domain names
  sd-dhcp6: Add support for DHCPv6 DNS Recursive Name Server option
  sd-dhcp6: Add support for DHCPv6 DNS Domain Search List option
  sd-dhcp6: Add support for DHCPv6 NTP Server Option
  sd-dhcp6: Support deprecated SNTP Configuration Option
  test-dhcp6-client: Add tests for DNS and NTP options
  network: Add function to serialize an IPv6 address
  network: Save DNS and NTP data for a DHCPv6 link

 src/libsystemd-network/dhcp6-internal.h       |   7 +-
 src/libsystemd-network/dhcp6-lease-internal.h |  20 ++-
 src/libsystemd-network/dhcp6-option.c         |  77 +++++++++-
 src/libsystemd-network/dhcp6-protocol.h       |   8 +-
 src/libsystemd-network/network-internal.c     |  15 ++
 src/libsystemd-network/network-internal.h     |   2 +
 src/libsystemd-network/sd-dhcp6-client.c      |  43 +++++-
 src/libsystemd-network/sd-dhcp6-lease.c       | 196 +++++++++++++++++++++++++-
 src/libsystemd-network/test-dhcp6-client.c    |  65 ++++++++-
 src/network/networkd-link.c                   |  62 ++++++++
 src/systemd/sd-dhcp6-lease.h                  |   8 +-
 11 files changed, 491 insertions(+), 12 deletions(-)

-- 
2.1.4



More information about the systemd-devel mailing list