86
Next Generation IP Protocol: IPv6 NETE0514 Presented by Dr.Apichan Kanjanavapastit

Next Generation IP Protocol: IPv6

  • Upload
    nancy

  • View
    90

  • Download
    0

Embed Size (px)

DESCRIPTION

Next Generation IP Protocol: IPv6. NETE0514 Presented by Dr.Apichan Kanjanavapastit. Why IPv6?. IPv4 has some deficiencies that make it unsuitable for the fast-growing Internet, including the following: - PowerPoint PPT Presentation

Citation preview

Page 1: Next Generation IP Protocol: IPv6

Next Generation IP Protocol:IPv6

NETE0514

Presented by

Dr.Apichan Kanjanavapastit

Page 2: Next Generation IP Protocol: IPv6

Why IPv6?

• IPv4 has some deficiencies that make it unsuitable for the fast-growing Internet, including the following:– Fast-spreading use of the Internet, and new services,

such as Mobile IP and IP telephony lead to the depletion of the IP addresses

– The Internet must accommodate real-time audio and video transmission

– The Internet must accommodate encryption and authentication of data for some applications

Page 3: Next Generation IP Protocol: IPv6

What IPv6?

• To overcome the deficiencies of IPv4, IPv6 (Internetworking Protocol, version 6), also known as IPng (Internetworking Protocol, next generation) was proposed

• In IPv6, the Internet protocol was extensively modified to accommodate the unforeseen growth of the Internet

• The format and the length of the IP addresses were changed along with the packet format

• Related protocols, such as ICMP, were also modified

Page 4: Next Generation IP Protocol: IPv6

What IPv6? (cont.)

• Other protocols in the network layer, such as ARP, RARP and IGMP, were either deleted or included in the ICMPv6 protocol

• Routing protocols, such as RIP and OSPF, were also slightly modified to accommodate these changes

Page 5: Next Generation IP Protocol: IPv6

Reason for Delay in Adoption of IPv6

• The adoption of IPv6 has been slow• The reason is that the depletion of IPv4

addresses has been slowed down because of 3 short-term remedies– Classless addressing– Use of DHCP for dynamic address allocation– NAT

• However, the fast-spreading use of the Internet, and new services, may require the total replacement of IPv4 with IPv6 in the future

Page 6: Next Generation IP Protocol: IPv6

Advantages of IPv6 over IPv4• Larger address space. An IPv6 address is 128 bits long.

Compared with the 32-bit address of IPv4• Better header format. Options of IPv6 are separated from

the base header and inserted, when needed, between the base header and the upper-layer data. This simplifies and speeds 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. There are 2 new fields, traffic class and flow label have been added to enable the source to request special handling of the packet

• Support for more security. The encryption and authentication options provide confidentiality and integrity of the packet

Page 7: Next Generation IP Protocol: IPv6

IPv6 Addresses

• An IPv6 address consists of 16 bytes (octets); it is 128 bits long

• A computer normally stores the address in binary, but it is clear that 128 bits cannot easily be handled by humans

• Several notations have been proposed to represent IPv6 addresses when they are handled by humans

Page 8: Next Generation IP Protocol: IPv6

Dotted-Decimal Notation

• To be compatible with IPv4 addresses, one can use dotted-decimal notation as used in IPv4 addresses

• However, this notation is inconvenient for 16-byte IPv6 addresses since it is too long

• This notation is therefore rarely used except partially

221.14.65.11.105.45.170.34.12.234.18.0.14.0.115.225

Page 9: Next Generation IP Protocol: IPv6

Colon Hexadecimal Notation

• In this notation, 128 bits are divided into 8 sections, each 2 bytes in length

• Two bytes in hexadecimal notation require 4 hexadecimal digits. Therefore, the address consists of 32 hexadecimal digits, with every 4 digits separated by a colon

Page 10: Next Generation IP Protocol: IPv6

Abbreviation of IPv6 addresses

• If many of the digits are zeros, we can abbreviate the address

• The leading zeros of a section (4 digits between 2 colons) can be omitted

• Only the leading zeros can be dropped, not the trailing zeros

Page 11: Next Generation IP Protocol: IPv6

Zero Compression

• Further abbreviations, often called zero compression, are possible if there are consecutive sections consisting of zeros only

• We can remove the zeros altogether and replace them with a double semicolon

• This type of abbreviation is allowed only once per address. If there are two runs of zero sections, only one of them can be abbreviated

Page 12: Next Generation IP Protocol: IPv6

Mixed Representation

• Sometimes we see a mixed representation of an IPv6 address: colon hex and dotted-decimal notation

• This is appropriate during the transition period in which an IPv4 address is embedded in an IPv6 address (as the rightmost 32 bits)

FDEC:14AB:2311:BBFE:AAAA:BBBB:130.24.24.18

Page 13: Next Generation IP Protocol: IPv6

CIDR Notation

• Since IPv6 uses hierarchical addressing, IPv6 then allows classless addressing and CIDR notation

Page 14: Next Generation IP Protocol: IPv6

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.

Solutiona. 0000:0000:0000:0000:FFFF:FFFF:FFFF:FFFFb. 0000:0000:0000:0000:0000:0000:0000:0000c. FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFFd. AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA

ExampleExample 26.1

Page 15: Next Generation IP Protocol: IPv6

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

a. :: FFFF:FFFF:FFFF:FFFFb. ::c. FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFFd. AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA:AAAA

ExampleExample 26.2

Page 16: Next Generation IP Protocol: IPv6

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

ExampleExample 26.3

Solutiona. 0:0:FFFF::b. 1234:2346::1111c. 0:1::1200:1000d. ::FFFF:24.123.12.6

Page 17: Next Generation IP Protocol: IPv6

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

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

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

ExampleExample 26.4

Page 18: Next Generation IP Protocol: IPv6

Address Space

• The address space of IPv6 contains 2128 addresses. This address space is 296 times of the IPv4 address

Page 19: Next Generation IP Protocol: IPv6

To give some idea about the number of addresses, let us assume that the number of people on the planet earth is soon to be 234 (more than 16 billion). Each person can have 294 addresses to use.

ExampleExample 26.5

Page 20: Next Generation IP Protocol: IPv6

If we assign 260 addresses to the users each year (almost one billion each second), it takes 268 years to deplete addresses.

ExampleExample 26.6

Page 21: Next Generation IP Protocol: IPv6

Categories of Addresses

• IPv6 defines 3 types of addresses: unicast, anycast, and multicast

• A unicast address defines a single computer. The packet sent to a unicast address must be delivered to that specific computer

• An anycast address defines a group of computers that all share a single address. A packet sent to an anycast address must be delivered to exactly one of the members of the group—the closest or the most easily accessible. IPv6 does not designate a block for anycasting; the addresses are assigned from the unicast block

• A multicast address defines a group of computers. A packet sent to a multicast address must be delivered to each member of the group

Page 22: Next Generation IP Protocol: IPv6

Address Space Allocation• The address space is divided into several blocks of varying size and

each block is allocated for special purpose• To better understand the allocation and the location of each block in

address space, the whole address space is divided into 8 equal regions• Each section is 1/8 of the whole address space. The first section

contains 6 variable-size blocks. The second section is considered one single block and is used for global unicast addresses. The next 5 sections are unassigned addresses. The last section is divided into 8 blocks.

Page 23: Next Generation IP Protocol: IPv6

Prefixes for IPv6 Addresses

Page 24: Next Generation IP Protocol: IPv6

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

SolutionThis 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.

ExampleExample 26.8

Page 25: Next Generation IP Protocol: IPv6

Algorithm for finding the allocated blocks

0 0 000000

1

GlobalUnicast

IPv4compatible

0

0

Unique localunicast

11111110 1

1

Linkedlocal

Multicast

Page 26: Next Generation IP Protocol: IPv6

Unspecified Address

• This is an address in which the entire address consists of zeros

• It is used during bootstrap when a host does not know its own address and sends an inquiry to find its address

• It cannot be used as a destination address• The CIDR notation for this one-address subblock is

::/128

Page 27: Next Generation IP Protocol: IPv6

Comparing the unspecified address in IPv4 to the unspecified addresses in IPv6.

SolutionIn both architectures, an unspecified address is an all-zero address. In IPv4 this address is part of class A address; in IPv6 this address is part of the reserved block.

ExampleExample 26.9

Page 28: Next Generation IP Protocol: IPv6

Loopback Address

• This is an address used by a host to test itself without going into the network

• A message is created in the application layer, sent to the transport layer, and passed to the network layer

• It then returns to the transport layer and then passes to the application layer

• This is very useful for testing the functions of software packages in these layer before even connecting the computer to the network

Page 29: Next Generation IP Protocol: IPv6

Compare the loop addresses in IPv4 to the loopback address in IPv6.

SolutionThere are two differences in this case. In classful addressing, a whole block is allocated for loopback addresses; in IPv6 only one address is allocated as the loopback address. In addition, the loopback block in classful addressing is part of the class A block. In IPv6, it is only one single address in the reserved block.

ExampleExample 26.10

Page 30: Next Generation IP Protocol: IPv6

IPv4 Compatible Addresses

• Addresses that use the prefix (00000000) are reserved, but part of it is used to define some IPv4 compatible addresses

Page 31: Next Generation IP Protocol: IPv6

Embedded IPv4 Addresses• During transition from IPv4 to IPv6, hosts can use their IPv4

addresses embedded in IPv6 addresses• Two formats have been designed for this purpose: compatible

and mapped• A compatible address is an address of 96 bits of zeros followed

by 32 bits of IPv4 address• It is used when a computer using IPv6 wants to send a message

to another computer using IPv6• However, suppose the packet passes through a region where the

networks are still using IPv4

Page 32: Next Generation IP Protocol: IPv6

Embedded IPv4 Addresses (cont.)

• A mapped address comprises 80 bits of zero, followed by 16 bits of one, followed by the 32-bit IPv4 address

• It is used when a computer that has migrated to IPv6 wants to send a packet to a computer still using IPv4

• The packet travels mostly through IPv6 networks but is finally delivered to a host that uses IPv4

Page 33: Next Generation IP Protocol: IPv6

Embedded IPv4 Addresses (cont.)

• A very interesting point about mapped and compatible addresses is that when calculating the checksum, one can use the embedded address or the total address because extra 0s or 1s in multiple of 16 don’t have any effect in checksum calculation

Page 34: Next Generation IP Protocol: IPv6

Unique Local Unicast Block

• IPv6 uses two large blocks for private addressing: one at the site level and one at the link level

• A subblock in a unique local unicast block can be privately created and used by a site

• The packet carrying this type of address as the destination address is not expected to be routed

• This type of address has the block identifier 1111 110, the next bit can be 0 or 1 to define how the address is selected (locally or by an authority)

• The next 40 bits are selected by the site using a randomly generated of length 40 bits

Page 35: Next Generation IP Protocol: IPv6

Link Local Block

• The second block designed for private addresses is link local block

• A subblock in this block can be used as a private address in a network

• This type of address has the block identifier 1111111010. The next 54 bits are set to zero. The last 64 bits can be changed to define the interface for each computer

Page 36: Next Generation IP Protocol: IPv6

Multicast Block

• In IPv6, multicast block uses the prefix 11111111. The second field is a flag that defines the group address as either permanent or transient

• A permanent group address is defined by the Internet authorities and can be accesses at all times

• A transient group address is used only temporarily such as in a teleconference

• The third defines the scope of the group address

Values in Hex

0: Permanent1: Transient

Values in Hex

0: Reserved1: Node local2: Link local4: Admin. local

5: Site local8: Org. localE: GlobalF: Reserved

Page 37: Next Generation IP Protocol: IPv6

Global Unicast Address

• This block in the address space is used for unicast communication

• An address in this block is divided into 3 parts: global routing prefix, subnet identifier, and interface identifier

Page 38: Next Generation IP Protocol: IPv6

Global Routing Prefix

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

• They are used to route packets through the Internet to the organization site such as ISP

• Since the first 3 bits is fixed (001), the rest of the 45 bits can define up to 245 sites (a private organization or an ISP)

Page 39: Next Generation IP Protocol: IPv6

Subnet Identifier

• The next 16 bits defines a subnet in an organization

• This means that an organization can have up to 216 subnet, which is more than enough

Page 40: Next Generation IP Protocol: IPv6

Interface Identifier

• The last 64 bits define the interface identifier which is similar to hostid in IPv4 addressing

• In IPv4 addressing, there is not a specific relation between the hostid (at the IP level) and physical or MAC address (at the data link layer) because the physical address is normally much longer than the hostid

• The IPv6 addressing allows this opportunity. A physical address whole length is less than 64 bits can be embedded as the whole or part of the interface identifier, eliminating the mapping process

• Two physical addressing scheme can be considered: the 64-bit extended unique identifier (EUI-64) defined by IEEE and the 48-bit physical address defined by Ethernet

Page 41: Next Generation IP Protocol: IPv6

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

Page 42: Next Generation IP Protocol: IPv6

Mapping Ethernet MAC Address

• Mapping a 48-bit Ethernet address into a 64-bit interface identifier is more involved

• 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 FFEE16

Page 43: Next Generation IP Protocol: IPv6

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.

SolutionWe only need to change the seventh bit of the first octet from 0 to 1 and change the format to colon hex notation. The result is F7A9:23EF:0714:7AD2.

ExampleExample 26.11

Page 44: Next Generation IP Protocol: IPv6

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.

SolutionWe only need to change the seventh bit of the first octet from 0 to 1, insert two octet FFFE16 and change the format to colon hex notation. The result is F7A9:23FF:FE14:7AD2 in colon hex.

ExampleExample 26.12

Page 45: Next Generation IP Protocol: IPv6

An organization is assigned the block 2000:1456:2474/48. What is the CIDR notation for the blocks in the first and second subnets in this organization.

SolutionTheoretically, the first and second subnets should use the block with subnet identifier 000116 and 000216. This means that the blocks are

2000:1456:2474:0000/64 and

2000:1456:2474:0001/64.

ExampleExample 26.13

Page 46: Next Generation IP Protocol: IPv6

An organization is assigned the block 2000:1456:2474/48. What is the IPv6 address of an interface in the third subnet if the IEEE physical address of the computer is (F5-A9-23-14-7A-D2)16.

SolutionThe interface identifier is F7A9:23FF:FE14:7AD2 (see Example 26.12). If we add this identifier to the global prefix and the subnet identifier, we get:

ExampleExample 26.14

Page 47: Next Generation IP Protocol: IPv6

26-4 AUTOCONFIGURATION

One of the interesting features of IPv6 addressing is the autoconfiguration of hosts. As we discussed in IPv4, the host and routers are originally configured manually by the network manager. However, the Dynamic Host Configuration Protocol, DHCP, can be used to allocate an IPv4 address to a host that joins the network. In IPv6, DHCP protocol can still be used to allocate an IPv6 address to a host, but a host can also configure itself.

Page 48: Next Generation IP Protocol: IPv6

Process of Auto-configuration

1. The host first creates a link local address for itself. The result is a 128-bit link local address

2. The host then tests to see if this link local address is unique and not used by other hosts. The host sends a neighbor solicitation message and waits for neighbor advertisement message. If any host in the subnet is using this address, the process fails and the host cannot autoconfigure itself; it needs to use other means such as DHCP for this purpose

Page 49: Next Generation IP Protocol: IPv6

Process of Auto-configuration (cont.)

3. If the uniqueness of the link local address is passed, the host stores this address as its link-local address (for private communication), but it still needs a global unicast address. The host then sends a router solicitation message to a local router. If there is a router running on the network, the host receives a router advertisement message that includes the global unicast prefix and subnet prefix that the host needs to add to its interface identifier to generate its global unicast address. If the router cannot help the host with the configuration, it informs the host in the router advertisement message (by setting a flag). The host then needs to use other means for configuration.

Page 50: Next Generation IP Protocol: IPv6

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.

SolutionThe host first creates its interface identifier as

F7A9:23FF:FE11:9BE2 using the Ethernet address read from its card. The host then creates its link-local address as

ExampleExample 26.15

Page 51: Next Generation IP Protocol: IPv6

Assuming that this address is unique, the host sends a router solicitation message and receives the router advertisement message that announces the combination of global unicast prefix and the subnet identifier as 3A21:1216:2165:A245:1232. The host then appends its interface identifier to this prefix to find and store its global unicast address as:

ExampleExample 26.15 Continued

Page 52: Next Generation IP Protocol: IPv6

Packet Format

• Each packet is composed of a mandatory base header followed by the payload

• The payload consists of 2 parts: optional extension headers and data from an upper layer

• The base header occupies 40 bytes, whereas the extension headers and data from the upper layer contain up to 65,535 bytes of information

Page 53: Next Generation IP Protocol: IPv6

Base Header

• Version. The 4-bit field defines the version number of the IP. For IPv6, the value is 6

• Traffic class. The 8-bit field is used to distinguish different payloads with different delivery requirements. It replaces the service class field in IPv4

• Flow label. This 20-bit field is designed to provide special handling for a particular flow of data

• Payload length. The 2-byte payload length field defines the length of the IP datagram excluding the base header

Page 54: Next Generation IP Protocol: IPv6

Base Header (cont.)

• Next header. The 8-bit field defines the header that follows the base header in the datagram. The next header is either one of the optional extension header or the header of an encapsulated packet such as TCP and UDP. This field in version 4 is called the protocol

• Hop limit. The 8-bit field serves the same purpose as the TTL field in IPv4

• Source address. This field identifies the original source of the datagram

• Destination address. This field usually identifies the final destination of the datagram. However, if source routing is used, this field contains the address of the next router

Page 55: Next Generation IP Protocol: IPv6

Next Header Codes

Page 56: Next Generation IP Protocol: IPv6

Traffic Class

• The traffic class field defines the priority of each packet with respect to other packets from the same source

• If one of two consecutive datagrams must be discarded due to congestion, the datagram with the lower packet priority will be discarded

• IPv6 divides traffic into 2 broad categories: congestion-controlled and non-congestion-controlled

Page 57: Next Generation IP Protocol: IPv6

Congestion-Controlled Traffic

• If a source adapts itself to traffic slowdown when there is congestion, the traffic is referred to as congestion-controlled traffic

• In congestion-controlled traffic, it is understood that packets may arrive delayed or even lost or received out of order

• Congestion-controlled data are assigned priorities from 0 to 7 (lowest to highest)

• The priority description are as follows:

Page 58: Next Generation IP Protocol: IPv6

Congestion-Controlled Traffic (cont.)

• No specific traffic. The priority 0 is assigned to a packet when the process does not define a priority

• Background data. This group defines data that is usually delivered in the background. Delivery of the news is a good example

• Unattended data traffic. If the user is not waiting (attending) for the data to be received, the packet will be given a priority 2. Email belongs to this group

• Attended bulk data traffic. A protocol that transfer data while the user is waiting to receive the data is given a priority 4. FTP and HTTP belong to this group

• Interactive traffic. Protocols such as TELNET that need user interaction are assigned a priority 6

• Control traffic. Control traffic such as OSPF, RIP, and SNMP is given the highest priority

Page 59: Next Generation IP Protocol: IPv6

Noncongestion-Controlled Traffic

• This refers to a type of traffic that expects minimum delay. Discarding of packet is not desirable. Retransmission is most cases is impossible

• Real-time audio and video are example of this type of traffic

• Priority number from 8 to 15 are assigned to this type of traffic. The priorities are usually assigned based on how much the quality of received data is affected by discarding some packets

• Data containing less redundancy (such as low-fidelity audio or video) can be given a higher priority than data containing more redundancy (such as high-fidelity audio or video)

Page 60: Next Generation IP Protocol: IPv6

Flow Label

• To a router, a flow is a sequence of packets that share the same characteristics such as traveling the same path, using the same resources, having the same kind of security, and so on

• A router that supports the handling of flow labels has a flow label table. The table has an entry for each active flow label; each entry defines the services required by the corresponding flow label

• When the router receives a packet, it consults its flow label table to find the corresponding entry for the flow label value defined in the packet. It then provides the packet with the service mentioned in the entry

Page 61: Next Generation IP Protocol: IPv6

Flow Label (cont.)

• However, the flow label itself does not provide the information for the entries of the flow label table; the information is provided by other means such as the hop-by-hop options or other protocols

• In its simplest form, a flow label can be used to speed up the processing of a packet by a router. When a router receives a packet, instead of consulting the routing table, it can easily look in a flow label for the next hop

Page 62: Next Generation IP Protocol: IPv6

Flow Label (cont.)

• In its more sophisticated form, a flow label can be used to support the transmission of real-time audio and video

• A process can make a reservation for these resources beforehand to guarantee that real-time data will not be delayed due to a lack of resources

Page 63: Next Generation IP Protocol: IPv6

Flow Label (cont.)

• To allow the effective use of flow labels, 3 rules have been defined:– The flow label is assigned to a packet by the

source host. The label is a random number between 1 and 224-1

– If a host does not support the flow label, it sets this field to zero. If a router does not support the flow label, it simply ignores it

– All packets belonging to the same flow have the same source, same destination, same priority, and same options

Page 64: Next Generation IP Protocol: IPv6

Comparison between IPv4 and IPv6 Headers

Page 65: Next Generation IP Protocol: IPv6

Extension Headers

• To give more functionality to the IP datagram, the base header can be followed by up to six extension headers which are hop-by-hop option, destination option, source routing, fragmentation, authentication, and encrypted security payload

Page 66: Next Generation IP Protocol: IPv6

Extension Header Format

Page 67: Next Generation IP Protocol: IPv6

Hop-by-Hop Option

• The hop-by-hop option is used when the source needs to pass information to all routers visited by the datagram

• The first field defines the next header in the chain of headers

• The header length defines the number of bytes in the header (including the next header field).

• The rest of the header contains different options

Page 68: Next Generation IP Protocol: IPv6

Hop-by-Hop Option (cont.)

• So far, only three options have been defined: Pad1, PadN and jumbo payload

• Pad1 and PadN are designed for alignment purposes• Jumbo payload is used to define a longer length than the maximum

length of 65,535 bytes

Action C Type

1 bit2 bits 5 bits

Action: if the option not recognized00 Skip this option01 Discard datagram, no more action10 Discard datagram and send ICMP message11 Discard datagram send ICMP message if not multicast

C: Change in option value

0 Does not change in transit1 May be changed in transit

Type00000 Pad100001 PadN00010 Jumbo payload

Page 69: Next Generation IP Protocol: IPv6

Pad1• This option is 1 byte long and is designed for alignment purposes• Some options need to start at a specific bit of the 32-bit word. If

an option falls short of this requirement by exactly one byte, Pad1 is added to make up the difference

• Pad1 contains neither the option length field nor the option data field. It consists solely of the option code field with all bits set to 0

• Pad1 can be inserted anywhere in the hop-by-hop option header

Page 70: Next Generation IP Protocol: IPv6

PadN

• PadN is similar in concept to Pad1. The difference is that PadN is used with 2 or more bytes are needed for alignment

• This option consists of 1 byte of option code, 1 byte of 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

Page 71: Next Generation IP Protocol: IPv6

Jumbo Payload

• Jumbo payload option is used to define the longer length of the maximum IP packet size

• The jumbo payload option must always start at a multiple of 4 bytes plus 2 from the beginning of the extension headers

Page 72: Next Generation IP Protocol: IPv6

Destination Option

• The destination option is used when the source needs to pass information to the destination only

• Intermediate routers are not permitted access to this information

• The format of the destination option is the same as the hop-by-hop option

• So far, only the Pad1 and PadN options have been defined

Page 73: Next Generation IP Protocol: IPv6

Source Routing• The source routing extension

header combines the concepts of the strict source route and the loose source route options of IPv4

• The source routing header contains a minimum of 7 field. The first 2 fields are identical to that of the hop-by-hop extension header

• The type field defines source routing type

• The address left field indicates the number of hops still needed to reach the destination

• The strict/loose mask field determines by the source. If the mask is loose, other routers may be visited in addition to those in the header

Page 74: Next Generation IP Protocol: IPv6

Source Routing Example

Page 75: Next Generation IP Protocol: IPv6

Fragmentation

• In IPv4, the source or a router is required to fragment if the size of the datagram is larger than the MTU of the network over which the datagram travels

• In IPv6, only the original source can fragment. A source then must use a Path MTU Discovery technique to find the smallest MTU supported by any network on the path

• If the source does not use a Path MTU Discovery technique, it fragments the datagram to a size of 1280 bytes or smaller

Page 76: Next Generation IP Protocol: IPv6

Authentication• The authentication extension header has a dual purpose: it validates

the message sender and ensures the integrity of data• The former is needed so the receiver can be sure that a message is

from the genuine sender and not from an imposter• The latter is needed to check that the data is not altered in transition

by some hacker• The security parameter index field defines the algorithm used for

authentication• The authentication data field contains the actual data generated by

the algorithm

Page 77: Next Generation IP Protocol: IPv6

Encrypted Security Payload

• The encrypted security payload (ESP) is an extension confidentiality and guards against eavesdropping

• The parameter index field is a 32-bit word that defines the type of encryption/decryption used

• The other field contains the encrypted data along with any extra parameters needed by the algorithm

• Encryption can be implemented in 2 ways: transport mode or tunnel mode (discussed in IPSec chapter)

Page 78: Next Generation IP Protocol: IPv6

Options Comparison between IPv4 and IPv6

Page 79: Next Generation IP Protocol: IPv6

Transition From IPv4 To IPv6

• It takes a considerable amount of time before every system in the Internet can move from IPv4 and IPv6

• The transition must be smooth to prevent any problems between IPv4 and IPv6 systems

• Three strategies have been devised by the IETF to help the transition: dual stack, tunneling, header translation

Page 80: Next Generation IP Protocol: IPv6

Dual Stack

• It is recommended that all hosts, before migrating completely to version 6, have a dual stack of protocol

• To determine which version to use when sending a packet to a destination, the source host queries the DNS

Page 81: Next Generation IP Protocol: IPv6

Tunneling

• Tunneling is a strategy used when 2 computers using IPv6 want to communicate with each other and the packet must pass through a region that uses IPv4

• The IPv6 packet is encapsulated in a IPv4 packet when it enters the region and it leaves its capsule when it exits the region

• To make it clear that the IPv4 packet is carrying an IPv6 packet as data, the protocol value is set to 41

• Tunneling uses the compatible addresses

Page 82: Next Generation IP Protocol: IPv6

Automatic Tunneling• If the receiving host uses a compatible IPv6 address, tunneling occurs

automatically without any reconfiguration• In automatic tunneling, the sender sends the receiver an IPv6 packet

using the IPv6 compatible address as the destination address• When the packet reaches the boundary of the IPv4 network, the router

encapsulates it in an IPv4 packet, which should have an IPv4 address• To get this address, the router extracts the IPv4 address embedded in

the IPv6 address• The packet then travels the rest of its journey as an IPv4 packet

Page 83: Next Generation IP Protocol: IPv6

Configured Tunneling

• If the receiving host does not support an IPv6-compatible address, the sender receives a noncompatible IPv6 address from the DNS

• In this case, configured tunneling is used. The sender sends the IPv6 packet with the receiver’s noncompatible IPv6 address

• However, the packet cannot pass through the IPv4 region without first being encapsulated in an IPv4 packet

• The 2 routers at the boundary of the IPv4 region are configured to pass the packet encapsulated in an IPv4 packet

Page 84: Next Generation IP Protocol: IPv6

Configured Tunneling (cont.)

• The router at one end sends the IPv4 packet with its own IPv4 address as the source and the other router’s IPv4 address as the destination

• The other router receives the packet, decapsulates the IPv6 packet, and sends it to the destination host

Page 85: Next Generation IP Protocol: IPv6

Header Translation

• Header translation is necessary when the majority of the Internet has moved to IPv6 but some system still use IPv4

• Tunneling does not work in this situation because the packet must be in the IPv4 format to be understood by the receiver

• In this case, the header format must be changed totally through header translation

• Header translation uses the mapped address to translate an IPv6 address to an IPv4 address

Page 86: Next Generation IP Protocol: IPv6

Header Translation Procedure