-
Notifications
You must be signed in to change notification settings - Fork 141
Enhancement - Let kernel handle interface management #594
Description
In Linux, the kernel can do all the heavy lifting of Neighbour Discovery, Router Solicitation, handling Router Advertisements, generating link local addresses, using prefixes, etc.
Add an option to startup dhcpcd for an interface, which will monitor incoming IPv6 traffic similar to radvd. This will give us a feed of Router Advertisements, allowing dhcpcd to determine what "mode" (Managed/DHCPv6 or Other/SLAAC) to begin operating in.
Include ability to send enabling configurations to kernel (see below).
Basically, to take Linux as an example, we should be writing to
(net.ipv6.conf..accept_ra), (net.ipv6.conf..addr_gen_mode),
(net.ipv6.conf.*.use_tempaddr) to enable RS (optionally
stable-privacy, tempaddr address - but respect the values for those if
they're already non-zero), for any interface that needs it and let the
kernel configure those items, before we let DHCPv6 request anything
else.Martin-Éric
So an example DHCPv6 startup might look like
- dhcpcd is asked to start up eth0 as IPv6
- dhcpcd configures RS options in kernel space for eth0 as per its per-interface config
- dhcpcd requests kernel set net.ipv6.conf.eth0.accept_ra and begins listening to RA stream
- dhcpcd receives RA, that provides a prefix and flags M=1,O=0
- dhcpcd leave LL generation up to kernel, but as instructed, begins DHCPv6 solicitation