Overblog Suivre ce blog
Editer l'article Administration Créer mon blog
27 mai 2013 1 27 /05 /mai /2013 10:46

 


When first encountering IPv6, one of the first questions that pops up to mind is : What are the address spaces, what have become of my private address ranges ( 10./8, 172.16./12 and 192.168./16 ). We will quickly review the addressing ranges of IPv6.

One important thing to note is that whereas in IPv4, a network interface has only one IP address, in IPv6 a network interface can have several addresses sumultaneously.



The practical over-simplified view :

 

 

IPv6 address=           Network ID:Host ID
                                         64 bits      64 bits

Host ID can be all 0 or all f ( ie 0:0:0:0 or ffff:ffff:ffff:ffff). There is no broadcast address or all zeros network address like in IPv4 )



fE80::/64 are link-local addresses. The host ID is autoconfigured. They are mandatory for IPv6 to function. You may use them, but you don't change / assign them.


2000::/64 to 3fff:ffff:ffff:fff/64 are Global Addresses. They are allocated by the ISP. They are the equivalent
of the IPv4 public IPs. You may assign the host ID. You may assign subnets' IDs if the ISP allocated you more than a single /64.


fd00::/64 to fdff:ffff:ffff:ffff/64 are Unique Local Addresses. They are not routable over the Internet. You can set them and assign them at will for your private use. They are the equivalent of IPv4 private IPs ( 10./8, 172.16./12, 192.168./16 )



The detailled view


IPv6 Address =           Network ID+Subnet ID    +         Host ID
                                     --------------64 bits--------      --------64 bits-----------


FE80: Link local Unicast address

Linklocal
Each Network interface has a link-local address. It is mandatory for IPv6 to function.
Link-local address is limited to the local link, ie. it'll reach a directly linked host, or pass through a switch, but won't pass through a router. It basically maps the old IPv4 Broadcast Domain, ie Subnet.

Link-local addresses official definition is fe80::/10 followed with 54 0 bits, thus :

fe80::/64+[Host ID]

So just look for fe80::/64 for all practical aims.

They remind a little of our IPv4 169./8 autoconfiguration addresses, though they have a broader role and are mandatory for Ipv6 to function properly.

You don't set them, they are auto-assigned. But you can toggle on/off the RFC 4941 state, which changes the way the Host ID is created

They are used for routing.




2001: Global Unicast Address


These are the Globally Routable Addresses. They pass through both Routers ( ie. they are Routable ) and The Internet ( ie. they are Globally Routable ).

They are the equivalent of our IPv4 public addresses

Their official definition is 2000/3 thus leading to an effective 2000::/64 to 3fff:ffff:ffff:fff/64

 The Network ID is assigned by the ISP. The Host ID may be assigned by you at your will ( Static, DHCP, SLAAC ). If the ISP assigned you with more than a single /64 ( ie a /63 for an exemple ), you can assign and use the subnet ID at will.




FD: Unique Local Address

Uniquelocal

 

These are Routable Addresses. They pass through Routers ( ie. they are Routable ), but won't pass through the Internet Routers( ie. they are not Globally Routable ).

 

Here is how they relate to Global Addresses :

 

Global

 

They are the equivalent of our IPv4 private addresses ( 10./8, 172.16/12, 192.168/16 ).

They are defined as fc00::/7 ( ie fc00::/8 and fd00::/8 ), but fc00::/8 is unassigned now.

Their official definition is fd/8+Network ID/40+Subnet ID/16.

( Actually it's fc00::/7 +L bit/1 +Network ID/40+Subnet ID/16 )

The Network ID should be randomly generated ( RFC 4193 ). Actually, the standard requires the 40 bits network ID to be randomly generated using the algorithm specified in the standard. Basically the algorithm performs the hashing of the sum ( MAC address + Time )

Here you can use the RFC 4193 algorithm : link

http://www.kame.net/~suz/gen-ula.html

Here an implementation, that doesn't use MAC address : link
http://unique-local-ipv6.com/

RFC 4193 : link
http://tools.ietf.org/html/rfc4193#section-3.2.1


The reason for this comes from the goal of Unique Local Addresses : They are for private local use, but may extend beyond the scope of a single site by use of private links ( Optical site to site connection, VPN, ... ). So to avoid the task of massive site network renumbering in case of 2 sites' merging, RFC 4193 requires pseudo-random numbering to be used, making mergings seamless and easy.

The Subnet ID part ( last 16 bits ) are used for subnet numbering, easiing route aggregation.


Note that for private non professionnal use ( ie home lan, network lab, server lab, ... ), clearly knowing that there won't be no merging or linking of sites, and because this fd address range is non-routable over the Internet, some people may choose to go without RFC 4193 randomness recomendation, and use a simpler scheme. Professionnals shouldn't/


Let's generate a ULA, using RFC 4193. We get : fd07:382d:ce43::/48

We can now use the last 16 bits for Subnet ID, thus giving us these 65536 subnets :

fd07:382d:ce43:0000::/64 to fd07:382d:ce43:ffff::/64


For easy memorization, we can map the IPv4 and the IPv6 addresses on our network. Some ULA exemples :

. simple flat ULA network : fd07:382d:ce43:0000::/64

. simple multi subnets ULA network numberings :

Host1=fd07:382d:ce43:0::1        host2=fd07:382d:ce43:0::2        host3=fd07:382d:ce43:0::3        <--- subnet1     fd07:382d:ce43:0::/64

host1b=fd07:382d:ce43:1::1    host2b=fd07:382d:ce43:1::2    host3b=fd07:382d:ce43:1::3    <---subnet2    fd07:382d:ce43:1::/64

etc...


. maping an 192.168.0.0/24 IPv4 subnet numbering to an IPv6 numbering for easy memorization :

Host1        192.168.0.14        fd07:382d:ce43:0:192:168:0:14
Host2        192.168.0.254      fd07:382d:ce43:0:192:168:0:254
etc ...


. maping two 192.168.x./24 IPv4 subnets numbering to two IPv6 subnets numbering for easy memorization :

Host1        192.168.0.14        fd07:382d:ce43:0:192:168:0:14        <-- network 1       fd07:382d:ce43:0::/64
Host2        192.168.0.254      fd07:382d:ce43:0:192:168:0:254

Host3        192.168.1.4        fd07:382d:ce43:1:192:168:1:4        <-- network 2       fd07:382d:ce43:0::/64
Host4        192.168.1.1        fd07:382d:ce43:1:192.168:1:1


. another maping of two 192.168.x./24 IPv4 subnets numbering to two IPv6 subnets numbering for easy memorization :

Host1        192.168.0.14        fd07:382d:ce43:0::14
Host2        192.168.0.254      fd07:382d:ce43:0::254

Host3        192.168.1.4        fd07:382d:ce43:1::4
Host4        192.168.1.1        fd07:382d:ce43:1::1



. maping a 10.0.0.0/8 subnet to an IPv6 subnet :

Host1        10.0.0.1        fd07:382d:ce43:0::1
Host2        10.0.1.4        fd07:382d:ce43:0::1:4
Host3        10.0.3.100    fd07:382d:ce43:0::3:100
Host4        10.1.0.1        fd07:382d:ce43:0::1:0:1


. another maping of a 10.0.0.0/8 subnet to an IPv6 subnet :

Host1        10.0.0.1        fd07:382d:ce43:0::10:0:0:1
Host2        10.0.1.4        fd07:382d:ce43:0::10:0:1:4
Host3        10.0.3.100    fd07:382d:ce43:0::10:0:3:100
Host4        10.1.0.1        fd07:382d:ce43:0::10:1:0:1



Partager cet article

Repost 0
Published by computer outlines - dans IPv6
commenter cet article

commentaires

Présentation

  • : Computer Outlines Blog
  • : Blog mainly focused over IPv6, Windows Server, and Networking in general.
  • Contact

Recherche

Liens