0% found this document useful (0 votes)
87 views95 pages

Unit 4

The document discusses IPv6 addressing modes and address notation. It describes the 128-bit IPv6 address format which includes a site prefix, subnet ID, and interface ID. It explains rules for representing IPv6 addresses through zero suppression and leading zero compression to simplify very long strings of zeros. The key rule is that zero compression can only be used once in an IPv6 address.

Uploaded by

Nipurn Bhaal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
87 views95 pages

Unit 4

The document discusses IPv6 addressing modes and address notation. It describes the 128-bit IPv6 address format which includes a site prefix, subnet ID, and interface ID. It explains rules for representing IPv6 addresses through zero suppression and leading zero compression to simplify very long strings of zeros. The key rule is that zero compression can only be used once in an IPv6 address.

Uploaded by

Nipurn Bhaal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 95

18CSC302J – Computer Networks

Unit IV

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 1


Topics
 IPV6 Overview, IPV6 Features
 IPV6 Addressing Modes Course Outcome:
 IPV6 Address Types  At the end of this unit/module,
 Address Space Allocation learners will be able to analyse
 Global Unicast Addresses and compare the IPv4 and IPv6
 Auto configuration, Renumbering protocols.
 IPV6 Introduction, IPV6 Routing Protocols
 IPV6 Packet Format
 Comparison between IPV4 and IPV6 Header
 IPV4 to IPV6 Tunneling
 IPV4 to IPV6 Translation Techniques
 NAT Protocol Translation
 IPV6 Mobility
 Protocols Changed to Support IPV6 – Computer Networks (2022-2023 ODD)
Unit IV – 18CSC302J 2
IPv6 Overview
• IPv4 stood the test of time- a tribute to its initial design
Proven to be robust
Easily implemented
Interoperable

• The initial design did not anticipate today's Internet scale and size.
Exhausting IPv4 address space
Large routing tables
Simpler management of IPv4 addresses
Security at IP level
QoS requirements

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 3


IPv6 Features
The changes introduced by IPv6 can be grouped into seven categories:
• Larger Addresses: The new address size is the most noticeable change. IPv6
quadruples the size of an IPv4 address from 32 bits to 128 bits. The IPv6 address
space is so large that it cannot be exhausted in the foreseeable future.
larger address space for extended address heirarchy
• Extended Address Hierarchy:IPv6 uses the larger address space to create additional
levels of addressing hierarchy. In particular, IPv6 can define a hierarchy of ISPs as
well as a hierarchical structure within a given site.

• Flexible Header Format: IPv6 uses an entirely new and incompatible datagram
format. Unlike the IPv4 fixed-format header, IPv6 defines a set of optional headers.

• Improved Options: Like IPv4, IPv6 allows a datagram to include optional control
information. IPv6 includes new options that provide additional facilities not available
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 4
in IPv4.
IPv6 Features
• Provision For Protocol Extension: Perhaps the most significant change in IPv6 is a
move away from a protocol that fully specifies all details to a protocol that can permit
additional features. The extension capability has the potential to allow the IETF to
adapt the protocol to changes in underlying network hardware or to new applications.

• Support For Auto configuration And Renumbering: IPv6 provides facilities that
allow computers on an isolated network to assign themselves addresses and begin
communicating without depending on a router or manual configuration. The protocol
also includes a facility that permits a manager to renumber networks dynamically.

• Support For Resource Allocation: IPv6 has two facilities that permit pre-allocation
of network resources: a flow abstraction and a differentiated service specification.
The latter will use the same approach as IPv4's differentiated services.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 5


IPv6 Addressing Modes
• 128 bits (or 16 bytes) long: four times as long as its predecessor.

• 2128 : about 340 billion billion billion billion different addresses

• Colon hexadecimal notation:


• addresses are written using 32 hexadecimal digits.
• digits are arranged into 8 groups of four to improve the readability.
• Groups are separated by colons
2001:0718:1c01:0016:020d:56ff:fe77:52a3
• Note:
• DNS plays an important role in the IPv6 world
• (manual typing of IPv6 addresses is not an easy thing,
• Some zero suppression rules are allowed to lighten this task at least a little.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 6
IPv6 Addressing Modes
What is interface explain in brief?
• IPv6 defines three address types: In computing, an interface is a shared
boundary across which two or more
• Unicast Identifies an interface of an individual node. separate components of a computer
system exchange information.

• Multicast Identifies a group of interfaces, usually on different nodes. Packets that are
sent to the multicast address go to all members of the multicast group.

• Anycast Identifies a group of interfaces, usually on different nodes. Packets that are
sent to the anycast address go to the anycast group member node that is physically
closest to the sender.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 7


Parts of the IPv6 Address

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 8


Parts of the IPv6 Address
• The leftmost three fields (48 bits) contain the site prefix. The prefix describes
the public topology that is usually allocated to your site by an ISP or Regional
Internet Registry (RIR).

• The next field is the 16-bit subnet ID, which you (or another administrator) allocate
for your site. The subnet ID describes the private topology, also known as the site
topology, because it is internal to your site.

• The rightmost four fields (64 bits) contain the interface ID, also referred to as
a token. The interface ID is either automatically configured from the interface's MAC
address or manually configured in EUI-64 format.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 9


Parts of the IPv6 Address
• 2001:0db8:3c4d:0015:0000:0000:1a2f:1a2b

• This example shows all 128 bits of an IPv6 address. The first 48
bits, 2001:0db8:3c4d, contain the site prefix, representing the public topology. The
next 16 bits, 0015, contain the subnet ID, representing the private topology for the
site. The lower order, rightmost 64 bits, 0000:0000:1a2f:1a2b, contain the interface
ID.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 10


IPv6 Address Notation: Example
128.91.45.157.220.40.0.0.0.0.252.87.212.200.31.255

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 11


Rule 1- IPv6 Zero Suppression
• Some types of addresses contain long sequences of zeros.
• To further simplify the representation of IPv6 addresses, a contiguous sequence of 16-
bit blocks set to 0 in the colon hexadecimal format can be compressed to “::”, known
as double-colon.
What are leading and trailing zeros?
Leading zeros are the zeros in front of a

• Example: number, and trailing zeros are the zeros after a


number.

• Original format: 1234:1234:0000:0000:0000:0000:3456:3434


• Using zero compression: 1234:1234::3456:3434

• Leading zeroes in any 16-bit field can be dropped, but each block you do this with must
have at least one number remaining. If the block is all zeroes, you have to leave one
zero. This is leading zero compression.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 12


Rule 1- IPv6 Zero Suppression
• For example:
• link-local address
• FE80:0:0:0:2AA:FF:FE9A:4CA2  FE80::2AA:FF:FE9A:4CA2.
• multicast address Zero Compression And Leading Zero Compression
If you have consecutive fields of zeroes, they can be expressed with two colons.

• FF02:0:0:0:0:0:0:2  FF02::2 The key rule: you can only do this zero compression once in an IPv6 address.
• loopback address Example:

• 0:0:0:0:0:0:0:1  ::1 Original format: 1234:1234:0000:0000:0000:0000:3456:3434

Using zero compression: 1234:1234::3456:3434

Leading zeroes in any 16-bit field can be dropped, but each block you do this with must have at least one
number remaining. If the block is all zeroes, you have to leave one zero. This is leading zero compression.

Example:

Original format:

1234:0000:1234:0000:1234:0000:0123:1234

With leading zero compression:

1234:0:1234:0:1234:0:123:1234

Recap..

Zero compression: Allowed only once per address.

Leading zero compression: Perform as often as you like in an address.


Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 13
Rule 1- IPv6 Zero Suppression
• Zero compression can only be used to compress a single contiguous series of 16-bit blocks expressed in
colon hexadecimal notation.
• You cannot use zero compression to include part of a 16-bit block.
• Example:
Original format:
1234:0000:1234:0000:1234:0000:0123:1234
With leading zero compression:
1234:0:1234:0:1234:0:123:1234
Recap..
Zero compression: Allowed only once per address.
Leading zero compression: Perform as often as you like in an address.
• For example,
cannot express FF02:30:0:0:0:0:0:5 as FF02:3::5
correct representation = FF02:30::5
Leading zeroes in every group can be omitted.
2001:718:1c01:16:20d:56ff:fe77:52a3
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 14
Rule 1- IPv6 Zero Suppression
• To determine the number of 0 bits represented by the “::”
1. count the number of blocks in the compressed address
2. (-) subtract this number from 8
3. (*) multiply the result by 16.

• For example
1. FF02::2
2. two blocks - “FF02” block and “2” block.
3. The number of bits expressed by the “::” is 96 (96 = (8 – 2)16).

• Zero compression can only be used once in a given address.


• Otherwise, you could not determine the number of 0 bits represented by each
instance of “::”.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 15


Example 1
Show the unabbreviated colon hex notation for the following IPv6 addresses:

a. An address with 64 0s followed by 64 1s.


b. An address with 128 0s.
c. An address with 128 1s.
d. An address with 128 alternative 1s and 0s.

Solution
a. 0000:0000:0000:0000:FFFF:FFFF:FFFF:FFFF
b. 0000:0000:0000:0000:0000:0000:0000:0000
c. FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF
d. AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 16


Example 2

The following shows the zero contraction version of addresses in Example 1 (part c and
d cannot be abbreviated)

a. :: FFFF:FFFF:FFFF:FFFF
b. ::
c. FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF
d. AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 17


Example 3
Show abbreviations for the following addresses:
a. 0000:0000:FFFF:0000:0000:0000:0000:0000
b. 1234:2346:0000:0000:0000:0000:0000:1111
c. 0000:0001:0000:0000:0000:0000:1200:1000
d. 0000:0000:0000:0000:0000:FFFF:24.123.12.6
Solution
a. 0:0:FFFF::
b. 1234:2346::1111
c. 0:1::1200:1000
d. ::FFFF:24.123.12.6

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 18


Example 4
Decompress the following addresses and show the complete unabbreviated IPv6 address:

a. 1111::2222
b. ::
c. 0:1::
d. AAAA:A:AA::1234

Solution
a. 1111:0000:0000:0000:0000:0000:0000:2222
b. 0000:0000:0000:0000:0000:0000:0000:0000
c. 0000:0001:0000:0000:0000:0000:0000:0000
d. AAAA:000A:00AA:0000:0000:0000:0000:1234

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 19


IPv6 Prefixes
• The prefix is the part of the address that indicates the bits that have fixed values or are
the bits of the subnet prefix.

• Prefixes for IPv6 subnets, routes, and address ranges are expressed in the same way as
Classless Inter-Domain Routing (CIDR) notation for IPv4.

• An IPv6 prefix is written in address/prefix-length notation.


• For example, 21DA:D3::/48 and 21DA:D3:0:2F3B::/64 are IPv6 address prefixes.

• Note IPv4 implementations commonly use a dotted decimal representation of the


network prefix known as the subnet mask. A subnet mask is not used for IPv6. Only the
prefix length notation is supported.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 20


IPv6 Prefixes

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 21


IPv6 Address Types or Addressing Modes

Three major categories of IPv6 addresses: Physical media refers to the physical materials that are
used to store or transmit information in data
• Unicast—For a single interface. communications

• Multicast—For a set of interfaces on the same physical medium. A packet is sent to all
interfaces associated with the address.

• Anycast—For a set of interfaces on different physical media. A packet is sent to only one
of the interfaces associated with this address, not to all the interfaces.

• IPv6 has no broadcast addresses: multicast addresses took over.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 22


IPv6 Address Types

One – one One – Many One – Any

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 23


IPv6 Address Types

address
groups of Private carry an IPv4
resolution global
devices used addressing address in the
to reach the routing
by Operating within a low-order 32
neighboring table(ISP)
System and campus bits of the
nodes
same interface address
attached to the
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 24
same link
Unicast Addresses
• A unicast address identifies a single interface. A network interface is the point of interconnection between
a computer and a private or public network
A unicast address is used to refer to a single host. It is meant to send data to a single destination.

• When a network device sends a packet to a unicast address, the packet goes only to the
specific interface identified by that address.

• Unicast addresses support a global address scope and two types of local address
scopes.

• A unicast address consists of n bits for the prefix, and 128 – n bits for the interface ID.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 25


Unicast Addresses

In the IPv6 implementation for a subscriber access network, the following types of
unicast addresses can be used:
• Global unicast address - A unique IPv6 address assigned to a host interface. These
addresses have a global scope and essentially the same purposes as IPv4 public
addresses. Global unicast addresses are routable on the Internet.

• Link-local IPv6 address - An IPv6 address that allows communication between


neighboring hosts that reside on the same link. Link-local addresses have a local scope,
and cannot be used outside the link. They always have the prefix FE80::/10.

• Loopback IPv6 address - An IPv6 address used on a loopback interfaces. The IPv6
loopback address is 0:0:0:0:0:0:0:1, which can be notated as ::1/128.

• Unspecified address -An IPv6 unspecified address is 0:0:0:0:0:0:0:0, which can be


notated as ::/128. Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 26
Multicast Addresses A multicast address can be used to deliver a package to a group of destinations.
Any packet sent to a multicast address, will be delivered to every host that has
joined that particular group

• A multicast address identifies a set of interfaces that typically belong to different nodes.

• When a network device sends a packet to a multicast address, the device broadcasts the
packet to all interfaces identified by that address.

• IPv6 does not support broadcast addresses, but instead uses multicast addresses in this
role.

• Multicast addresses support 16 different types of address scope, including node, link,
site, organization, and global scope.

• A 4-bit field in the prefix identifies the address scope.


Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 27
Multicast Addresses
The following types of multicast addresses can be used in an IPv6 subscriber access
network:
• Solicited-node multicast address - Neighbor Solicitation (NS) messages are sent to this
address.
• All-nodes multicast address - Router Advertisement (RA) messages are sent to this
address.
• All-nodes multicast address - Router Advertisement (RA) messages are sent to this
address.
• All-routers multicast address - Router Solicitation (RS) messages are sent to this
address.
• Multicast addresses use the prefix FF00::/8.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 28


Anycast Addresses The anycast address is very similar to the multicast
address, but packets will be delivered to only one
random host, instead of the entire group.

• An anycast address identifies a set of interfaces that typically belong to different nodes.

• Anycast addresses are similar to multicast addresses, except that packets are sent only to one
interface, not to all interfaces.

• The routing protocol used in the network usually determines which interface is physically closest
within the set of anycast addresses and routes the packet along the shortest path to its destination.

• There is no difference between anycast addresses and unicast addresses except for the subnet-router
address.

• For an anycast subnet-router address, the low-order bits, typically 64 or more, are zero.

• Anycast addresses are taken from the unicast address space.


Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 29
IPv6 Notation

Address type Binary prefix IPv6 notation

Unspecified 00 . . . 0 (128 bits) ::/128

Loopback 00 . . . 1 (128 bits) ::1/128

Multicast 11111111 FF00::/8

Link-local unicast 1111111010 FE80::/10

Site-local unicast 1111111011 FEC0::/10

Global unicast (everything else)

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 30


Address space allocation

• The first section contains six variable-size blocks


• Five sections are unassigned addresses
• Some are reserved for special purposes
• More than five-eighths of the address space is still
unassigned

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 31


Address space allocation

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 32


Example

• Figure Address space allocation shows that only a portion of the address space can be
used for global unicast communication. How many addresses are in this block?

Solution
• This block occupies only one-eighth of the address spaces. To find the number of
addresses, we can divide the total address space by 8 or 23 . The result is (2128)/(23) =
2125 —a huge block.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 33


Algorithm for finding the allocated blocks

Linked 10 0 1 111111 0 0 000000 IPv4


local compatible
1 0 1

Multicast Unique local Global


unicast Unicast

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 34


Global Unicast Addresses
Global unicast address - A unique IPv6 address assigned to a host interface. These
addresses have a global scope and essentially the same purposes as IPv4 public
addresses. Global unicast addresses are routable on the Internet.
• Primary used to address the System for one-one Communication mechanism i.e host to host
direct communication over the internet.

• Global unicast address is equivalent to public IPV4 address

• Global unicast address objective is to reach any host globally across the internet uniquely

• Address block refer this is called global unicast address block

• CIDR Notation for the block is 2000::/3, where 3 refers to that 3 leftmost bit is common for all
address in this block (001)

• The size of the address space is 2125 which is more than for expansion of internet in many
years
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 35
Global Unicast Addresses

Three Levels of Hierarchy


n bits 128-n-m bits m bits

Global routing prefix Subnet Identifier Interface Identifier

Global Unicast Address

Block Assignment Length of block


Global routing prefix (n) 48 bits
Subnet Identifier (128-n-m) 16 bits
Interface Identifier 64 bits

Recommended length for each block in Global unicast address


Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 36
Three levels of Hierarchy

Global Routing Prefix :

• The first 48 bits of a global unicast address are called global routing prefix.

• They are used to route the packet through the Internet to the organization site such
as ISP that owns the block.

• The first three bits in this part is fixed (001), Remaining 45 bits can defined up to
245 sites
• The global routers in the Internet route a packet to its destination site based on the
value of n.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 37


Three levels of Hierarchy

Subnet Identifier :

• 16 bit block is used to identify the specific subnet of an organization.

• An organization can have upto 216 subnets.

Interface Identifier :

• Last 64 bits refers to the interface identifier. It is similar to the hostId in IPV4 scheme.

• In IPV4 addressing, there is no relation between the hostid (32 bits) and MAC(48 bits) due to the
difference in length.

• Physical address whose length is less than 64 bits can be embedded as the whole or part of the
interface identifier, eliminating the mapping process with the help of IPv6.

• Two common physical addressing scheme can be considered for this purpose: the 64-bit extended
unique identifier (EUI-64) defined
Unit IV – by IEEE
18CSC302J and the
– Computer 48-bit
Networks ODD) address defined by Ethernet.
physical
(2022-2023 38
Mapping EUI-64

To map a 64-bit physical address, the global/local bit of this format needs to be changed
from 0 to 1 (local to global) to define an interface address

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 39


Mapping Ethernet MAC Address
To map 48-bit Ethernet address into a 64-bit interface identifier, we need to change the
local/global bit to 1 and insert an additional 16 bits. The additional 16 bits are defined as
15 ones followed by one zero, or FFFE16. 11111111111111
0

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 40


Example of mapping address from one format to other
1. Find the interface identifier if the physical address in the EUI is (F5-A9-23-EF-07-14-7A-D2)
16 using the format we defined for Ethernet addresses.

Soln : To map the EUI to interface identifier we need to invert the seventh bit of first octet. The
first octet value
F5 -> (11110101)
F7 -> (11110111)
Interface identifier is F7-A9-23-EF-07-14-7A-D2

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 41


Example of mapping address from one format to other
2. Find the interface identifier if the Ethernet physical address is (F5-A9-23-14-7A-D2)16 using
the format we defined for Ethernet addresses.

Soln : To map the Ethernet address to interface identifier, we need to invert the seventh bit of first
octet and FFFE has to be inserted after the 3 octet.
F5-A9-23-14-7A-D2 (11110101)
F7-A9-23-FF-FE-14-7A-D2 (11110111)

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 42


IPV6 Auto configuration
Auto configuration helps the nodes in an IPv6 network to automatically get configured without
any human intervention.
Type of Auto-Configuration
a) Stateful Auto-configuration.
• It requires a certain level of human intervention because it needs a Dynamic Host
Configuration Protocol for IPv6 (DHCPv6) server for the installation and administration of
the nodes.

• The DHCPv6 server keeps a list of nodes to which it supplies configuration information.

• It also maintains state information so the server knows how long each address is in use, and
when it might be available for reassignment.
IPV6 Auto configuration
b) Stateless Auto-configuration.
• This is suitable for small organizations and individuals.

• Each host determines its addresses from the contents of received router advertisements.

• Using the IEEE EUI-64 standard to define the network ID portion of the address, it is
reasonable to assume the uniqueness of the host address on the link.
Dynamic Addressing

• Dynamic addressing starts with IPv6 Router Advertisement (RA) Messages. It


informs the network devices about how they can reach IPv6 addressing Information.

• Router Advertisement (RA) Messages are sent periodically or any time after receiving
a Solicitation Message. Routers answers in four ways for this RA messages:
1) SLAAC (Stateless) - Use only router advertisements
2) SLAAC + DHCPv6 (Stateless) - Use router advertisements and DHCPv Server
3) DHCPv6 (Statefull) - Use DHCP server Only
4) DHCPv6 (Statefull + Stateless) - Use DHCP server Only but we can use stateless also

The ICMP Router Solicitation message is sent from a computer host to any routers on the local area network to request that they advertise their
presence on the network.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 45


Dynamic Addressing
There are three important flags in a Router Advertisement
Message, to use DHCPv6 or not. These flags are:

• Other Configuration Flag (O Flag)

• Managed Configuration Flag (M Flag)

• Auto Configuration Flag (A Flag)

• “O” flag indicates that, Stateless Auto Configuration will be


done or not.

• “M” flag indicates that Auto IP Configuration will be done


with DHCP version 6 or Not.

• If A flag is 1, Auto stateless configuration is done. if 0 then


statefull DHCP is used.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 46


Auto Configuration
• Auto configuration enables the host to assign the IPV6 address on its own.

• In IPV4 usually the network manager will assign the address (static) for each host in the
network in-case if the network uses DHCP (dynamic host configuration protocol) the host
will be assign a dynamic address when the host join the network and it keeps changing
every time it joins the network.

• Auto Configuration process:

1. Host create a link local address by taking 10 bit local prefix (1111 1110 10) and add
54 zeros and adding 64 bits interface identifier of its own from the interface card
which makes as 128 bit link local address.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 47
Auto Configuration
2. The host verifies the uniqueness of the link local address by sending the neighbour
solicitation message and waits for the neighbour advertisement message. Incase if
any of the host address matches then auto configuration process results in failure
which can be counter by either DHCP or manual configuration

3. If the uniqueness test for link local address is successful, then the host send router
solicitation message to the local router. If the local router running in the network
sends a router advertisement message from which thee host extract the global unicast
prefix and the subnet prefix and append the same with local link to complete the
address. Incase if the router cant help for auto configuration it inform the host by
setting the flag in the advertisement message.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 48
Computing the global unicast address

1. Assume a host with Ethernet address (F5-A9-23-11-9B-E2)16 has joined the network.
What would be its global unicast address if the global unicast prefix of the organization
is 3A21:1216:2165 and the subnet identifier is A245:1232.
Soln:
Step 1 : Creating a local link address by adding 10 bit prefix (1111 1110 10) and 54 zeros and append its 64 bit interface
ID extracted from the Ethernet address :
FE80 : :F7A9-23FF-FE11-9BE2 (by inverting the seventh bit of 1st octet and adding FFFE after the third octet)
Step 2 : On assuming this uniqueness it send the router solicitation message upon receiving the advertisement message it
complete the auto configuration process by extracting the global unicast prefix and subnet identifier from the message as
follows 3A21:1216:2165:A245:1232 and append it to the local link address

3A21:1216:2165:A245:1232: F7A9-23FF-FE11-9BE2
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 49
Renumbering
• Renumbering allow the site to change the service provider and reconfigure the IPV6 address.

• If the site changes the service provider the address prefix needs to be changed.

• Once the service provider changes the router advertises the new prefix and the site uses the old
prefix before its disabling.

• The main hindrance in renumbering is support of the DNS, which needs to propagate the new
addressing associated with a domain name. Anew protocol called Next generation DNS in
exploration.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 50


• IPV6 Routing Protocols - Introduction
• IPV6 Routing Protocols
• IPV6 Packet Format
• Comparison between IPV4 and IPV6 Header
Introduction
The evolution of IPV6 was due to two major factors:

1. Address depletion

2. slowness of the process due to some unnecessary processing, and support for multimedia and security.

IPV6 responds to the above issue by the following modifications

• Larger address space. Instead of 32bit addressing scheme it uses 128 bit addressing format.

• Better header format. Options are flexible i.e., removed from base header and inserted when needed which speed up the routing
process.

• New options. IPv6 has new options to allow for additional functionalities.
• Allowance for extension. IPv6 is designed to allow the extension of the protocol if required by new technologies or applications.

• Support for resource allocation. In place of type-of-service field two new fields, traffic class and flow label have been added to
enable the source to request special handling of the packet which enable the support for multimedia transmission

• Support for more security. The encryption and authentication options in IPv6 provide confidentiality and integrity of the packet.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 52
IPV6 Routing Protocols
 Same Protocols as in IPv4
 Static
 RIPng (Routing Information Protocol Next Generation)
 OSPFv3 ( Open Shortest Path First version 3 )
 MP-BGP4 (Modified Protocol Border Gateway Protocol)

 Use ping6 and traceroute6 commands to check reachability and route

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 53


IPV6 Routing Protocols

• Aggregation of prefixes announced in the global routing table


• Efficient and scalable routing

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 54


IPV6 Routing Protocols
Neighbor Discovery Protocol
• IPv6 nodes which share the same physical medium (link) use Neighbor Discovery
Protocol (NDP) to:

 Discover their mutual presence


 Determine link-layer addresses of their neighbors
(equivalent to ARP)
 Find routers
 Maintain neighbors’ reachability information

• Uses Multicast Address

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 55


IPV6 Routing Protocols

Neighbor Discovery Protocol features


 Router discovery
 Prefix(es) discovery
 Parameters discovery (link MTU, Max Hop Limit, ...)
 Address auto-configuration
 Address resolution
 Next Hop determination
 Neighbor Unreachability Detection
 Duplicate Address Detection
 Redirect
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 56
IPV6 Routing Protocols
• Neighbor Discovery Protocol provides the functionality of

 ARP

 ICMP redirect

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 57


IPV6 Routing Protocols
 ND specifies 5 types of ICMP packets:

 Router Advertisement (RA) :


 Periodic advertisement (of the availability of a router) which contains:
 list of prefixes used on the link (autoconf)
 a possible value for Max Hop Limit (TTL of IPv4)
 value of MTU

 Router Solicitation (RS) :


 The host needs RA immediately (at boot time)

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 58


IPV6 Routing Protocols

 Neighbor Solicitation (NS):


 to determine the link-layer address of a neighbor
 to check its reachability
 used to detect duplicate addresses (DAD)

 Neighbor Advertisement (NA):


 answer to a NS packet
 to advertise the change of physical address

 Redirect:
 Used by a router to inform a host of a better route to a given destination

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 59


IPV6 Packet format
40 bytes Upto 65 535 bytes

Base Header Payload

Extension Headers (Optional) Data Packet from upper layers

32 bits = 4 bytes • Version : To specify whether IPV4 or IPV6


• Traffic Class : Distinguish the payload.
0 4 12 24 • Flow label : Mention special handling for a
16 31
particular flow of data.
VER Traffic Class Flow Label • Payload length : Defines the length of the IP
datagram in payload.
Payload length Next Header Hop limit • Next Header : Optional extension headers used
Source Address by IP or the header of an encapsulated packet
such as UDP or TCP.
(128 bits = 16 bytes)
• Hop Limit : TTL
Destination Address • Source Address: Original source address
(128 bits = 16 bytes) • Destination Address: Final destination of
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD)
datagram 60
Format of Base Header
Next Header codes
Code Next Header
0 Hop-by-Hop option
2 ICMP
6 TCP
17 UDP
43 Source routing
44 Fragmentation
50 Encrypted Security Payload
51 Authentication
59 NULL (no next header)
60 Destination Option
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 61
Flow Label
• IP protocol designed to serve as connectionless protocol, but it has the ability to serve as connection
oriented protocol.

• Router consider the flow as a sequence of packet share the same characteristics such as path, resources,
and security.

• Router support the handling of flow label table which has entry for each active flow. When a router
receives a packet it check the flow label table for the entry and provides the service mentioned. The
information is provided by other means such as the hop-by-hop options or other protocols.

• Flow label objective is to speed up the processing of packet i.e. while receiving a packet instead checking
the routing table it consults the flow label table to find the next hop.

• A flow label used to support the transmission of real-time audio and video. Real-time audio or video,
particularly in digital form
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 62
Flow Label
Rules for flow label:

• Flow label is defined by source host which takes a random number form 1 to 224 -1 and it must
be unique one.

• If host doesn’t support the feature its set to zero and if router doesn’t support it simply ignore
the field.

• All the packets belong to the same flow has same source, same destination, same priority and
same option

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 63


Extension Header

VER Traffic Class Flow Label

Payload length Next Header Hop limit


Base Header
Source Address(128 bits = 16 bytes)

Destination Address (128 bits = 16 bytes)

Next Header Header length

Next Header Header length

.
. Extension Header
.

Next Header Header length


Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 64
Format of Base Header
Extension Header
Extension Header

Source
Hop-by-Hop Destination Fragmentation Authentication ESP
Routing

• Hop-by-Hop is used when source needs to send information to all routers along the path. Used to specify information
such as management, debugging and control function also used too specify when datagram size exceeds 65535 bits.

• The first field defines the header and next fields defines the length and rest of the field makes options. Only 3 options
have been defined are Pad1, PadN, and jumbo Payload.

Next Header Header length


Options
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 65
Options in Hop-by-Hop header
8 bits 8 bits

code Length Data (variable length)

Action (2 bits) C (1 bit) Type (5 bits)


C Change in option Value
• 0 Doesn’t change in transit
Action (if option not required) • 1 maybe changed in transit
• 00 Skip this option
• 01 Discard datagram, no more action Type
• 10 Discard datagram and send ICMP message • 00000 Pad1
• 11 Discard datagram and send ICMP message if • 00001 PadN
not Multicast • 00010 Jumbo Payload

Type
• Pad1 – used for alignment purpose. Options need to start at specific bit of 32 bit word, if it fall short by 1 bit Pad1 is used. Pad1
excludes the length of option and data field. Pad1 can be inserted anywhere in hop-by-hop

Options
Code pad1
00000
Rest of– 18CSC302J
Unit IV the payload
– Computer Networks (2022-2023 ODD)
b. Used for padding
66
a. Pad1
Options in Hop-by-Hop header
code length Data

00000001 C (1 bit) All 0’s Pad N

1 byte 1 byte variable


Type
• PadN – PadN is used when 2 or more bytes are needed for alignment. PadN is made of 1 byte of option code, 1 byte of the option
length, and a variable number of zero padding bytes. The value of the option code is 1 (action is 00, the change bit is 0, and type is
00001). The option length contains the number of padding bytes

Code Code
Jumbo Payload
11000010 00000100
Length of Jumbo payload ( 4 bytes)
Type
• Jumbo payload. Payload in the IP datagram can be a maximum of 65,535 bytes in length, if for any reason payload length is larger
than prefer jumbo payload option to define this longer length. The jumbo payload option must always start at a multiple of 4 bytes
plus 2 from the beginning of the extension headers. The jumbo payload option starts at the (4n + 2) byte, where n is a small integer.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 67


Extension Headers
Destination: Destination is used when the source needs to send information only to the destination and prevents the information get
accessed by the router along the path. The format of the destination field is same as hop-by-hop option.

Source Routing: Combines the concept of strict and loose routing and minimum of 7 fields length.

Next Header Header Length Code Address left • Next Header and Header length are same as in Hop-by-Hop
Reserved Strict/loose mask • Type field defines strict or loose routing.
• Address left represents the host need to reach the destination.
First Address
• strict/loose mask field determines the rigidity of routing.
Second Address
• If set to strict, routing must follow the source specification
:
• If set to loose, it may visit other routers
:

Last address

Note : Destination address in source routing does not refer to the final destination of the datagram instead, it changes from router to router.
The addresses in the extension headers also changeUnit
fromIV – router to –router.
18CSC302J Computer Networks (2022-2023 ODD) 68
Source Routing Example
If source A wants to send a packet to destination B then, the routing info

Source : A Source : A Source : A Source : A


Destination : R1 Destination : R2 Destination : R3 Destination : R3
Left : 3 Left : 2 Left : 1 Left : 0
R2 R1 R1 R1
R3 R3 R2 R2
B B B R3

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 69


Extension Header – Fragmentation & Authentication
Fragmentation
• Refers to the process of breaking the segment into smaller fragment
• IPV4 either the source (host) or the router performs the fragmentation process based on the MTU (Maximum Transmission Unit)

Next Header Header Length Fragment offset 0 M


Fragmentation
Fragment Identification

• In IPV6 only the source performs the fragmentation by using Path MTU discovery technique in-order to find the smallest MTU on the
path. If the source doesn’t use MTU discovery, it fragment the packet into size of 1280 bytes or smaller
Authentication:

Security parameter index


Authentication
Authentication Data

• Validates the sender and ensure integrity of data. Validation of sender to insure the message comes for genuine source not from intruder
The integrity is verify the original transmitted message reaches the receiver end.
• Security parameter index defines the algorithm used for authentication and the data field contain the actual data generated by the
algorithm. Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 70
Authentication of data
128-bit security key

IP datagram with changeable 128 bit Authentication


Authentication
and authentication fields set to data
Algorithm
zero

128-bit security key


Authentication Process

 The sender passes a 128-bit security key, the entire IP datagram, and the 128-bit security key again to the algorithm.

 Those fields in the datagram with values that change during transmission (for example, hop count) are set to zero.

 The datagram passed to the algorithm includes the authentication header extension, with the authentication data field set to zero.

 The algorithm creates authentication data which is inserted into the extension header prior to datagram transmission.

 The receiver on receiving the message passes the datagram and the secret to the algorithm and compare the result, if it matches
the datagram is accepted else discarded.Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 71
Extension Header – ESP
Encrypted Security Payload (ESP)

Security parameter index


ESP
Encrypted Data

• To provide confidentiality and prevent eavesdropping.


• The security parameter index defines the type of encryption algorithm used and data field carries
the encrypted data and other information if any needed for the algorithm
• Encryption can be done either by transport model or tunnel model

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 72


Comparison between IPV4 and IPV6 Header

IPV4 IPV6
Header length Field Header length field is eliminated
Service type field Traffic class and flow label
Total length field Payload length field
Identification , flag, offset Fragmentation extension header
TTL Hop-limit
Protocol Next Header
Header Checksum No Checksum
Option fields Extension Headers
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 73
Transition from IPV4 to IPV6
Three strategies used are:
• Dual stack
• Tunnelling
• Header translation
Dual Stack: Before complete migration all station must run in dual mode i.e. Both IPV4 and IPV6

Transport and Application layers

IPV4 IPV6

Underlying LAN or WAN Technology

To IPV4 To IPV6

Before sending a packet to the destination the source queries the DNS, if it returns IPV4 then source sends IPV4
packet else send IPV6 packet. Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 74
Transition from IPV4 to IPV6 : Tunnelling
Tunnelling : Process happens when two IPV6 host wants to communicate through a IPV4
Channel, to pass through this channel it requires a IPV4 address. So IPV6 packet is encapsulated
in a IPV4 packet and enter the region.
IPV4 Header IPV6 Host
IPV6 Host
IPV6 Header
Payload

IPV6 Header Tunnelling IPV6 Header


Payload Payload

IPV4 Region

IPv4 packet is carrying an IPv6 packet as data, the protocol value is set to 41

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 75


Transition from IPV4 to IPV6 : Header translation
Header Translation acquires when sender uses a IPV6 and receiver uses IPV4, where the IPV6 address needs to be translated to IPV4.

Header translation
done here
IPV6 Host IPV4 Host

IPV6 Header IPV4 Header


Payload Payload

IPV4 Region
IPV6 Region

Header translation uses the mapped address to translate an IPv6 address to an IPv4 address. Rules for Translation:
The IPv6 mapped address is changed to an IPv4 address by extracting the right-most 32 bits.
The value of the IPv6 priority field is discarded. The type of service field in IPv4 is set to zero.
The checksum for IPv4 is calculated and inserted in the corresponding field. The IPv6 flow label is ignored.
Compatible extension headers are converted to options and inserted in the IPv4 header. Some may have to be dropped.
The length of IPv4 header is calculated and inserted into the corresponding field.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 76
The total length of the IPv4 packet is calculated and inserted in the corresponding field.
NAT Protocol
Network Address Translation
• To access the Internet one public IP address is needed but we can use a private IP
address in our private network.

• The idea of NAT is to allow multiple devices to access the Internet through a single
public address.

• To achieve this the translation of private IP address to a public IP address is required.


Network Address Translation (NAT) is a process in which one or more local IP address
is translated into one or more Global IP address and vice versa in order to provide
Internet access to the local hosts.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 78


Network Address Translation
• A technology that can provide the mapping between the private and universal
addresses, and at the same time, support virtual private networks, is network address
translation (NAT).

• The technology allows a site to use a set of private addresses for internal
communication and a set of global Internet addresses (at least one) for communication
with the rest of the world.

• The site must have only one single connection to the global Internet through a NAT-
capable router that runs NAT software.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 79


What is NAT?

• Above figure shows a simple implementation of NAT.


• The private network uses private addresses. The router that connects the network to
the global address uses one private address and one global address.
• The private network is transparent to the rest of the Internet; the rest of the Internet
sees only the NAT router with the address 200.24.5.8.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 80
Working of NAT
• Generally, the border router is configured
for NAT i.e the router which has one
interface in local (inside) network and
one interface in the global (outside)
network.

• When a packet traverse outside the local


(inside) network, then NAT converts that
local (private) IP address to a global
(public) IP address.

• When a packet enters the local network, the global (public) IP address is converted to a local
(private) IP address.
• If NAT run out of addresses, i.e., no address is left in the pool configured then the packets will
be dropped and an Internet Control Message Protocol (ICMP) host unreachable packet to the
destination is sent.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 81
Types of NAT
There are 3 ways to Configure NAT :

• Static NAT – In this, a single unregistered (Private) IP address is mapped with a legally
registered (Public) IP address i.e one-to-one mapping between local and global address.

• Dynamic NAT – In this type of NAT, an unregistered IP address is translated into a registered
(Public) IP address from a pool of public IP address.

• Port Address Translation (PAT) – This is also known as NAT overload. In this, many local
(private) IP addresses can be translated to a single registered IP address. Port numbers are used
to distinguish the traffic i.e., which traffic belongs to which IP address.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 82
Advantages of NAT

• NAT conserves legally registered IP addresses.


• It provides privacy as the device IP address, sending and receiving the traffic, will be
hidden.
• Eliminates address renumbering when a network evolves.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 83


Disadvantages of NAT

• Translation results in switching path delays.

• Certain applications will not function while NAT is enabled.

• Complicates tunneling protocols such as IPsec.

• Also, router being a network layer device, should not tamper with port
numbers(transport layer) but it has to do so because of NAT.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 84


IPv6 Mobility
IPv6 Mobility
• When a host is connected to a link or network, it acquires an IP address and all
communication take place using that IP address on that link.

• As soon as, the same host changes its physical location, that is, moves into another
area / subnet / network / link, its IP address changes accordingly, and all the
communication taking place on the host using old IP address, goes down.

• IPv6 mobility provides a mechanism for the host to roam around different links
without losing any communication/connection and its IP address.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 86


Modules associated
• Mobile Node: The device that needs IPv6 mobility.

• Home Link: This link is configured with the home subnet prefix and this is where the Mobile
IPv6 device gets its Home Address.

• Home Address: This is the address which the Mobile Node acquires from the Home Link.
This is the permanent address of the Mobile Node.

• If the Mobile Node remains in the same Home Link, the communication among various
entities take place as usual.

• Home Agent: This is a router that acts as a registrar for Mobile Nodes. Home Agent is
connected to Home Link and maintains information about all Mobile Nodes, their Home
Addresses, and their present IP addresses.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 87


Modules associated

• Foreign Link: Any other Link that is not Mobile Node’s Home Link.

• Care-of Address: When a Mobile Node gets attached to a Foreign Link, it acquires a
new IP address of that Foreign Link’s subnet.

• Correspondent Node: Any IPv6 enabled device that intends to have communication
with Mobile Node.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 88


Diagrammatic Representation

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 89


IPv6 Mobility Operations
• When a Mobile Node leaves its Home Link and is connected to some Foreign Link, the
Mobility feature of IPv6 comes into play.

• After getting connected to a Foreign Link, the Mobile Node acquires an IPv6 address from
the Foreign Link. This address is called Care-of Address.

• The Mobile Node sends a binding request to its Home Agent with the new Care-of Address.

• The Home Agent binds the Mobile Node’s Home Address with the Care-of Address,
establishing a Tunnel between both.

• Whenever a Correspondent Node tries to establish connection with the Mobile Node (on its
Home Address), the Home Agent intercepts the packet and forwards to Mobile Node’s Care-
of Address over the Tunnel which was already established.
Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 90
Route Optimization

• When a Correspondent Node initiates a communication by sending packets to Mobile the


Node on the Home Address, these packets are tunneled to the Mobile Node by the Home
Agent.

• In Route Optimization mode, when the Mobile Node receives a packet from the
Correspondent Node, it does not forward replies to the Home Agent.

• Rather, it sends its packet directly to the Correspondent Node using Home Address as Source
Address.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 91


Protocols Changed to Support IPv6
ICMPv6

• Internet Control Message Protocol version 6 is an upgraded implementation of ICMP


to accommodate IPv6 requirements.

• This protocol is used for diagnostic functions, error and information message,
statistical purposes.

• ICMPv6’s Neighbor Discovery Protocol replaces ARP and helps discover neighbor
and routers on the link.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 93


DHCPv6
• Dynamic Host Configuration Protocol version 6 is an implementation of DHCP.

• Though IPv6 enabled hosts do not require any DHCPv6 Server to acquire IP address
as they can be auto-configured.

• Neither do they need DHCPv6 to locate DNS server because DNS can be discovered
and configured via ICMPv6 Neighbor Discovery Protocol.

• Yet DHCPv6 Server can be used to provide these information.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 94


DNS

• There has been no new version of DNS but it is now equipped with extensions to
provide support for querying IPv6 addresses.

• A new AAAA (quad-A) record has been added to reply IPv6 query messages.

• Now DNS can reply with both IP versions (4 & 6) without any change in query
format.

Unit IV – 18CSC302J – Computer Networks (2022-2023 ODD) 95

You might also like