Main Page | See live article | Alphabetical index

Internet control message protocol

The Internet Control Message Protocol (ICMP) is part of the TCP-IP suite of protocols. ICMP messages are typically generated in response to errors in IP datagrams (as specified in RFC1122) or for diagnostic or routing purposes.

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 particular, ICMP messages should never be generated as a consequence of ICMP message processing, in order to prevent cascades of ICMP messages.

Many commonly used network utilities are based on ICMP messages. The ping utility (well known on Unix) is implemented using the ICMP "Echo" and "Echo reply" messages. The related traceroute command is implemented by transmitting UDP datagrams with manipulated IP Time-to-live (TTL) header fields and looking for ICMP "Time to live exceeded in transit" and "Destination unreachable" messages in response. Every machine (such as intermediate routers) that forwards an IP datagram has to decrement the TTL 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 does not guarantee delivery.

List of permitted control messages:
0 - Echo Reply
3 - Destination Unreachable
4 - Source Quench
5 - Redirect
8 - Echo Request
9 - Router Advertisement
10 - Router Solicitation
11 - Time Exceeded
12 - Parameter Problem
13 - Timestamp
14 - Timestamp Reply
15 - Information Request
16 - Information Reply
17 - Address Mask Request
18 - Address Mask Reply
19 - Reserved for security
20-29 - Reserved for robustness experiment
30 - Traceroute
31 - Datagram Conversion Error
32 - Mobile Host Redirect
33 - IPv6 Where-Are-You
34 - IPv6 Here-I-Am
35 - Mobile Registration Request
36 - Mobile Registration Reply
37 - Domain Name Request
38 - Domain Name Reply
39 - SKIP
40 - Photuris
41-255 - Reserved
(Please complete this list!)
(Source: IANA ICMP Parameters)

Further reading: RFC792