ICMP
DHCP
NAT
Computer Networks and Security
Chapter 4 - Network layer (part 3): Network control and Address
Management
Florence Perronnin
UniversiteĢ Joseph Fourier, LIG Laboratory
December 10, 2009
Perronnin (UJF)
IP Addressing
December 10, 2009
1 / 21
ICMP
DHCP
NAT
ICMP Protocol
Ping and Traceroute
Outline
1
ICMP
ICMP Protocol
Ping and Traceroute
2 DHCP
3 NAT
Perronnin (UJF)
IP Addressing
December 10, 2009
2 / 21
ICMP
DHCP
NAT
ICMP Protocol
Ping and Traceroute
ICMP
ICMP (Internet Control Message Protocol) is a layer 3 protocol (just
above IP) for network-level reporting [RFC 792]:
carries only network information (not for application message
transport)
error reporting (unreachable host/port/network)
query messages: echo request / echo reply (ping command)
Error messages are fixed-size datagrams (type, code and beginning of IP
packet header that triggered ICMP message). Query messages have a
variable format.
Perronnin (UJF)
IP Addressing
December 10, 2009
3 / 21
ICMP
DHCP
NAT
ICMP Protocol
Ping and Traceroute
ICMP Message Format
Type Code Checksum
Variable header field
ICMP Data
For error messages, data = IP
header + 64 bits original data
datagram.
Type
Description
Code Variable header field
8/0
Echo Request/Reply
0
Id + Seq N.
3
Destination Unreachable
0-5
unused
4
Source Quench
0
unused
5
Redirect
0/1
GW address
11
Time Exceeded
0/1
unused
12
Parameter Problem
Pointer
13/14 Timestamp / Reply
0
Id + Seq N.
15/16
Information Req./Reply
0
Id + Seq N.
Perronnin (UJF)
IP Addressing
December 10, 2009
4 / 21
ICMP
DHCP
NAT
ICMP Protocol
Ping and Traceroute
ICMP example: Ping
Ping
The ping program sends and ICMP Echo request (type 8 code 0). The
destination sends back and ICMP Echo reply (type 0 code 0).
ping www.google.com
Time Source
Destination
Ptcl Info
1.52 129.88.69.94 129.88.30.10 DNS Standard query A
1.53 129.88.30.10 129.88.69.94 DNS Standard query response CNAME www.l.google.com A 74.125.43.147 A 74.125.43.99 A 74.125.
1.53 129.88.69.94 74.125.43.147 ICMP Echo (ping) request
1.56 74.125.43.147 129.88.69.94