Commit graph

10 commits

Author SHA1 Message Date
Thomas Hindoe Paaboel Andersen 71d35b6b55 tree-wide: sort includes in *.h
This is a continuation of the previous include sort patch, which
only sorted for .c files.
2015-11-18 23:09:02 +01:00
Lennart Poettering 3733eec3e2 dhcp: stop using refcnt.h
No need to invole atomic ops in single-threaded APIs, let's simplify
this.
2015-08-26 21:05:53 +02:00
Patrik Flykt 41e4615d4f sd-dhcp6: Support deprecated SNTP Configuration Option
Although the SNTP option specified in RFC 4075 has been deprecated, some
servers are still sending NTP information with this option. Use the SNTP
information provided only if the NTP option is not present.

Update the test case as SNTP information is also requested.
2015-08-21 11:23:22 +03:00
Patrik Flykt 6599680e2d sd-dhcp6: Add support for DHCPv6 NTP Server Option
Support NTP server and multicast addresses and NTP server domain names
as specified in RFC 5908.
2015-08-21 11:23:22 +03:00
Patrik Flykt 5da1b97f3c sd-dhcp6: Add support for DHCPv6 DNS Domain Search List option
Support DHCPv6 DNS search list option as specified in RFC 3646. This
option contains a list of DNS search domains encoded without compression
as specified in Section 8. of RFC 3315.
2015-08-21 11:23:22 +03:00
Patrik Flykt 7bd8e95d44 sd-dhcp6: Add support for DHCPv6 DNS Recursive Name Server option
Support DHCPv6 DNS server option as specified in RFC 3646. This option
contains a list of IPv6 DNS server addresses.
2015-08-21 11:23:21 +03:00
Patrik Flykt ed6ee21953 sd-dhcp6-client: Implement Rapid Commit
Add a Rapid Commit option to Solicit messages and expect a Reply to
be received instead of an Advertise. When receiving a DHCPv6 message
from the server in state Solicit, continue testing whether the
message is a Reply. Ease up the message type checking, it's not fatal
if the message is of a wrong type.

Add helper functions to set/get the rapid commit of a lease. See
RFC 3315, sections 17., 17.1.2., 17.1.4. and 18.1.8.
2014-06-26 16:10:47 +03:00
Patrik Flykt 709d6710d0 sd-dhcp6-lease: Add helper function to compute remaining expiry time
Create a helper function to compute the remaining time in seconds from
time T2 to the IPv6 address with the longest lifetime. The computed
time is used as the Maximum Retransmission Duration in Rebinding state.
See RFC 3315, section 18.1.4. for details.
2014-06-26 16:10:21 +03:00
Patrik Flykt ea3b3a75ab sd-dhcp6-lease: Add functions for accessing lease and addresses
Add support functions for accessing the current client lease as well
as iterating over the addresses and get their preferred and valid
lifetimes.
2014-06-19 15:44:44 +03:00
Patrik Flykt 3fb2c57038 sd-dhcp6-lease: Add DHCPv6 lease handling
Create a structure describing a DHCPv6 lease. Add internal functions
for creating a new lease and accessing the server ID, preference and
IAID. Provide functions for clearing addresses and associated timers.

External users are initially given only the capabilities of
referencing and unreferencing the lease structure.
2014-06-19 15:44:44 +03:00