IPv6 Address Types.
Address types.
ipv6 has three main address types.
- Unicast , these can be of the global or local-link variety or special address type.
- Multicast , these are the same as conventional multicast addresses , packets are destined for all interfaces in a multicast group
- Anycast, here packets are destined for the one of a group of interfaces usually the nearest one are determined by a routing protocol.
One of the key things to grasp about ipv6 is that an interface can and normally does have multiple addresses. It is common for an interface to have global addresses and local address. In the wonderful world of MS windows you even have more than one type of the local-link address type just to make thing more interesting and harder to firewall, so lets start.
Unicast address type 1 – Global Unicast
The first type of ipv6 address we will discuss is the global unicast , this is comparable to the publicly routeable address in ipv4 that we are assigned by our ISP. Again the main difference is the lenght (128 bits) and the fact that we are no longer trying to conserve these addresses. Currently IANA is assigned addresses from the 2000::/3 range. Let take an example.
We have been given the following range by our ISP 2003:0001:0002::/48.
We then subnet this address ourselves to the 64 bit lenght. So taking the first subnet of this we would get
2003:0001:0002:0001::/64 . So we are using the fourth field for subnetting and 0001 is the first subnet in the range so that is what we will use for our example network. Rememeber we need the last remaining 64 bits for the Interface ID (host address).
Next we will assign an address to the the host in our chosen network.
2003:001:0002:0001:0000:0000:0000:0001/64 which of course we can write in short hand notation as
2003:1:2:1::1/64.
So we now have our global address for our end server or workstation. In the simple old world of ipv4 internal hosts are normally given an rfc 1918 address such as 10.x.x.x but in the new world of ipv6 everyhost has an address that be routed on the internet without the sue of NAT , this is another key aspect of ipv6 that need s to be grasped.
Unicast address type 2- Local Addresses.
Local addresses in ipv6 come in a few different variety but the all serve the same function to facilate communication on local links like LAN’s P2P link etc. They are kinda comparable to ipv4 private address but are different. When two node or router are communcating on the lan with each other they will use these address as the source and destination of the traffic. For example two router speaking OSPF will use thier link-local address when going through neighbour relationship phases and the like. Ipv6 had its own set of host/router discovery mechanisms ( like arp in ipv4 but way m0re advanced) and again these local address are used. So they are a key factor of ipv6.
Type 2.1 Site Local.
This address is comparable to a private address in ipv4. It is only routeable within the organsation and not on the internet. Its scope is limited to this context. When configured, a site-local address uses a specific prefix (FEC0::/10). Owing to the fuzzy terms of its definition and the fact that it isnt neccasary to have private address of this type in ipv6 ( we have enough addresses even for the dog in the street and his iphone !!!) this type had been depricated.
Type 2.1 Link-Local.
This one is very important and a key requirement in understanding ipv6. These addresses have a smaller scope than site local. There are not routeable within the organisation they stay on the local link. Router will not forward these off a link. They are used for ipv6 neighbour discovey and other inter host/router communcation on a given physical link as mentioned above. Also and importantly they allow addressing hosts to communicate without using a globally-routable address prefix. Again routers will not forward packets with link-local addresses. These addresses ar configure within the range of FE80::10.
So how are these address assigned , well they can be manually assigned on the network card are per ipv4 or they can be assigned by a process known as Ipv6 Stateless Address Autoconfiguration , I know, sounds funky enough but is is cool and important to grasp. It contracts with another method of addressing which is stateful and involves a server and a protocol called DHCPv6. So stateless equals no DCHP and no annoying dhcp scope assignment happy days. So stateful configuration is dhcp and static assignment and stateless is stateless address autoconfig.
The IPv6 Stateless Address Autoconfiguration Process.
Step 1.
The device generates a link local address. The format is as follows. The first part of the address is always the same. the first ten bits are as follows. The address is generates at his stage is often call the EUI-64 address, dont ask me why !!!.
fe80 HEX
1111 1110 10 BIN
The next 54 are all always zeros.
fe80 000000000000000000000000000000000000000000000000000000
So the first network portion of the address is fe80::/64.
Step 1.1
The host portion of the node remember it is always the last 64 bits of the address is then assigned in the following manner. The mac address of the network card is taken and modified in two ways to come up with the ipv6 address. Example work best as always.
First of all the address is split by inserting the fffe characters in the middle of the mac address 00:90:2717:fc:0f. resulting in 00:90:27:ff:fe:17:fc:0f.
Step 1.2
The universal /local U/L bit is flipped. This is the 7th bit of the address in this case 00 hex in decimal is 00000000 would result in 00000010 which gives an overall address of 02:90:27:ff:fe:17:fc:0f.
So we now have an overall link-local ipv6 address for our host which is fe80::0290:27ff:fe17:fc0f.
That is the first step in the process but by itself it is quite an important step. We are now going to proceed in detailing how the node/router can attain its global address by using stateless address autoconfiguration.
Step 2.
The node tests to see if the address it has generates is indeed unique. Unlikely put the step is mandatory. It sends out a neigbour solicitation message using the neighbour discovery protocol. ( The topic of the next post) It then listens for a neighbour advertisement in response to see if any other host is using this address. It is higlhy unlikely but neccessary.
Step 3
Assuming that the address is unique the node goes ahead and assigns itself the address. It is now active and able to communicate on the local link but not the wider network or internet.
Step 4.
The node will hen try and contact a lcoat router to try and find out how it will get its other address the global unicast address ,remember in ipv6 addressing interfaces generally have two or more addresses. The node will send a router solicitation message to find out oif there are any router on the link and if so , ask the router how to progress. The router may tell the host to sue dhcpv6 but in most cases it will tell the node to use our old bud stateless auto-config. So to attain its global unicast address the will get the first part of the address ie the network prefix from the router and use the same process as in step 1 above to get the last 64 bits for the host address.
example, we have assign a network address of 2003:3:3:3/64 for the network , the node use the eui-64 address as detailed above and has a global address of 2003:3:3:3/640290:27ff:fe17:fc0f.
Step 5
The node now assigns its second address to the interface and now has the two address it needs for both local link communication and global communcation , cool enough all done without us having to ring the monkeys on the systems team , now that my friends is a good thing….
Unicast address type 3 – Special Address types.
Type 3.1 IPv6/ Ipv4 Address Embedding.
Now just so we are under no illusions here , ipv6 and ipv6 will both be running side by side in dual stack configuration for quite a while . So as result we need a way to represent ipv4 address in the world of ipv6 so that is where address embedding comes in. IPv6 is backward compatible with IPv4, provided that special techniques are used. For example, to enable communication between “islands” of IPv6 devices connected by IPv4 networks, tunneling may be employed. To support IPv4/IPv6 compatibility, a scheme was developed to allow IPv4 addresses to be embedded within the IPv6 address structure. This method takes regular IPv4 addresses and puts them in a special IPv6 format so they are recognized as being IPv4 addresses by certain IPv6 devices.
These address exist on devices that are classified are dual stack that being that theysupport both ipv6 and ipv4 prootcols.
Lets look at an example , th following figure is belonging to the brillaint www.tcpipguide.com , one of the best website out there.
So as you can see the first 96 bits are all zeros and the last 32 bits of the address as the ipv4 address , it is a simple enough process.
Multicast Addresses.
Multicast is a very big topic in Ipv6. The conventional purpose of multicast , to allow one source to send one stream to multiple receipents still exists however there are more features and way more uses for mcast technology in ipv6. Now one of the best things about ipv6 is that there is no more broadcast . That as the americans would say is totally awesome. No more pesky arp requests and no more spotty teeangers causing havic with childlike man in the middle attacks.
Under Ipv4 mulitcast was utilised under the D block of reserved addresses. with Ipv6 mulicast has it own leading prefix of range of address . These are
FF00::/8 in hex
1111:1111:0000:0000 in Binary.
So any address leading with this address is multicast. As you can see we have load and loads and laods of buts left for a whole range of multicast groups and enetities.
The next two fields in the address are used to specify the scope and range of the addres are highlightd in the figure below again from www.tcpipguide.com below. So in total the multicast group will up the first 16 bits of the address field.
I am sparse on information about the current use and naming convention of the flags field .
Here a quote from tcpipguide.com
Flags: Four bits are reserved for flags that can be used to indicate the nature of certain multicast addresses. At the present time the first three of these are unused and set to zero. The fourth is the “T” (Transient) flag. If left as zero, this marks the multicast address as a permanently-assigned, “well-known” multicast address, as we will see below. If set to one, this means this is a transient multicast address, meaning that it is not permanently assigned.
The Scope ID field is somewhat easier to understand however. These four bits are used to dictate the scope or proposed location of the multicast group f0r example scope id 2 is link local only , scope id E ot 15 in dec is global so ca be used on the internet.
The list is as follow some are not yet in use and as with all ipv6 specification are subject to change.
0 reserved
1 interface-local scope
2 link-local scope
3 reserved
4 admin-local scope
5 site-local scope
6 (unassigned)
7 (unassigned)
8 organization-local scope
9 (unassigned)
A (unassigned)
B (unassigned)
C (unassigned)
D (unassigned)
E global scope
F reserved
The remainding 112 bits ar used to address the actual multicast group.
So lets take a few examples.
A link local multicast address to al router in the nodes on the link would be ff02::1 ( note ::1 as a host is all node on a link by)
All nodes on the local network site would be ff05::1.
Lets pretend that a new NTP server was created by NASA for the whole internet , The potential address would be ff0e:0001::1.
Anycast Addresses.
An anycast address is something quite new and sweet in terms onf load balanacing it is essence identifies multiple interfaces by one address . With the appropriate routing topology, packets addressed to an anycast address are delivered to a single interface (the nearest interface that is identified by the address). The nearest interface is defined as being closest in terms of routing distance. A multicast address is used for one-to-many communication, with delivery to multiple interfaces. An anycast address is used for one-to-one-of-many communication, with delivery to a single interface.
That all then , next I ll be looking at ipv6 neighbour discovery protocol. As some of the concepts here are new to me I welcome comments.


Hello,
Good detailing on the topic.
December 24, 2009 at 7:33 pm
Pingback: ipv6 neighbour discovery « cciepursuit
Thanks for your post. Helpful.
October 24, 2011 at 2:26 pm