08-26-2015 11:06 PM - edited 03-01-2019 05:48 PM
i was going through ipv6 address types
i see that for Global unicast address is 2000::/3 (0010 0000 0000....like that so it used first three bit)
so if we do like this for Link local address which is FE80::/10 (1111 1110 1000 000... like this only 9 bit is utilized)
why not ipv6 link local address FE80::/9 instead of FE80::/10
same way they used for unique local address which is FC00::/7(1111 1100 0000...like this only 6 bit utilized)
why not ipv6 Unique local address FC00::/6 instead of FC00::/7??
thanks
Solved! Go to Solution.
08-28-2015 12:49 AM
Hello again,
In IPv6 addressing the 'first' three bits being 001 is significant. An IPv6 address with 000 at the left-most position does not adhere to the rule that the interface ID portion of the address is 64-bits long.
I suppose you could liken it to IPv4 classful addressing. Addresses must have a particular left-most binary pattern and mask:
Class A : '0' /8
Class B: '10' /16
Class C: '110' /24
Also bear in mind that decimal number 2000 is not really significant, it is just where IANA has started allocating addresses from. All you need to remember is that the binary representation must start with 001 and the mask must be no smaller than /3 for it to be a valid GUA.
fe80:ffff:ffff:ffff:ffff:ffff:ffff:ffff and feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff is the range of addresses availble with FE80::0/9
Take a look here:
http://www.gestioip.net/cgi-bin/subnet_calculator.cgi
...it is a good way to familirise yourself with the binary construction and impact of masks on IPv6 addresses.
Also read these RFCs, in particular these sections:
https://tools.ietf.org/html/rfc4291#section-2.5.4
https://tools.ietf.org/html/rfc3587#section-2
cheers,
Seb.
08-27-2015 02:05 AM
Hi there,
The binary prefix should not be trimmed back to the first occurance of a '1'. The '0' is part of the prefix and is used to identify the address type.
Granted you could try and cut down the prefix but the address you would end up with would mean that a great proportion of addresses would no longer be identified as you wanted.
FE80::0/10
gives:
fe80:0000:0000:0000:0000:0000:0000:0000-
fe80:ffff:ffff:ffff:ffff:ffff:ffff:ffff
..but FE80::0/9
gives:
fe80:0000:0000:0000:0000:0000:0000:0000-
feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff
So you now have addresses that would be allocated using the /9 mask but would no longer be classified as link-local.
Take a look here, the IPv6 addressing specficiation demands it:
https://tools.ietf.org/html/rfc4291#section-2.4
cheers,
Seb.
08-27-2015 09:18 AM
hi,
why not using until "1"??
if you see global unicast address 2000::/3 its prefix only uses until last "1" so if we do by this way why not for link local address also??
and other question
what is fe80:ffff:ffff:ffff:ffff:ffff:ffff:ffff and feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff ??
how do you calculate that??
thanks for reply
08-28-2015 12:49 AM
Hello again,
In IPv6 addressing the 'first' three bits being 001 is significant. An IPv6 address with 000 at the left-most position does not adhere to the rule that the interface ID portion of the address is 64-bits long.
I suppose you could liken it to IPv4 classful addressing. Addresses must have a particular left-most binary pattern and mask:
Class A : '0' /8
Class B: '10' /16
Class C: '110' /24
Also bear in mind that decimal number 2000 is not really significant, it is just where IANA has started allocating addresses from. All you need to remember is that the binary representation must start with 001 and the mask must be no smaller than /3 for it to be a valid GUA.
fe80:ffff:ffff:ffff:ffff:ffff:ffff:ffff and feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff is the range of addresses availble with FE80::0/9
Take a look here:
http://www.gestioip.net/cgi-bin/subnet_calculator.cgi
...it is a good way to familirise yourself with the binary construction and impact of masks on IPv6 addresses.
Also read these RFCs, in particular these sections:
https://tools.ietf.org/html/rfc4291#section-2.5.4
https://tools.ietf.org/html/rfc3587#section-2
cheers,
Seb.
08-28-2015 08:17 AM
hi,
so that means that for link local we have to use /10 mask
1111 1110 1000 0000 0000 0000 0000 0000 .......it for link local address
1111 1110 1100 0000 0000 0000 0000 0000 .......it is for site local address
thanks for reply
08-29-2015 11:44 AM
Yes, the minimum mask length ensures that bit pattern remains intact and that addresses can be allocated and treated correctly.
FYI, site-local was depreciated a long time again:
https://www.ietf.org/rfc/rfc3879.txt
cheers,
Seb.
10-03-2015 01:33 AM
FE80::0/10 gives: fe80:0000:0000:0000:0000:0000:0000:0000- fe80:ffff:ffff:ffff:ffff:ffff:ffff:ffff ..but FE80::0/9 gives: fe80:0000:0000:0000:0000:0000:0000:0000- feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff
Correction:
FE80::0/10
gives:
fe80:0000:0000:0000:0000:0000:0000:0000-
febf:ffff:ffff:ffff:ffff:ffff:ffff:ffff
..but FE80::0/9
gives:
fe80:0000:0000:0000:0000:0000:0000:0000-
feff:ffff:ffff:ffff:ffff:ffff:ffff:ffff
My cheat sheet:
FE80::/10 | fe80 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | link-local unicast / link-scoped unicast RFC 4291 |
febf |
FEC0::/10 | fec0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | site-local unicast (deprecated) |
feff |
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide