Commit 1be9b30a3b17 ("dhcp6: use dns_name_from_wire_format") introduced a stricter validation of domains received via DHCPv6, by using function dns_name_from_wire_format() which rejects the domain when it is missing the terminating zero label. According to RFC 4704 § 4.2, DHCPv6 servers should always add the zero label: To send a fully qualified domain name, the Domain Name field is set to the DNS-encoded domain name including the terminating zero-length label. To send a partial name, the Domain Name field is set to the DNS-encoded domain name without the terminating zero-length label. [...] Servers SHOULD send the complete fully qualified domain name in Client FQDN options. In practice, there is at least on common DHCPv6 server implementation (dnsmasq) that sends the FQDN option without the ending zero-length label; after upgrading to the new systemd, the client cannot parse the option and therefore the machine doesn't get the hostname provided by dnsmasq. This commit restores the old behavior that considers a domain valid even when it's missing the terminating zero label. Here's a quick reproducer: --8<-- ip link add veth0 type veth peer name veth1 ip netns add ns1 ip link set veth1 netns ns1 ip link set veth0 address 00:11:22:33:44:55 ip link set veth0 up ip -n ns1 link set veth1 up ip -n ns1 address add dev veth1 fd01::1/64 ip netns exec ns1 dnsmasq \ --pid-file=/tmp/dnsmasq.pid --no-hosts \ --bind-interfaces --interface veth1 --except-interface lo \ --dhcp-range=fd01::100,fd01::200 --enable-ra \ --dhcp-host 00:11:22:33:44:55,foobar & cat <<EOF > /etc/systemd/network/veth0.network [Match] Name=veth0 [Network] DHCP=ipv6 EOF networkctl reload networkctl up veth0 sleep 5 hostname --8<-- Without this change, systemd-networkd prints the following message and doesn't set the hostname from DHCP: veth0: DHCPv6 client: Failed to parse FQDN option, ignoring: Bad message
System and Service Manager
Details
Most documentation is available on systemd's web site.
Assorted, older, general information about systemd can be found in the systemd Wiki.
Information about build requirements is provided in the README file.
Consult our NEWS file for information about what's new in the most recent systemd versions.
Please see the Code Map for information about this repository's layout and content.
Please see the Hacking guide for information on how to hack on systemd and test your modifications.
Please see our Contribution Guidelines for more information about filing GitHub Issues and posting GitHub Pull Requests.
When preparing patches for systemd, please follow our Coding Style Guidelines.
If you are looking for support, please contact our mailing list, join our IRC channel #systemd on libera.chat or Matrix channel
Stable branches with backported patches are available in the stable repo.
We have a security bug bounty program sponsored by the Sovereign Tech Fund hosted on YesWeHack
Repositories with distribution packages built from git main are available on OBS