2. 2
2
What is IPv4 ?
1) An IPv4 address has 32 bits.(Binary Notation)
10000000 00001011 00000011 00011111
NOTE:- Above notation is representation of IPv4 address in binary
format.
2) Another notation is Dotted Decimal Notation
128.11.3.31
NOTE:- Above notation is representation of IPv4 address in dotted decimal
notation.
3) IPv4 address are unique and universal.
4) The addess space of a IPv4 is 2^32 or 4,294,967,296.
NETWORK ADDRESS TRANSLATION.
3. 3
3
IPv4 Addressing
There is two methods of IPv4 addressing:
---Classful Addressing
---Classless Addressing
In classful addressing , the address space is divided
five classes:
A, B, ,C, D and E.
5. 5
5
Classless Addressing
In classless addressing every entity is granted a block of addresses as per
requirement.
In class addesing the address block must be contiguous.
The number of addresses in a block must be a power of 2 (1, 2, 4 ,8…………..)
6. 6
6
Need of IPv6
IPv6 addresses are four times the size of IPv4 addresses.
An IPv4 address has 32 bits, while IPv6 address has 128 bits.
For IPv4, this pool is 32-bits (232) in size and contains
4,294,967,296 IPv4 addresses.
The IPv6 address space is 128-bits (2128) in size, containing
340,282,366,920,938,463,463,374,607,431,768,211,456 IPv6
addresses.
7. 7
7
What is IPv6 ?
1) An IPv6 address has 128 bits.
0010 0000 0000 0001 0000 1101 1011 1000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0101 0010
0000 0000 0000 0000 0000 0000 0000 0001
NOTE:- Above notation is representation of IPv6 address
in binary format.
2) To convert the above binary notation into IPv6 format
2001:0db8:0000:0000:0000:0052:0000:0001
This is an entirely “legal” representation, a well-formed address
8. 8
8
As we know in IPv6
each 16-bit field is
textually represented by
four hexadecimal
characters, the value of
each 16-bit field may
have hexadecimal
values 0x0000 through
0xFFFF.
9. 9
Preferred Format of IPv6 Addresses
0000:0000:0000:0000:0000:0000:0000:0000
0000:0000:0000:0000:0000:0000:0000:0001
2001:0410:0000:1234:FB00:1400:5000:45FF
3ffe:0000:0000:0000:1010:2a2a:0000:0001
3FFE:0B00:0C18:0001:0000:1234:AB34:0002
FE80:0000:0000:0000:0000:0000:0000:0009
FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF
Examples of IPv6 Addresses in the Preferred Format
9
10. 10
Successive 16-bit fields made of 0s of an IPv6 address.
• When one to multiple successive 16-bit fields of 0 characters are present,
we can represent these fields of 0s as :: (a double colon).
• Only one :: is permitted in an IPv6 address.
• This method makes many IPv6 addresses very small/
.
10
12. 12
Leading 0s in 16-Bit Fields of an IPv6 Address
• It is applicable to each 16-bit hexadecimal field of an IPv6 address when
one or more leading 0s are present.
• Leading 0s from left of each 16 bit field can simply be removed to
simplify the length of an IPv6 address.
• If every hexadecimal character of a 16-bit field is set to 0, at least
one 0 character must be kept.
12
14. 14
IPv6 Address with an Embedded IPv4 Address
• IPv6 address is of 128 bits out of which 64 bits are used for networks and
rest 64 bits are used for hosts.
• To embedded IPv4 address within the IPv6 address, the first part of the IPv6 address
uses the hexadecimal representation, and the IPv4 address part is in decimal format.
• IPv6 address is represented by the high-order 96-bit set to 0 followed by the 32-bit
of the IPv4 address.
• The prefix for the IPv4-mapped IPv6 address is represented by the high-order
80-bit set to 0, then the next 16-bit set to 1, and finally followed by the 32-bit of the
IPv4 address of the local node.
• Lets take an example to convert IPv4 address into IPv6 address.
IPv4 Address:- 10.11.12.13 /8
1) From above we can conclude for IPv4 address there are in total 24 (32 -8) bits for hosts.
2) So in IPv6 Network bits = 128 – 24 (hosts bits as per IPv4 address) = 104 bits.
14
15. 15
3) As we know to embedded IPv4 address into IPv6, the first 96 bits are in IPv6
format
and rest 32 bits are in IPv4 format.
4) So we can write 0000.0000.0000.0000.0000.10.10.10.10 as IPv6 address. In this
IPv6
address still last 32 bits are in IPv4 format.
4) 10.11.12.13 in IPv4 can be represented in binary format as:
00001010.00001011.00001100.00001101
5) The above notation can be converted into Hexadecimal format as:-
0a0b.0c0d
6) So IPv6 can be written as:-
0000.0000.00000.0000.0000. 0a0b.0c0d /104
15