Provided by Colasoft Co., Ltd.

ICMPv6 ( Internet Control Message Protocol Version 6 )

Home > Protocols > ICMPv6 Update: 2005-11-17 17:28:24    I have words to say about this protocol
On this page
SUMMARY
Protocol : Internet Control Message Protocol Version 6
Protocol suite : TCP/IP
Layer : Network Layer
Type : Network Layer control protocol
Related protocols : IP,
IPv6,
TCP,
UDP,
IGMP,
SNMP,
IRDP
DESCRIPTION
ICMPv6 is used by IPv6 nodes to report errors encountered in processing packets, and to perform other internet-layer functions, such as diagnostics (ICMPv6 "ping"). ICMPv6 is an integral part of IPv6 and must be fully implemented by every IPv6 node.


Header format
The structure of the ICMPv6 header is shown in the following illustration.

8

16

32 bits

Type

Code

Checksum


  • Type
    The type of the message. Messages can be error or informational messages. Error messages can be Destination unreachable, Packet too big, Time exceed, Parameter problem. The possible informational messages are, Echo Request, Echo Reply, Group Membership Query, Group Membership Report, Group Membership Reduction.


  • Code
    For each type of message several different codes are defined.
    An example of this is the Destination Unreachable message, where possible messages are: no route to destination, communication with destination administratively prohibited, not a neighbor, address unreachable, port unreachable. For further details, refer to the standard.


  • Checksum
    Checksum that covers the ICMPv6 message and contains the 16-bit one's complement of the one's complement sum of the entire ICMPv6 message starting with the ICMPv6 message type field, prepended with a pseudo-header of IPv6 header fields. The pseudo-header contains the following fields:


  • 24

    32 bit

    Source IPv6 address

    Destination IPv6 address

    Upper layer packet length

    0

    Next header



Message General Format
ICMPv6 messages are grouped into two classes: error messages and informational messages. Error messages are identified as such by having a zero in the high-order bit of their message Type field values. Thus, error messages have message Types from 0 to 127; informational messages have message Types from 128 to 255.

This document defines the message formats for the following ICMPv6 messages:
  • ICMPv6 error messages


  • 1Destination UnreachableA Destination Unreachable message SHOULD be generated by a router, or by the IPv6 layer in the originating node, in response to a packet that cannot be delivered to its destination address for reasons other than congestion.
    2Packet Too BigA Packet Too Big must be sent by a router in response to a packet that it cannot forward because the packet is larger than the MTU of the outgoing link. The information in this message is used as part of the Path MTU Discovery process [PMTU].
    3Time ExceededIf a router receives a packet with a Hop Limit of zero, or a router decrements a packet"s Hop Limit to zero, it must discard the packet and send an ICMPv6 Time Exceeded message with Code 0 to the source of the packet. This indicates either a routing loop or too small an initial Hop Limit value.
    4Parameter ProblemIf an IPv6 node processing a packet finds a problem with a field in the IPv6 header or extension headers such that it cannot complete processing the packet, it must discard the packet and should send an ICMPv6 Parameter Problem message to the packet"s source, indicating the type and location of the problem.


  • ICMPv6 informational messages


  • 128Echo RequestEvery node MUST implement an ICMPv6 Echo responder function that receives Echo Requests and sends corresponding Echo Replies. A node should also implement an application-layer interface for sending Echo Requests and receiving Echo Replies, for diagnostic purposes.
    129Echo ReplyEvery node MUST implement an ICMPv6 Echo responder function that receives Echo Requests and sends corresponding Echo Replies. A node SHOULD also implement an application-layer interface for sending Echo Requests and receiving Echo Replies, for diagnostic purposes.



Message Source Address Determination
A node that sends an ICMPv6 message has to determine both the Source and Destination IPv6 Addresses in the IPv6 header before calculating the checksum. If the node has more than one unicast address, it must choose the Source Address of the message as follows:
  • If the message is a response to a message sent to one of the node's unicast addresses, the Source Address of the reply must be that same address.


  • If the message is a response to a message sent to a multicast or anycast group in which the node is a member, the Source Address of the reply must be a unicast address belonging to the interface on which the multicast or anycast packet was received.


  • If the message is a response to a message sent to an address that does not belong to the node, the Source Address should be that unicast address belonging to the node that will be most helpful in diagnosing the error. For example, if the message is a response to a packet forwarding action that cannot complete successfully, the Source Address should be a unicast address belonging to the interface on which the packet forwarding failed.


  • Otherwise, the node's routing table must be examined to determine which interface will be used to transmit the message to its destination, and a unicast address belonging to that interface must be used as the Source Address of the message.


Message Checksum Calculation
The checksum is the 16-bit one's complement of the one's complement sum of the entire ICMPv6 message starting with the ICMPv6 message type field, prepended with a "pseudo-header" of IPv6 header fields. The Next Header value used in the pseudo-header is 58.

Message Processing Rules
Implementations must observe the following rules when processing ICMPv6 messages:
  • If an ICMPv6 error message of unknown type is received, it must be passed to the upper layer.


  • If an ICMPv6 informational message of unknown type is received, it must be silently discarded.


  • Every ICMPv6 error message (type < 128) includes as much of the IPv6 offending (invoking) packet (the packet that caused the error) as will fit without making the error message packet exceed the minimum IPv6 MTU [IPv6].


  • In those cases where the internet-layer protocol is required to pass an ICMPv6 error message to the upper-layer process, the upper-layer protocol type is extracted from the original packet (contained in the body of the ICMPv6 error message) and used to select the appropriate upper-layer process to handle the error.

    If the original packet had an unusually large amount of extension headers, it is possible that the upper-layer protocol type may not be present in the ICMPv6 message, due to truncation of the original packet to meet the minimum IPv6 MTU [IPv6] limit. In that case, the error message is silently dropped after any IPv6-layer processing.


  • An ICMPv6 error message must not be sent as a result of receiving:

    • an ICMPv6 error message, or


    • a packet destined to an IPv6 multicast address (there are two exceptions to this rule:
      (1) the Packet Too Big Message - to allow Path MTU discovery to work for IPv6 multicast.
      (2) the Parameter Problem Message, Code 2 - reporting an unrecognized IPv6 option that has the Option Type highest-order two bits set to 10).


    • a packet sent as a link-layer multicast, (the exception from e.2 applies to this case too).


    • a packet sent as a link-layer broadcast, (the exception from e.2 applies to this case too).


    • a packet whose source address does not uniquely identify a single node -- e.g., the IPv6 Unspecified Address, an IPv6 multicast address, or an address known by the ICMP message sender to be an IPv6 anycast address.


  • Finally, in order to limit the bandwidth and forwarding costs incurred sending ICMPv6 error messages, an IPv6 node MUST limit the rate of ICMPv6 error messages it sends. This situation may occur when a source sending a stream of erroneous packets fails to heed the resulting ICMPv6 error messages. There are a variety of ways of implementing the rate-limiting function, for example:

    Timer-basedLimiting the rate of transmission of error messages to a given source, or to any source, to at most once every T milliseconds.
    Bandwidth-basedLimiting the rate at which error messages are sent from a particular interface to some fraction F of the attached link"s bandwidth.

    The limit parameters (e.g., T or F in the above examples) must be configurable for the node, with a conservative default value (e.g., T = 1 second, NOT 0 seconds, or F = 2 percent, NOT 100 percent).


Top of Page

EXAMPLES

Top of Page


PROTOCOL RELATIONS
Parent layer
Child layer
IP
ICMPv6
Echo Req
Echo Reply
Dest Unreach
Time Exceed
Redirect
Router Solicit
Router Advert
Neighbor Solicit
Neighbor Advert
Top of Page

GLOSSARY
Address
A location of data, usually in main memory or on a disk. You can think of computer memory as an array of storage boxes, each of which is one byte in length. Each box has an address (a unique number) assigned to it. By specifying a memory address, programmers can access a particular byte of data. Disks are divided into tracks and sectors, each of which has a unique address. Usually, you do not need to worry about addresses unless you are a programmer.

A name or token that identifies a network component. In local area networks (LANs), for example, every node has a unique address. On the Internet, every file has a unique address called a URL.

Checksum
Checksum is a simple error-detection scheme in which each transmitted message is accompanied by a numerical value based on the number of set bits in the message. The receiving station then applies the same formula to the message and checks to make sure the accompanying numerical value is the same. If not, the receiver can assume that the message has been garbled.

Destination
Many computer commands move data from one file to another or from one storage device to another. This is referred to as moving the data from the source to the destination (or target). The term is also used as an adjective, as in destination file or destination device.

Destination Unreachable
This message is generated by a router to inform the source host that the destination address is unreachable. If, according to the information in the gateway's routing tables, the network specified in the internet destination field of a datagram is unreachable, e.g., the distance to the network is infinity, the gateway may send a destination unreachable message to the internet source host of the datagram.

If, in the destination host, the IP module cannot deliver the datagram because the indicated protocol module or process port is not active, the destination host may send a destination unreachable message to the source host.

Another case is when a datagram must be fragmented to be forwarded by a gateway yet the Don't Fragment flag is on. In this case the gateway must discard the datagram and may return a destination unreachable message.

Codes 0, 1, 4, and 5 may be received from a gateway. Codes 2 and 3 may be received from a host.

ICMPv6
ICMPv6 is used by IPv6 nodes to report errors encountered in processing packets, and to perform other internet-layer functions, such as diagnostics (ICMPv6 "ping") and multicast membership reporting. ICMPv6 is an integral part of IPv6 and MUST be fully implemented by every IPv6 node.

IPv6
IPv6 is designed as an evolutionary upgrade to the Internet Protocol and will, in fact, coexist with the older IPv4 for some time. IPv6 is designed to allow the Internet to grow steadily, both in terms of the number of hosts connected and the total amount of data traffic transmitted.

Node
In networks, node is a processing location. A node can be a computer or some other device, such as a printer. Every node has a unique network address, sometimes called a Data Link Control (DLC) address or Media Access Control (MAC) address.

In tree structures, node is a point where two or more lines meet.

Packet
A packet is the unit of data that is routed between an origin and a destination on the Internet or any other packet-switched network. When any file (e-mail message, HTML file, Graphics Interchange Format file, Uniform Resource Locator request, and so forth) is sent from one place to another on the Internet, the Transmission Control Protocol (TCP) layer of TCP/IP divides the file into "chunks" of an efficient size for routing. Each of these packets is separately numbered and includes the Internet address of the destination. The individual packets for a given file may travel different routes through the Internet. When they have all arrived, they are reassembled into the original file (by the TCP layer at the receiving end).

Parameter
Characteristic, means defining the characteristics of something. In general, parameters are used to customize a program. For example, filenames, page lengths, and font specifications could all be considered parameters.

In programming, the term parameter is synonymous with argument, a value that is passed to a routine.

Parameter Problem
This message is generated as a response for any error not specifically covered by another ICMP message.

If the gateway or host processing a datagram finds a problem with the header parameters such that it cannot complete processing the datagram it must discard the datagram. One potential source of such a problem is with incorrect arguments in an option. The gateway or host may also notify the source host via the parameter problem message. This message is only sent if the error caused the datagram to be discarded.

The pointer identifies the octet of the original datagram's header where the error was detected (it may be in the middle of an option). Code 0 may be received from a gateway or a host.

Ping
A utility to determine whether a specific IP address is accessible. It works by sending a packet to the specified address and waiting for a reply. PING is used primarily to troubleshoot Internet connections. There are many freeware and shareware Ping utilities available for personal computers.

It is often believed that "Ping" is an abbreviation for Packet Internet Groper, but Ping's author has stated that the names comes from the sound that a sonar makes.

Redirect
In operating system shells, redirection refers to directing input and output to files and devices other than the default I/O devices. By default, input generally comes from the keyboard or mouse, and output goes to the display monitor. With a redirection operator, you can override these defaults so that a command or program takes input from some other device and sends output to a different device. ICMP Redirect is a mechanism for routers to convey routing information to hosts.

Router
A device that forwards data packets along networks. A router is connected to at least two networks, commonly two LANs or WANs or a LAN and its ISP network. Routers are located at gateways, the places where two or more networks connect.

Routers use headers and forwarding tables to determine the best path for forwarding the packets, and they use protocols such as ICMP to communicate with each other and configure the best route between any two hosts.

SNMP
SNMP (Simple Network Management Protocol) is a set of protocols for managing complex networks. The first versions of SNMP were developed in the early 80s. SNMP works by sending messages, called protocol data units (PDUs), to different parts of a network. SNMP-compliant devices, called agents, store data about themselves in Management Information Bases (MIBs) and return this data to the SNMP requesters.

Source
*Source is a place from which data is taken. Many computer commands involve moving data. The place from which the data is moved is called the source, whereas the place it is moved to is called the destination or target.
*Source is the node on a network from which data is sent to its destination.

Time Exceeded
This data is used by the host to match the message to the appropriate process. If the gateway processing a datagram finds the time to live field is zero it must discard the datagram. The gateway may also notify the source host via the time exceeded message.

If a host reassembling a fragmented datagram cannot complete the reassembly due to missing fragments within its time limit it discards the datagram, and it may send a time exceeded message.

If fragment zero is not available then no time exceeded need be sent at all.

Code 0 may be received from a gateway. Code 1 may be received from a host.

Top of Page

REFERENCES
Related links:
                ICMPv6 parameters
RFCs:
[RFC 1933] Transition Mechanisms for IPv6 Hosts and Routers.
[RFC 2460] Internet Protocol, Version 6 (IPv6) Specification.
                Obsoletes: RFC 1883.
[RFC 2461] Neighbor Discovery for IP Version 6 (IPv6).
                Obsoletes: RFC 1970.
[RFC 2463] Internet Control Message Protocol (ICMPv6) for the Internet Protocol Version 6 (IPv6) Specification.
                Obsoletes: RFC 1885.
[RFC 2466] Management Information Base for IP Version 6: ICMPv6 Group.
                Defines SNMP MIB iso.org.dod.internet.mgmt.mib-2.ipv6IcmpMIB (1.3.6.1.2.1.56).
[RFC 2473] Generic Packet Tunneling in IPv6 Specification.
[RFC 2765] Stateless IP/ICMP Translation Algorithm (SIIT).
[RFC 2780] IANA Allocation Guidelines For Values In the Internet Protocol and Related Headers.
[RFC 2894] Router Renumbering for IPv6.
[RFC 3122] Extensions to IPv6 Neighbor Discovery for Inverse Discovery Specification.
[RFC 3775] Mobility Support in IPv6.
                Defines IPv6 protocol 135 (Mobility Header).
                Defines ICMPv6 messages 144, 145, 146, 147.
[RFC 3971] SEcure Neighbor Discovery (SEND).
                Defines ICMPv6 messages 148 (Certification Path Solicitation), 149 (Certification Path Advertisement).
[RFC 4068] Fast Handovers for Mobile IPv6.
                Defines ICMPv6 type 150 subtypes 2, 3, 4 and 5.
                Defines Mobility Header option type 7 (Mobility Header Link-Layer Address).
Obsolete RFCs:
[RFC 1883] Internet Protocol, Version 6 (IPv6) Specification.
                Obsoleted by: RFC 2460.
                Defines the IPv6 addressing architecture.
[RFC 1885] Internet Control Message Protocol (ICMPv6) for the Internet Protocol Version 6 (IPv6) Specification.
                Obsoleted by: RFC 2463.
[RFC 1970] Neighbor Discovery for IP Version 6 (IPv6).
                Obsoleted by: RFC 2461.
                


Top of Page

OTHER PROTOCOLS OF TCP/IP SUITE
AARP   RRP   RTP Video   RTP Audio   RTP   COPS   Gopher   HSRP   ICP   MPLS   IEEE 802.2   CIP   FTP - Data   FTP - Ctrl   IMAPS   IP Fragment   LDAPS   PUP   MSSQL   RSH   SQL   POP3s   RTELNET   RSVP   STP   VLAN   MSN   H.323   MSRDP   HTTPS   WINS   LPD   GTP   ICMPv6   POP   TELNET   H.225   VRRP   PIM   RARP   SAP   OSPF   RLOGIN   SCTP   SIP   RTCP   PPPoE   Mobile IP   IMAP3   WhoIs   SLP   NCP   PPTP   MGCP   LDAP   L2TP   Kerberos   IPv6   GRE   Ethernet SNAP   AFP   CIFS   IEEE 802.3   Finger   NBDGM   NetBEUI   NBSSN   ESP   EIGRP   EGP   DHCP   CGMP   CDP   BOOTP   AH   NBNS   EthernetII   ICQ   PPP   ARP   RIP   IPX   IGRP   IGMP   SSH   RPC   NetBIOS   TFTP   SNMP   SNA   SMB   RADIUS   NTP   NNTP   UDP   TCP   BGP   DNS   SOCKS   IMAP   RTSP   NFS   ICMP   IP   FTP   Telnet   POP3   SMTP   HTTP  
Search RFCs:

Advanced Search
Search Glossary:
Exact search
Fuzzy search


All Protocols
Submit a Request

Recommend an Article

 Layer 7 Application Layer
  AFP
  BOOTP
  CIFS
  CIP
  COPS
  DHCP
  DNS
  Finger
  FTP
  FTP - Ctrl
  FTP - Data
  Gopher
  HSRP
  HTTP
  HTTPS
  ICP
  ICQ
  IMAP
  IMAP3
  IMAPS
  Kerberos
  LPD
  MGCP
  MSN
  MSRDP
  MSSQL
  NCP
  NFS
  NNTP
  NTP
  POP
  POP3
  POP3s
  RADIUS
  RLOGIN
  RRP
  RSH
  RTCP
  RTELNET
  RTP
  RTP Audio
  RTP Video
  RTSP
  SAP
  SIP
  SLP
  SMB
  SMTP
  SNA
  SNMP
  SOCKS
  SSH
  Telnet
  TELNET
  TFTP
  WhoIs
  WINS
 Layer 6 Presentation Layer
  NBNS
  NBSSN
  NCP
  NetBIOS
 Layer 5 Session Layer
  LDAP
  LDAPS
  NCP
  NetBEUI
  RPC
 Layer 4 Transport Layer
  H.225
  H.323
  NBDGM
  NetBEUI
  PUP
  SCTP
  TCP
  UDP
 Layer 3 Network Layer
  AARP
  AH
  BGP
  EGP
  EIGRP
  ESP
  GRE
  GTP
  ICMP
  ICMPv6
  IGMP
  IGRP
  IP
  IP Fragment
  IPv6
  IPX
  Mobile IP
  MPLS
  OSPF
  PIM
  PPPoE
  RIP
  RSVP
  STP
  VRRP
 Layer 2 Data Link Layer
  ARP
  CDP
  CGMP
  Ethernet SNAP
  EthernetII
  IEEE 802.2
  IEEE 802.3
  L2TP
  PPP
  PPTP
  RARP
  SQL
  VLAN
 Layer 1 Physical Layer
© 2006 - 2007 Colasoft Co., Ltd. All rights reserved.