Ray Patrick Soucy

IPv6 Stateless Autoconfiguration Explained

With IPv6 there is no need to use DHCP for address assignment.  IPv6 allows for stateless autoconfiguration as per RFC 4862.

With stateless autoconfiguration the MAC-48 hardware address of the Ethernet controller is used to create a unique host segment of an IPv6 address.  The network segment of the global unicast address is obtained through discovery (Router Advertisement).

Example:

A host with a MAC-48 address of 00:0B:DB:91:B2:38 on a network with a prefix of 2001:DB8:1::/64) would have a stateless autoconfiguration address of: 2001:DB8:1::20B:DBFF:FE91:B238.  Note that stateless autoconfiguration only works on networks that are a /64 in size.

The host segment 020B:DBFF:FE91:B238 is derived from the MAC-48 address with the insertion of FFFE at byte 4.  The first byte is then has the 7th bit set to 1 (incremented by 2) changing 000BDB91B238 to 020BDBFFFE91B238.

This is the case for most implementations of IPv6.  The exception to this is Microsoft Windows.

Due to privacy concerns with using the MAC-48 in creating a unique host segment, Microsoft proposed RFC 3041, Privacy Extensions for Stateless Address Autoconfiguration in IPv6.  Using this method a privacy address is generated by the additional step of hashing the MAC-48 using MD5.

This feature can be turned off using the Windows command prompt:

netsh interface ipv6 set privacy disabled

Stateless Autoconfiguration does not provide additional host configuration information, such as DNS servers.  On a dual-stack network, it will make use of the IPv4 DNS servers configured.

Alternatively, DHCPv6 can be configured to provide stateful address configuration, or work in harmony with stateless configuration and only provide DNS server information.  At this point, however, most client operating systems do not yet support DHCPv6.