|
Access:
» ICMP use and abuseRelated categories: Security | Networks | Firewalls Antonio MerolaViewed: 12574 | Article date: 2006-04-24 14:41:53 We describe how to use ICMP protocol and how it can be used by intruders for evil purposes. We present all ICMP protocols, their meaning and ways in which can be used. We explain how to configurate firewall to protect our system against attacks.
ICMP is often regarded as a very innocent, harmless protocol. However, if not properly handled by the operating system or a firewall, it can be used by intruders for evil purposes.
About the authorAntonio Merola works as a senior security expert for Telecom Italia. During his professional career, he has been involved in many aspects of security. As a freelancer he serves several companies as a consultant and instructor on a wide variety of security topics. He has published IT articles in several Italian magazines. His recent interests include honeypots and IDS/IPS security solutions. ICMP stands for Internet Control Message Protocol. It's in charge of delivering messages about non-transient error conditions. RFC specification and ICMP features are outlined in RFC 792. Table 1 contains a list of RFC documents concerning ICMP. ICMP is used for example when a host receives a UDP request on a non-listening port, or when IP fragmentation is required and the DF bit is set (see Frame IP Fragmentation and ICMP). It is involved in reporting error conditions and querying the network.
What you will learn...
What you should know...
While ICMP is encapsulated in IP datagrams like transport protocols such as TCP or UDP (OSI layer 4), it is a network-layer protocol (OSI layer 3) like the IP protocol itself. ICMP is an integral part of IP, does not use a client-server scheme or port numbers, can be broadcasted and gives no guarantees about the delivery of a message. The most important data in the ICMP protocol are message type and message code for the specified message type. These two numbers are included in the first two bytes of the ICMP header (see Figure 1). Table 2 defines various ICMP types and codes.
IP fragmentation and ICMPIP datagrams are encapsulated in frames, the size of a datagram is restricted due to the limit of every transmission media, this size is known as MTU (Maximum Transmission Unit) and if it is greater than this limit, then it must be fragmented. An IP datagram can be prevented from fragmentation, by setting the DF - Don't Fragment flag in the IP header. If a router receives a packet too large for it to forward, packet is just fragmented and passed through, while if the DF bit is set the packet is dropped and an ICMP type 3 (destination unreachable), code 4 (fragmentation needed but don't-fragment bit set) is returned back to the sender. This tells the sender host that it needs to reduce the size of its packets in order to get through; the MTU of the next hop is included in the ICMP message so the sender knows how big packets can be. Table 1. ICMP-related RFC documents
Figure 1. ICMP message format Table 2. ICMP types and codes
|
|
Copyright C 2006 by Software Developer's Journal. All rights reserved.






SDJ Users:
hakin9 StarterKit IT Practical Solutions for Newbies










