Age | Commit message (Collapse) | Author |
|
Fixes fallout from 3733eec3e292e4ddb4cba5eb8d3bd8cbee7102d8.
|
|
a) drop handling of obsolete or unused DHCP options time_offset,
mtu_aging_timeout, policy filter, mdr, ttl, ip forwarding settings.
Should this become useful one day we can readd support for this.
b) For subnet mask and broadcast it is not always clear whether 0 or
255.255.255.255 might be valid, hence maintain a boolean indicating
validity next to it.
c) serialize/deserialize broadcast address, lifetime, T1 and T2 together
with the rest of the fields in dhcp_lease_save() and
dhcp_lease_load().
d) consistently return ENODATA from getter functions for data that is
missing in the lease.
e) add missing getter calls for broadcast, lifetime, T1, T2.
f) when decoding DHCP options, generate debug messages on parse
failures, but try to proceed if possible.
g) Similar, when deserializing a lease in dhcp_lease_load(), make sure
we deal nicely with unparsable fields, to provide upgrade compat.
h) fix some memory allocations
|
|
If we handly arbitrary data we should use "void*" pointers, not
"uint8_t*", how go intended C to be used.
|
|
Everywhere else we call the generic user data pointer just "userdata",
rather than "user_data". Let's do this here, too.
|
|
No need to invole atomic ops in single-threaded APIs, let's simplify
this.
|
|
When we make sd-dhcp public one day we really should not make
sd_dhcp_lease_save() and sd_dhcp_lease_load() public, since it's pretty
much only useful as internal utility for networkd itself.
|
|
This one is simply to add: encode the tzdata timezone in the DHCP
options and optionally make use of it.
|
|
This stores private-zone DHCP options inside of their respective DHCP
lease. These options aren't used by networkd (what would it do with
them?), but saving them will allow other programs to query the values.
To improve performance, the options are stored in ascending order by
tag.
|
|
This adds support for option 43 (Vendor Specific Information) to
libsystemd-network DHCP code. The option carries an opaque object of n
octets, interpreted by vendor-specific code on the clients and
servers.
[@zonque: adopted to new unhexmem() API]
|
|
The lease is usually tied to the client ID, so users of the
lease may want to know what client ID it was acquired with.
|
|
Based on patch by Dan Williams.
|
|
Also change the default prefixlen function to only access the first octet of the in_addr.
|
|
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.
|
|
|
|
|
|
Export the NTP servers so timesyncd can use them.
|
|
The DHCP RFC does not require the DHCP server to send a subnet mask, so if it
is missing, let's try to use the default subnet masks based on address class.
In case the class the address belongs to does not have a default subnet mask,
we fail as before.
Also improve logging when handling invalid dhcp messages, and simply ignore them
rather than stop the whole dhcp client.
|
|
|
|
This is necessary when mounting /dev/nfs based on a DHCP lease.
|
|
This is similar to sd-login, but exposes the state of networkd rather than logind.
Include it in libsystemd-dhcp and rename it to libsystemd-network.
|