ICMPv6

Last updated
Internet Control Message Protocol for IPv6
Communication protocol
ICMP header - General-en.svg
General structure of ICMPv6 Messages
AbbreviationICMPv6
PurposeAuxiliary Protocol for IPv6
IntroductionDecember 1995;28 years ago (1995-12)
OSI layer Network layer
RFC(s) RFC 4443

Internet Control Message Protocol version 6 (ICMPv6) is the implementation of the Internet Control Message Protocol (ICMP) for Internet Protocol version 6 (IPv6). [1] ICMPv6 is an integral part of IPv6 and performs error reporting and diagnostic functions.

Contents

ICMPv6 has a framework for extensions to implement new features. Several extensions have been published, defining new ICMPv6 message types as well as new options for existing ICMPv6 message types. For example, Neighbor Discovery Protocol (NDP) is a node discovery protocol based on ICMPv6 which replaces and enhances functions of ARP. [2] Secure Neighbor Discovery (SEND) is an extension of NDP with extra security. Multicast Listener Discovery (MLD) is used by IPv6 routers for discovering multicast listeners on a directly attached link, much like Internet Group Management Protocol (IGMP) is used in IPv4. Multicast Router Discovery (MRD) allows the discovery of multicast routers.

Message types and formats

ICMPv6 messages may be classified as error messages and information messages. ICMPv6 messages are transported by IPv6 packets in which the IPv6 Next Header value for ICMPv6 is set to the value 58.

The ICMPv6 message consists of a header and the protocol payload. The header contains only three fields: Type (8 bits), Code (8 bits), and Checksum (16 bits).

ICMPv6 message
Offset Octet 0123
Octet Bit 012345678910111213141516171819202122232425262728293031
00TypeCodeChecksum
432Message body
864
Type: 8 bits:Specifies the type of the message. Values in the range from 0 to 127 (high-order bit is 0) indicate an error message, while values in the range from 128 to 255 (high-order bit is 1) indicate an information message.
Code: 8 bits:The Code field value depends on the message type and provides an additional level of message granularity.
Checksum: 16 bits:Provides a minimal level of integrity verification for the ICMP message. The checksum is calculated from the ICMP message (starting with the Type field), prepended with an IPv6 pseudo-header. [1] See below.
Message body: Variable:Contents depends on the message.

Types

Control messages are identified by the value in the type field. The code field gives additional context information for the message. Some messages serve the same purpose as the correspondingly named ICMP message types.

TypeCode
ValueMeaningValueMeaning
ICMPv6 Error Messages
1 Destination unreachable 0no route to destination
1communication with destination administratively prohibited
2beyond scope of source address
3address unreachable
4port unreachable
5source address failed ingress/egress policy
6reject route to destination
7Error in Source Routing Header
2 Packet too big 0
3 Time exceeded 0hop limit exceeded in transit
1fragment reassembly time exceeded
4Parameter problem0erroneous header field encountered
1unrecognized Next Header type encountered
2unrecognized IPv6 option encountered
100Private experimentation
101Private experimentation
127Reserved for expansion of ICMPv6 error messages
ICMPv6 Informational Messages
128 Echo Request 0
129 Echo Reply 0
130Multicast Listener Query (MLD)0

There are two subtypes of Multicast Listener Query messages:

  • General Query, used to learn which multicast addresses have listeners on an attached link.
  • Multicast-Address-Specific Query, used to learn if a particular multicast address has any listeners on an attached link.

These two subtypes are differentiated by the contents of the Multicast Address field, as described in section 3.6 of RFC 2710

131Multicast Listener Report (MLD)0
132Multicast Listener Done (MLD)0
133Router Solicitation (NDP)0
134Router Advertisement (NDP)0
135Neighbor Solicitation (NDP)0
136Neighbor Advertisement (NDP)0
137Redirect Message (NDP)0
138Router Renumbering [3] 0Router Renumbering Command
1Router Renumbering Result
255Sequence Number Reset
139ICMP Node Information Query0The Data field contains an IPv6 address which is the Subject of this Query.
1The Data field contains a name which is the Subject of this Query, or is empty, as in the case of a NOOP.
2The Data field contains an IPv4 address which is the Subject of this Query.
140ICMP Node Information Response0A successful reply. The Reply Data field may or may not be empty.
1The Responder refuses to supply the answer. The Reply Data field will be empty.
2The Qtype of the Query is unknown to the Responder. The Reply Data field will be empty.
141Inverse Neighbor Discovery Solicitation Message0
142Inverse Neighbor Discovery Advertisement Message0
143Multicast Listener Discovery (MLDv2) reports [4]
144Home Agent Address Discovery Request Message0
145Home Agent Address Discovery Reply Message0
146Mobile Prefix Solicitation0
147Mobile Prefix Advertisement0
148Certification Path Solicitation (SEND)
149Certification Path Advertisement (SEND)
151Multicast Router Advertisement (MRD)
152Multicast Router Solicitation (MRD)
153Multicast Router Termination (MRD)
155RPL Control Message
160Extended Echo Request [5] 0Request Extended Echo
161Extended Echo Reply [5] 0No Error
1Malformed Query
2No Such Interface
3No Such Table Entry
4Multiple Interfaces Satisfy Query
200Private experimentation
201Private experimentation
255Reserved for expansion of ICMPv6 informational messages

Note that the table above is not comprehensive. The current complete list of assigned ICMPv6 types can be found at this link: IANA: ICMPv6 Parameters.

Checksum

ICMPv6 provides a minimal level of message integrity verification by the inclusion of a 16-bit checksum in its header. The checksum is calculated starting with a pseudo-header of IPv6 header fields according to the IPv6 standard, [6] which consists of the source and destination addresses, the packet length and the next header field, the latter of which is set to the value 58. Following this pseudo header, the checksum is continued with the ICMPv6 message. The checksum computation is performed according to Internet protocol standards using 16-bit ones' complement summation, followed by a final ones' complement of the checksum itself and inserting it into the checksum field. [7] Note that this differs from the way it is calculated for IPv4 in ICMP, but is similar to the calculation done in TCP.

ICMPv6 pseudo-header
Offset Octet 0123
Octet Bit 012345678910111213141516171819202122232425262728293031
00Source Address
432
864
1296
16128Destination Address
20160
24192
28224
32256ICMPv6 Length
36288ZeroesNext Header

Format

The payload of an ICMPv6 message varies according the type of message being sent. It begins at bit 32 immediately after the header described above. For some messages such as destination unreachable or time exceeded there is no defined message body.

Destination Unreachable
Bit offset0–78–1516–31
01CodeChecksum
32Unused
64Message body (Variable Size)
Time Exceeded
Bit offset0–78–1516–31
03CodeChecksum
32Unused
64Message body (Variable Size)

Others define a use only for the first four bytes of the body with no other defined content:

Packet Too Big
Bit offset0–78–1516–31
020Checksum
32MTU
64Message body (Variable Size)
Parameter Problem
Bit offset0–78–1516–31
04CodeChecksum
32Pointer
64Message body (Variable Size)
Echo Request
Bit offset0–78–1516–31
01280Checksum
32IdentifierSequence Number
64Data (Variable Size)
Echo Reply
Bit offset0–78–1516–31
01290Checksum
32IdentifierSequence Number
64Data (Variable Size)

In the case of NDP messages the first four bytes are either reserved or used for flags/hoplimit. While the reset of body has unspecified structured data:

Router Solicitation
Bit offset0–78–1516–31
01330Checksum
32Reserved
64Options (Variable Size)
Router Advertisement
Bit offset0–78–1516–31
01340Checksum
32Cur Hop LimitManaged Address FlagOther Configuration FlagReservedRouter Lifetime
64Reachable Time
96Retrans Time
128Options (Variable Size)
Neighbor Solicitation
Bit offset0–78–1516–31
01350Checksum
32Reserved
64Target Address (16 bytes)
192Options (Variable Size)
Neighbor Advertisement
Bit offset0–78–1516–31
01360Checksum
32From Router (R)Solicited Flag(S)Override(O)Reserved
64Target Address (16 bytes)
192Options (Variable Size)

For a redirect the first bytes of the message body are reserved but not used. This is followed by a Target and destination address. Unspecified options can be attached to the end:

ICMPv6 Redirect
Bit offset0–78–1516–31
01370Checksum
32Reserved
64Target Address (16 bytes)
192Destination Address (16 bytes)
320Options (Variable Size)

Message processing

When an ICMPv6 node receives a packet, it must undertake actions that depend on the type of message. The ICMPv6 protocol must limit the number of error messages sent to the same destination to avoid network overloading. For example, if a node continues to forward erroneous packets, ICMP will signal the error to the first packet and then do so periodically, with a fixed minimum period or with a fixed network maximum load. An ICMP error message must never be sent in response to another ICMP error message.

Related Research Articles

The Internet Control Message Protocol (ICMP) is a supporting protocol in the Internet protocol suite. It is used by network devices, including routers, to send error messages and operational information indicating success or failure when communicating with another IP address. For example, an error is indicated when a requested service is not available or that a host or router could not be reached. ICMP differs from transport protocols such as TCP and UDP in that it is not typically used to exchange data between systems, nor is it regularly employed by end-user network applications.

<span class="mw-page-title-main">IPv4</span> Fourth version of the Internet Protocol

Internet Protocol version 4 (IPv4) is the first version of the Internet Protocol (IP) as a standalone specification. It is one of the core protocols of standards-based internetworking methods in the Internet and other packet-switched networks. IPv4 was the first version deployed for production on SATNET in 1982 and on the ARPANET in January 1983. It is still used to route most Internet traffic today, even with the ongoing deployment of Internet Protocol version 6 (IPv6), its successor.

<span class="mw-page-title-main">IPv6</span> Version 6 of the Internet Protocol

Internet Protocol version 6 (IPv6) is the most recent version of the Internet Protocol (IP), the communications protocol that provides an identification and location system for computers on networks and routes traffic across the Internet. IPv6 was developed by the Internet Engineering Task Force (IETF) to deal with the long-anticipated problem of IPv4 address exhaustion, and was intended to replace IPv4. In December 1998, IPv6 became a Draft Standard for the IETF, which subsequently ratified it as an Internet Standard on 14 July 2017.

The Internet Protocol (IP) is the network layer communications protocol in the Internet protocol suite for relaying datagrams across network boundaries. Its routing function enables internetworking, and essentially establishes the Internet.

In computer networking, the maximum transmission unit (MTU) is the size of the largest protocol data unit (PDU) that can be communicated in a single network layer transaction. The MTU relates to, but is not identical to the maximum frame size that can be transported on the data link layer, e.g., Ethernet frame.

ping (networking utility) Network utility used to test the reachability of a host

ping is a computer network administration software utility used to test the reachability of a host on an Internet Protocol (IP) network. It is available for virtually all operating systems that have networking capability, including most embedded network administration software.

The Transmission Control Protocol (TCP) is one of the main protocols of the Internet protocol suite. It originated in the initial network implementation in which it complemented the Internet Protocol (IP). Therefore, the entire suite is commonly referred to as TCP/IP. TCP provides reliable, ordered, and error-checked delivery of a stream of octets (bytes) between applications running on hosts communicating via an IP network. Major internet applications such as the World Wide Web, email, remote administration, and file transfer rely on TCP, which is part of the Transport layer of the TCP/IP suite. SSL/TLS often runs on top of TCP.

In computer networking, the User Datagram Protocol (UDP) is one of the core communication protocols of the Internet protocol suite used to send messages to other hosts on an Internet Protocol (IP) network. Within an IP network, UDP does not require prior communication to set up communication channels or data paths.

A multicast address is a logical identifier for a group of hosts in a computer network that are available to process datagrams or frames intended to be multicast for a designated network service. Multicast addressing can be used in the link layer, such as Ethernet multicast, and at the internet layer for Internet Protocol Version 4 (IPv4) or Version 6 (IPv6) multicast.

The Internet Group Management Protocol (IGMP) is a communications protocol used by hosts and adjacent routers on IPv4 networks to establish multicast group memberships. IGMP is an integral part of IP multicast and allows the network to direct multicast transmissions only to hosts that have requested them.

Generic routing encapsulation (GRE) is a tunneling protocol developed by Cisco Systems that can encapsulate a wide variety of network layer protocols inside virtual point-to-point links or point-to-multipoint links over an Internet Protocol network.

The Neighbor Discovery Protocol (NDP), or simply Neighbor Discovery (ND), is a protocol of the Internet protocol suite used with Internet Protocol Version 6 (IPv6). It operates at the internet layer of the Internet model, and is responsible for gathering various information required for network communication, including the configuration of local connections and the domain name servers and gateways.

A ping of death is a type of attack on a computer system that involves sending a malformed or otherwise malicious ping to a computer. In this attack, a host sends hundreds of ping requests with a packet size that is large or illegal to another host to try to take it offline or to keep it preoccupied responding with ICMP Echo replies.

Multicast DNS (mDNS) is a computer networking protocol that resolves hostnames to IP addresses within small networks that do not include a local name server. It is a zero-configuration service, using essentially the same programming interfaces, packet formats and operating semantics as unicast Domain Name System (DNS). It was designed to work as either a stand-alone protocol or compatible with standard DNS servers. It uses IP multicast User Datagram Protocol (UDP) packets and is implemented by the Apple Bonjour and open-source Avahi software packages, included in most Linux distributions. Although the Windows 10 implementation was limited to discovering networked printers, subsequent releases resolved hostnames as well. mDNS can work in conjunction with DNS Service Discovery (DNS-SD), a companion zero-configuration networking technique specified separately in RFC 6763.

The link-state advertisement (LSA) is a basic communication means of the OSPF routing protocol for the Internet Protocol (IP). It communicates the router's local routing topology to all other local routers in the same OSPF area. OSPF is designed for scalability, so some LSAs are not flooded out on all interfaces, but only on those that belong to the appropriate area. In this way detailed information can be kept localized, while summary information is flooded to the rest of the network. The original IPv4-only OSPFv2 and the newer IPv6-compatible OSPFv3 have broadly similar LSA types.

Path MTU Discovery (PMTUD) is a standardized technique in computer networking for determining the maximum transmission unit (MTU) size on the network path between two Internet Protocol (IP) hosts, usually with the goal of avoiding IP fragmentation. PMTUD was originally intended for routers in Internet Protocol Version 4 (IPv4). However, all modern operating systems use it on endpoints. In IPv6, this function has been explicitly delegated to the end points of a communications session. As an extension to the standard path MTU discovery, a technique called Packetization Layer Path MTU Discovery works without support from ICMP.

The internet layer is a group of internetworking methods, protocols, and specifications in the Internet protocol suite that are used to transport network packets from the originating host across network boundaries; if necessary, to the destination host specified by an IP address. The internet layer derives its name from its function facilitating internetworking, which is the concept of connecting multiple networks with each other through gateways.

The Internet checksum, also called the IPv4 header checksum is a checksum used in version 4 of the Internet Protocol (IPv4) to detect corruption in the header of IPv4 packets. It is carried in the IP packet header, and represents the 16-bit result of summation of the header words.

<span class="mw-page-title-main">IPv6 address</span> Label to identify a network interface of a computer or other network node

An Internet Protocol version 6 address is a numeric label that is used to identify and locate a network interface of a computer or a network node participating in a computer network using IPv6. IP addresses are included in the packet header to indicate the source and the destination of each packet. The IP address of the destination is used to make decisions about routing IP packets to other networks.

An IPv6 packet is the smallest message entity exchanged using Internet Protocol version 6 (IPv6). Packets consist of control information for addressing and routing and a payload of user data. The control information in IPv6 packets is subdivided into a mandatory fixed header and optional extension headers. The payload of an IPv6 packet is typically a datagram or segment of the higher-level transport layer protocol, but may be data for an internet layer or link layer instead.

References

  1. 1 2 A. Conta; S. Deering (March 2006). M. Gupta (ed.). Internet Control Message Protocol (ICMPv6) for the Internet Protocol Version 6 (IPv6) Specification. Network Working Group. doi: 10.17487/RFC4443 . STD 89. RFC 4443.Internet Standard 89. Obsoletes RFC  2463. Updates RFC  2780. Updated by RFC  4884.
  2. T. Mrugalski; M. Siodelski; B. Volz; A. Yourtchenko; M. Richardson; S. Jiang; T. Lemon; T. Winters (November 2018). Dynamic Host Configuration Protocol for IPv6 (DHCPv6). IETF. doi: 10.17487/RFC8415 . ISSN   2070-1721. RFC 8415.Proposed Standard. sec. 3. Obsoletes RFC  3315, 3633, 3736, 4242, 7083, 7283 and 7550.
  3. M. Crawford (August 2000). Router Renumbering for IPv6. Network Working Group. doi: 10.17487/RFC2894 . RFC 2894.Proposed Standard.
  4. R. Vida; L. Costa, eds. (June 2004). Multicast Listener Discovery Version 2 (MLDv2) for IPv6. Network Working Group. doi: 10.17487/RFC3810 . RFC 3810.Proposed Standard. Updates RFC  2710. Updated by RFC  4604.
  5. 1 2 R. Bonica; R. Thomas; J. Linkova; C. Lenart; M. Boucadair (February 2018). PROBE: A Utility for Probing Interfaces. Internet Engineering Task Force (IETF). doi: 10.17487/RFC8335 . ISSN   2070-1721. RFC 8335.Proposed Standard. Updates RFC  4884.
  6. S. Deering; R. Hinden (July 2017). Internet Protocol, Version 6 (IPv6) Specification. IETF. doi: 10.17487/RFC8200 . STD 86. RFC 8200.Internet Standard 86. sec. 8.1. Obsoletes RFC  2460.
  7. R. Braden; D. Borman; C. Partridge (September 1988). Computing the Internet Checksum. Network Working Group. doi: 10.17487/RFC1071 . RFC 1071.Informational. Updated by RFC  1141.