Internet Control Message Protocol

Internet Control Message Protocol

The Internet Control Message Protocol (ICMP) is one of the core protocols of the Internet Protocol Suite. It is chiefly used by networked computers' operating systems to send error messages—indicating, for instance, that a requested service is not available or that a host or router could not be reached.

ICMP [cite news |title=RFC 792 INTERNET CONTROL MESSAGE PROTOCOL; DARPA INTERNET PROGRAM; PROTOCOL SPECIFICATION; Introduction |url=http://www.faqs.org/rfcs/rfc792.html |work=J. Postel |publisher=Internet RFC/STD/FYI/BCP Archives |date=1981-09-01 |accessdate=2008-05-16 ] relies on IP to perform its tasks, and it is an integral part of IP. It differs in purpose from transport protocols such as TCP and UDP in that it is typically not used to send and receive data between end systems. It is usually not used directly by user network applications, with some notable exceptions being the ping tool and traceroute.

Technical details

Internet Control Message Protocol is part of the Internet Protocol Suite as defined in RFC 792. ICMP messages are typically generated in response to errors in IP datagrams (as specified in RFC 1122) or for diagnostic or routing purposes.

The version of ICMP for Internet Protocol version 4 is also known as ICMPv4, as it is part of IPv4. IPv6 has an equivalent protocol, ICMPv6.

ICMP messages are constructed at the IP layer, usually from a normal IP datagram that has generated an ICMP response. IP encapsulates the appropriate ICMP message with a new IP header (to get the ICMP message back to the original sending host) and transmits the resulting datagram in the usual manner.

For example, every machine (such as an intermediate router) that forwards an IP datagram has to decrement the time to live (TTL) field of the IP header by one; if the TTL reaches 0, an ICMP Time to live exceeded in transit message is sent to the source of the datagram.

Each ICMP message is encapsulated directly within a single IP datagram, and thus, like UDP, ICMP is unreliable.

Although ICMP messages are contained within standard IP datagrams, ICMP messages are usually processed as a special case, distinguished from normal IP processing, rather than processed as a normal sub-protocol of IP. In many cases, it is necessary to inspect the contents of the ICMP message and deliver the appropriate error message to the application that generated the original IP packet, the one that prompted the sending of the ICMP message.

Many commonly-used network utilities are based on ICMP messages. The traceroute command is implemented by transmitting UDP datagrams with specially set IP TTL header fields, and looking for ICMP Time to live exceeded in transit (above) and "Destination unreachable" messages generated in response. The related ping utility is implemented using the ICMP "Echo request" and "Echo reply" messages.

ICMP segment structure

Header

The ICMP header starts after bit 160 of the IP header (unless IP options are used).

* Type - ICMP type as specified below.
* Code - further specification of the ICMP type; e.g. : an ICMP Destination Unreachable might have this field set to 1 through 15 each bearing different meaning.
* Checksum - This field contains error checking data calculated from the ICMP header+data, with value 0 for this field.
* ID - This field contains an ID value, should be returned in case of ECHO REPLY.
* Sequence - This field contains a sequence value, should be returned in case of ECHO REPLY.

Padding data

After the ICMP header follows padding data (in octets):
* The Linux "ping" utility pads ICMP to a total size of 64 in addition to the 8 octet header.
* Windows "ping.exe" pads to a total size of 40 in addition to the 8 octet header.

List of permitted control messages (incomplete list)

(Sources: [http://www.iana.org/assignments/icmp-parameters IANA ICMP Parameters] [http://freebie.fatpipe.org/~mjb/Drawings/UDP_ICMP_Headers.png] and "Computer Networking - A Top-Down Approach" by Kurose and Ross)

ee also

* PMTUD
* ICMPv6
* IRDP
* Smurf attack
* TCP
* ping
* traceroute
* ICMP Clock Synchronization
* ICMP tunnel

References

External links

* RFC 792, "Internet Control Message Protocol"
* [http://www.eventhelix.com/RealtimeMantra/Networking/Icmp.pdf ICMP Sequence Diagram]
* RFC 1122, "Requirements for Internet Hosts -- Communication Layers"
* RFC 1716, "Requirements routers"
* [http://www.daemon.be/maarten/icmpfilter.html Filtering ICMP on firewalls]
* [http://www.iana.org/assignments/icmp-parameters IANA]


Wikimedia Foundation. 2010.

Игры ⚽ Нужен реферат?

Look at other dictionaries:

  • Internet control message protocol — Pile de protocoles 7 • Application 6 • Présentation 5 • Session 4 • …   Wikipédia en Français

  • Internet Control Message Protocol — (ICMP) Familia: Familia de protocolos de Internet Función: Control y notificación de errores del Protocolo de Internet Ubicación en la pila de protocolos Transporte ICMP …   Wikipedia Español

  • Internet Control Message Protocol — Internet Control Message Protocol,   ICMP …   Universal-Lexikon

  • Internet Control Message Protocol V6 — ICMPv6 (Internet Control Message Protocol Version 6) Familie: Internetprotokollfamilie Einsatzgebiet: Obligatorischer Zusatz zu IPv6, Fehlermeldungen, Diagnose, Autoconfiguration, Routing Internet Protokolle im TCP/IP Protokollstapel Internet… …   Deutsch Wikipedia

  • Internet Control Message Protocol — Pile de protocoles 7.  Application 6.  Présentation 5.  Session 4.  Tr …   Wikipédia en Français

  • Internet Control Message Protocol V6 — L’ICMP pour IPv6 (Internet Control Message Protocol Version 6) fait partie à part entière de l architecture IPv6 et doit être complètement supportée par toutes les implémentations d IPv6. ICMPv6 combine des fonctions antérieurement subdivisées à… …   Wikipédia en Français

  • Internet Control Message Protocol — ICMP (Internet Control Message Protocol) Familie: Internetprotokollfamilie Einsatzgebiet: Obligatorischer Zusatz zum Internet Protocol, Fehlermeldungen, Diagnose ICMP im TCP/IP‑Protokollstapel Internet ICMP IPv4 …   Deutsch Wikipedia

  • Internet Control Message Protocol — protocol used to send control messages and error messages during the transmission of IP type data packets, ICMP …   English contemporary dictionary

  • Internet Control Message Protocol —    Abbreviated ICMP. An error reporting protocol that works with Internet Protocol (IP) and provides the functions used for networklayer management and control. Routers send ICMP messages to respond to undeliverable datagrams by placing an ICMP… …   Dictionary of networking

  • Internet Control Message Protocol — El Protocolo de Control de Mensajes de Internet (ICMP por sus siglas en inglés) es uno de los protocolos centrales de la suite de protocolos de Internet. Es usado principalmente por los Sistemas operativos de las computadoras en una red para… …   Enciclopedia Universal

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”