SLAAC
What
Allows IPv6 devices to configure their own IPv6 addresses, without needing a DHCPv6 server
StateLess Address AutoConfiguration
Why
Makes the proces simpler, by not needing a central DHCP server
Also means one less point of failure, and one less central bottleneck
Since there is no central state, it also cannot be lost
Concepts
- Router Advertisements (RAs)
- Routers periodically announce themselves, on the "all nodes" multicast address
ff02::1
- Routers periodically announce themselves, on the "all nodes" multicast address
- Router Solicitation (RS)
- Devices can request routers to announce themselves, instead of waiting
- Sent to the "all routers" multicast at
ff02::2
How
- Generate link-local address
- Either based on MAC address, or random (more privacy friendly)
- Do Duplicate Address Detection: "Is anyone using fe80:21a:2bff:fe3c:4d5e?"
- If no response, the address is unique and can be used
- If there is a response, the address is in use, try again from the start with a newly generated link-local
- Discover routers: send RS message to all routers multicast
- Can also wait for periodic RAs if desired
- Response/RA will contain router config such as:
- Network prefix
- Prefix length
- Flags
- Default gateway info
- Prefix valid and preferred lifetimes
- Generate global scope address
- Based on router prefix + MAC/random
- E.g. prefix
2001:db8:1::/64+ MAC/random::21a:2bff:fe3c:4d5e->2001:db8:1::21a:2bff:fe3c:4d5e/64
- Use Duplicate Address Detection again
- Only need to check with local devices, since no other devices will use the same prefix
- Device now has:
- Link-local address
- Global scope address
- Default gateway information