Cap. 3 (Commer) 3.1 Introduccion Reunir distintas tecnologias de red dentro de un todo coordinado. Esquema que esconde los detalles del hardware subyacentes de red a la vez que proporciona servicios universales de comunicacion. La interconexion trata de ocultar detalles de la red. Enfoques de Interconectividad: Nivel Aplicación Nivel red Nivel Red en Internet Provee transportación mejor-esfuerzo para transmitir datagramas (paquetes) de la fuente al destino. La fuente y el destino puede estar en la misma red o en diferentes redes. Environment (Medio Ambiente): Aplicación Aplicación Presentación Red: re-dirección Actualizacion de Tablas Presentación Sesión Transporte Enlace Datos Red: Físico re-dirección Enlace Datos Físico Red: re-dirección Actualizacion de Tablas Enlace Datos Físico Red: re-dirección Actualizacion de Tablas Enlace Datos Físico Red: re-dirección Actualizacion de Tablas Sesión Transporte Red: re-dirección Enlace Datos Enlace Datos Físico Físico Red: re-dirección Actualizacion de Tablas Enlace Datos Físico Nivel Red en Internet A nivel red Internet es una colección de subredes, conocidos como sistemas autónomos (AS de sus siglas en inglés) conectados. El cemento que une estas redes es el nivel red (IP internetwork Protocol). Environment Líneas trasatlánticas rentadas Backbone de ASIA Backbone de USA Red Regional Red Universitaria Líneas trasatlánticas rentadas Red Regional Red Local Backbone de Europa Red Nacional Red de una Companía Cap. 4 (Forouzan) IP Addressing: La dirección IP tiene 32 bits de longitud escritos como 4 octetos. Dos dispositivo NUNCA pueden tener la misma dirección IP, pero un dispositivo puede tener MAS de una dirección IP (multihomed device). La dirección IP representa localizaciones, NO nombres de dispositivos. La dirección IP tiene dos partes: netid y hostid. Una dirección IP se expresa como 4 conjuntos de 8 bits separados por un “.”. 11000000.00000101.00100010.00001011 Por facilidad, se utiliza la notación “dotted-decimal” para expresar la dirección 192.5.34.11 Direccionamiento en IP Clase A (8,24): 256 redes y 224 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 0 Red Host Rango de Direcc. de los hosts. 1.0.0.0 a 127.255.255.255 Clase B (16,16): 32,527 redes y 32,527 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 128.0.0.0 a 1 0 Red Host 191.255.255.255 Clase C (24,8): 224 redes y 256 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 1 0 Red Host 192.0.0.0 a 223.255.255.255 Clase D (4,28) 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 1 1 0 Dirección "Mulicast" 224.0.0.0 a 239.255.255.255 Clase E (4,28) 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 1 1 1 Reserv eed 240.0.0.0 a 255.255.255.255 Sample Internet 129.8.0.1 129.8.45.13 220.3.6.3 129.8.0.0 222.13.16.40 220.3.6.0 220.3.6.23 222.13.16.41 G G 222.13.16.0 220.3.6.1 x.y.z.t R 207.42.56.2 To the rest of the internet R 124.0.0.0 124.100.33.77 124.42.5.45 124.4.51.66 Number of Networks and hosts in each class Class Number of Networks Number of Hosts A 2 7 2 126 224 2 16,777,214 B 214 16,384 216 2 65,534 C 221 2,097,152 2 8 2 254 D E No aplica (direcciones especiales) No aplica(reservadas) Direcciones Especiales Special Address Netid Hostid Comment Network address Specific All 0’s Network itself is considered an entity with an IP address. Direct Broadcast address. Specific All 1’s It used by a router to send a packet to all hosts in a specific network. Limited Broadcast address. All 1’s All 1’s A host which wants to send a packet to every other host in the current network. (Actually a class E address). The router block this packet to confine the broadcasting to the local network. This Host on this network All 0’s All 0’s Used by a host at bootstrap time when it does not know its IP address. At this time, the host send this address as source address and a limited Broadcast addr. as destination address. (Actually a class A address) Specific host on this network All 0’s Specific It used by a host to send a packet to a another host on the same network. (Actually a class A address) Loopback address 127 Any It used by a host to send a packet to itself. (Actually a class A address). Used to test software. Direcciones Multicast por Categoría Address Group 224.0.0.0 Reserved 224.0.0.1 All SYSTEMS on this SUBNET. 224.0.0.2 All Routers on this SUBNET. 224.0.0.4 DVPRM ROUTERS 224.0.0.5 OSPFIGP all ROUTERS 224.0.0.6 OSPFIGP Designeted ROUTERS 224.0.0.7 ST Routers 224.0.0.8 ST Hosts 224.0.0.9 RIP2 Routers 224.0.0.10 IGRP Routers 224.0.0.11 Mobile-Agents Direcciones Multicast para Conferencia Address Group 224.0.1.7 AUDIONEWS 224.0.1.10 IETF-1-LOW-AUDIO 224.0.1.11 IETF-1-AUDIO 224.0.1.12 IETF-1-VIDEO 224.0.1.13 IETF-2-LOW-AUDIO 224.0.1.14 IETF-2-AUDIO 224.0.1.15 IETF-2-VIDEO 224.0.1.16 MUSIC-SERVICE 224.0.1.17 SEANET-TELEMETRY 224.0.1.18 SEANET-IMAGE Private Networks Issues: 1. 2. Apply for a unique address and use it without being connected to internet. 1. Advantage: Future Integration to internet without hassle. 2. Disadvantage: Almost imposible to obtain a class A o B addresses these days.. Use any class address without registering it with the internet authorities. Advantage: They can be used without permission. Disadvantage: The address does not have to be unique. (Confusion). Solution: Internet authorities have reserved a block of addresses: Advantage: They can be used without permission. veryboy know that these addresses are for private networks. They are unique inside of the organization. Number of Networks and hosts in each class Class Number of Networks Total A 10.0.0 1 B 172.16 to 172.31 16 C 192.68.0 to 192.68.255 256 Exercises: Identify the class of the following IP address: 4.5.6.7 A. class A B. class C Identify the class of the following IP address: 191.1.2.3 A. class A B. B. class B D. Class D class C B. class B D. Class Identify the class of the following IP address: 169.5.0.0 A. class A B. class C B. class B D. Class D Exercises: Identify the class of the following IP address: 241.1.2.3 A. class A. B. C. class What of the following is a source IP address: A. B. B. class B. D. Class This host on this network. Loopback address B. limited broadcast address. D. specific host on this network. Using the limited broadcast address, a ______ sends a packet to ______ on the network: A. host; all other hosts. B. router; all other routers. B. host; a specific host D. host; itself Exercises : What destination address can be used to send a packet from a host with IP address 188.1.1.1 to all hosts on the network. A. B. 188.0.0.0 255.255.255.255 B. 0.0.0.0 D. b and c. A host with address 142.5.0.1 needs to test internal software. What is the destination address in the packet: A. 127.0.0.0 B. 127.1.1.1 B. 127.127.127.127 D. all the above A packet send form a node with IP address 198.123.46.20 to all nodes on network 198.123.46.0 requires a _____address. A. unicast B. multicast B. broadcast D. a or b Exercise 1: Find 7 errors 129.8.0.1 129.8.45.13 220.3.6.3 129.8.0.0 222.13.16.40 220.3.0.0 220.3.6.23 G G 222.13.16.0 220.3.6.1 R x.y.z.t 207.42.56.1 206.42.56.2 To the rest of the internet R 124.0.0.1 124.100.33.77 124.255.255.255 124.4.51.66 Cap. 5 (Forouzan) Subnetting and Supernetting IP addressing works with two levels of hierachy (netid, hostid), when the two levels of hierachy are not enough, then we can use either: Subnetting: Network is divided into several smaller subnetworks with each subnetwork having its own subnetwork address. The rest of the Internet is not aware of the change. The router knows how to route packets in the subnet. Supernettting: Class C address are stil available. Combination of several class C addresses to create a larger range of addresses. The rest of the Internet is not aware of the change. Subnet: Class B Subnet b a l3 l1 l6 d l2 l4 e c l5 B A l1 R1 Rest of Internet Subnet l 3 l6 D l2 l4 C Subnet b a l3 l1 l6 d l2 l4 c l5 G F l5 l7 E Subnet (Subred) Example: Clase B (16,6,10): 32,527 redes, 62 subredes y 1,024 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 0 Red Subred Host Clase B (16,10,6): 32,527 redes, 1024 subredes y 64 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 0 Red Subred Host Rango de Direcc. de los hosts. 128.0.0.0 a 191.255.255.255 Rango de Direcc. de los hosts. 128.0.0.0 a 191.255.255.255 Masking Operation to obtain the subnettwork address from an IP address. Mask: 32-bit number, diviedn in two parts: The bits in the mask containing 1s defines the netid or combination of netid and subnetid. The part of the 0s define the hostid To get the subnet address, the router applys the bit-wise-and operation on the IP address and the mask. Ejemplo: Si se pidieron prestados 8 bits al campo del “host”, entonces la máscara seria: 255.255.255.0 Special Address in Subnetting Special Address Netid Hostid Comment Subnetwork address Specific All 0’s Subnetwork itself is considered an entity with an IP address. Direct Broadcast address. Specific All 1’s It used by a router to send a packet to all hosts in a specific subnetwork. Limited Broadcast address. All 1’s All 1’s A host which wants to send a packet to every other host in the current subnetwork. (Actually a class E address). The router block this packet to confine the broadcasting to the local subnetwork. This Host on this subnetwork All 0’s All 0’s Used by a host at bootstrap time when it does not know its IP address. At this time, the host send this address as source address and a limited Broadcast addr. as destination address. (Actually a class A address) Specific host on this subnetwork All 0’s Specific It used by a host to send a packet to a another host on the same subnetwork. (Actually a class A address) Loopback address 127 Any It used by a host to send a packet to itself. (Actually a class A address). Used to test software. Example: 11000000.00000101.00100010.00001011 192.5.34.11 Mask: 255.255.255.0 Result: 192.5.34.0 Subnet: Supernet Class C b a l3 l1 l6 d l2 l4 e c l5 B A l1 R1 Rest of Internet Class C l 3 l6 D l2 l4 C Class C b a l3 l1 l6 d l2 l4 c l5 G F l5 l7 E Subnets Example: Class C (22,2,8): 222 nets, 4 supernets y 256 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 1 0 Red SN Host 192.0.0.0 a 223.255.255.255 Clase C (20,4,8): 220 nets, 16 supernet y 256 hosts. 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 1 1 0 Red Super Host 192.0.0.0 a 223.255.255.255 Masking Operation to obtain the subnettwork address from an IP address. Mask: 32-bit number, divied in two parts: The bits in the mask containing 1s defines the supernetid. The part of the 0s define the hostid. To get the supernet address, the router applys the bit-wise-and operation on the IP address and the mask. Ejemplo: Si se pidieron prestados 2 bits al campo del “host”, entonces la máscara seria: 255.255.252.0 Example: 11000000.00000101.00100010.00001011 192.5.34.11 Mask: 255.255.252.0 Supernet: 192.5.32.0 Sample Internet 134.18.0.0 255.255.248.0 129.8.0.0 255.255.192.0 129.8.64.2 129.8.127.254 220.3.6.0 129.8.128.2 129.8.181.246 255.255.255.248 129.8.128.0 129.8.64.0 220.3.6.10 220.3.6.8 220.3.6.14 129.8.64.1 129.8.128.1 220.3.6.9 G 222.13.16.40 222.13.16.0 220.3.6.241 255.255.0.0 220.3.6.242 134. R x.y.z.t 220.3.6.16 G 222.13.16.41 To the rest of the internet 220.3.6.246 207.42.56.2 R 124.100.33.77 124.0.0.0 255.224.0.0 124. 124. 124. 124. 124. 124. 124. 124. 124. Exercises : In Fig. 5.2, what is the mask for the network. A. 255.255.0.0 B. 0.0.255.255 A device has the IP address 190.1.2.3. What is the subnetid? A. 1 B. 3 C. 255.255.255.0 D. none of the above C. 2 D. insufficient information to answer. Which of the followng is the defaul mask for the address: 98.0.46.201? A. 255.0.0.0 B. 255.255.255.0 C. 255.255.0.0 D. 255.255.255.255 Exercises: What class of IP address does the subnet mask 255.255.128.0 operate on? C. class B. D. class A,B or C. A. class A. B. class C The subenet mask for a class C network is 255.255.255.192. How many subnetworks are available? (Disregard special address): A. B. 2 8 C. 4 D. 192 A supernet mask is 255.255.248.0. How many class C networks were combined to make this supernet: A. B. 2 6 C. 4 D. 8 Cap. 7 (Forouzan) IP datagram 0 8 Ver HLEN 16 Service Type TOS P R E Identification Time to Live=#Hops 24 31 Total_Length=header+Data_length Flags Protocol(TCP, UDP...) Fragmentation Offset Header Checksum Source IP address Destination IP address Option (0-40 bytes) Data Types of Service TOS bits Description 0000 Normal (Default) 0001 Minimize Cost 0010 0100 1000 Maximize reliability Maximize Throughput Minimize Delay Default TOS Protocol TOS bits Description ICMP 0000 Normal IGP 0010 Maximize Reliability SNMP 0010 Maximize Reliability TELNET 1000 Minimize Delay FTP (data) 0100 Maximize Throughput FTP (control) 1000 Minimize Delay SMTP (data) 0100 Maximize Throughput SMTP (control) 1000 Minimize Delay IP datagram: Fragmentation Control bits 0 8 16 24 Ver HLEN Service Type Flags Identification Time to Live Total Length TOS P R E Fragmentation Offset D M Protocol Header Checksum Source IP address Destination IP address Option Data 31 Figure 7-7 Figure 7-8 IP datagram: Options 0 8 Ver HLEN 16 Total Length Service Type Identification Time to Live 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Code Cp Css Number Length (code+length+Hdata) Data HData 31 Record Route Option 0 8 Ver HLEN 16 Total Length Service Type Identification Time to Live 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Code 0 00 00111 Pointer Length IP addresses Data 31 Figure 7-14 Strict Source Route Option 0 8 Ver HLEN 16 Total Length Service Type Identification Time to Live 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Code 1 00 01001 Pointer Length IP addresses Data 31 Figure 7-16 Loose Source Route Option 0 8 Ver HLEN 16 Total Length Service Type Identification Time to Live 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Code 1 00 00011 Pointer Length IP addresses Data 31 Timestamp Option 0 8 Ver HLEN 16 Time to Live Total Length Service Type Identification 31 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Code 0 10 00100 Length Pointer O-Flow Flags IP addresses and timestamp to be stored Data Figure 7-19 Figure 7-20 Checksum 0 8 Ver HLEN 16 Service Type Total Length TOS P R E Identification Time to Live 24 Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Option Data 31 Figure 7-23 Fragmentation Useful when a datagram travel through different networks. MTU (Maximum Transfer Unit) is the maximum length of data that can be encapsulated in a frame. If a datagram is fragmented is fragment, it becomes to be a new datagram. When a datagram is fragmented, requires part of the header to be copied by all fragments. MTUs for Different Networks Protocol MTU Hyperchannel 65,535 Token Ring (16 Mbps) 17,914 Token Ring (4 Mbps) 4,464 FDDI X.25 PPP 4,532 576 296 No fragmentation needed. IP Datagram Header MTU Trailer No fragmentation needed. IP Datagram H MTU T H MTU T H MTU T H H MTU T H T MTU T When a host or router process a frame 0 8 31 16 24 Ver HLEN Service Type Identification Time to Live Total Length Flags Protocol Fragmentation Offset Header Checksum Source IP address Destination IP address Option Data Figure 7-24 Figure 7-25 Figure 7-26 Cap. 6 Forouzan Servicios Servicio Orientado a Conexión Servicio con Confirmación Servicio sin Confirmación X.25 TCP, Ethernet, Frame Relay Ethernet UDP, IP, Ethernet Conexión Datos Desconexión Servicio NO Orientado a Conexión Direct vs. Indirect Delivery Routing Methods Static vs. Dynamic Routing Static Routing: The administrator enter the route for each destination into the table manually. Not updated automatically. Used in small networks that do not change frequently. Dynamic Routing: Updated periodically using Dynamic Routing Protocols: RIP, OSPF, BGP Routing Module Routing Table Receive: an IP packet 1. For each entry in the routing table 1. 2. Apply the mask to packet destination address If (the mask matches the value in the destination field) 1. If (the G flag is absent) 1. 2. 3. 2. 3. Use packet destination address as next hop address Send packet to fragmentation module with next hop address Return If no match is found, send an ICMP error message. Return. Example: Routing table for router R1 Mask Destination Next Hop F. R.C. U. I. 255.0.0.0 111.0.0.0 - U 0 0 m0 255.255.255.224 193.14.5.160 - U 0 0 m2 255.255.255.224 194.17.21.192 - U 0 0 m1 255.255.255.255 194.17.21.16 111.20.18.14 UGH 0 0 m0 255.255.255.0 192.16.7.0 111.15.17.32 UG 0 0 m0 255.255.255.0 194.17.21.0 111.20.18.14 UG 0 0 m0 0.0.0.0 0.0.0.0 111.30.31.18 UG 0 0 m0 …………… When R1 receives a packet for destination: 192.16.7.14 Mask Destination Address Hop ANDNext Mask Match? F. R.C. U. I. 255.0.0.0 111.0.0.0 192.0.0.0 NoU 0 0 m0 255.255.255.224 193.14.5.160 192.16.7.0 NoU 0 0 m2 255.255.255.224 194.17.21.192 192.16.7.0 - NoU 0 0 m1 …………… 192.16.7.14 255.255.255.255 194.17.21.16 111.20.18.14 NoUGH 192.16.17.14 0 0 m0 255.255.255.0 192.16.7.0 111.15.17.32 Match!! UG 192.16.17.0 1 1 m0 255.255.255.0 194.17.21.0 111.20.18.14 UG 0 0 m0 0.0.0.0 0.0.0.0 111.30.31.18 UG 0 0 m0 Increase by 1, if other packet with the same destination reach this router. When R1 receives a packet for destination: 193.14.5.176 Mask Address AND Destination MaskNext Hop 193.0.0.0 - Match ? F. R.C. U. I. NoU 0 0 m0 Match! U 1 1 m2 255.0.0.0 111.0.0.0 255.255.255.224 193.14.5.160 193.14.15.160 - 255.255.255.224 194.17.21.192 - U 0 0 m1 255.255.255.255 194.17.21.16 111.20.18.14 UGH 0 0 m0 255.255.255.0 192.16.7.0 111.15.17.32 UG 0 0 m0 255.255.255.0 194.17.21.0 111.20.18.14 UG 0 0 m0 0.0.0.0 0.0.0.0 111.30.31.18 UG 0 0 m0 …………… 193.14.5.176 Increase by 1, if other packet with the same destination reach this router. When R1 receives a packet for destination: 200.34.12.34 Mask Destination Address Hop ANDNext Mask Match? F. R.C. U. I. 255.0.0.0 111.0.0.0 200.0.0.0 NoU 0 0 m0 255.255.255.224 193.14.5.160 200.34.12.32 NoU 0 0 m2 255.255.255.224 194.17.21.192 200.34.12.32 - NoU 0 0 m1 …………… 200.34.12.34 255.255.255.255 194.17.21.16 111.20.18.14 NoUGH 200.34.12.34 0 0 m0 255.255.255.0 192.16.7.0 111.15.17.32 NoUG 200.34.12.0 0 0 m0 255.255.255.0 194.17.21.0 111.20.18.14 NoUG 200.34.12.0 0 0 m0 0.0.0.0 0.0.0.0 111.30.31.18 Match! UG 0.0.0.0 1 1 m0 Increase by 1, if other packet with the same destination reach this router. Chapter 8 ARP and RARP Static vs. Dynamic Mapping Static Table Static Table ARP (Address Resolution Protocol) ARP (Address Resolution Protocol) NL-1: Sender knows the IP address of the target. NL-2: IP ask ARP to create a request ARP message. DLL: encapsulated using broadcast address in the destination field. NL-1: Recives the destination phyisical address NL-1: recognise the IP address. NL-2: IP ask ARP to create a reply ARP message with its physical address. DLL: encapsulated using unicast address in the destination field. ARP packet (i.e. IPv4=0800H) (i.e. Ethernet=1) (Physical Address Length) (Logical Address Length) Encapsulation in an Ethernet frame Figure 8-5, Part I Figure 8-5, Part II Proxy ARP Figure 8-7 RRQ (if I am not the destination, only updates table) RRQ/srp Sleep IP_RE (if solved in the cache) IP_RE/srq Pending RRP (updates the cache table) Original Cache Table used for the examples State Queue Attempt Time-out 900 Protocol Address R 5 P 2 2 129.34.4.8 P 14 5 201.11.56.7 R 8 P 12 450 1 180.3.6.1 114.5.7.89 Hardware Address ACAE32457342 457342ACAE32 220.55.5.7 F R 9 P 18 60 3 19.1.7.82 188.11.8.71 4573E3242ACA Example: ARP output module receive and IP datagram with address: 114.15.7.89 State Queue Attempt Time-out Protocol Address R 5 900 P 2 2 129.34.4.8 P 14 5 201.11.56.7 R 8 P 12 450 1 180.3.6.1 114.5.7.89 Hardware Address ACAE32457342 457342ACAE32 220.55.5.7 F R 9 P 18 60 3 19.1.7.82 188.11.8.71 4573E3242ACA Example: ARP output module receive and IP datagram with address: 116.1.7.22 State Queue Attempt Time-out Protocol Address R 5 900 P 2 2 129.34.4.8 P 14 5 201.11.56.7 R 8 P 12 1 220.55.5.7 P 23 1 116.1.7.22 450 180.3.6.1 114.5.7.89 Hardware Address ACAE32457342 457342ACAE32 F R 9 P 18 60 3 19.1.7.82 188.11.8.71 4573E3242ACA Example: ARP input module receive and IP datagram with address: 188.11.8.71 and Hardware Address: E34573242ACA State Queue Attempt Time-out Protocol Address R 5 900 P 2 2 129.34.4.8 P 14 5 201.11.56.7 R 8 P 12 1 220.55.5.7 P 23 1 116.1.7.22 450 180.3.6.1 114.5.7.89 Hardware Address ACAE32457342 457342ACAE32 F R 9 60 19.1.7.82 4573E3242ACA R 18 900 188.11.8.71 E34573242ACA Example: The cache-control updates every entry. The time-out values is decremented by 60. State Queue R 5 P 2 Attempt Time-out Protocol Address 840 3 180.3.6.1 Hardware Address ACAE32457342 129.34.4.8 F 201.11.56.7 R 8 390 114.5.7.89 P 12 2 220.55.5.7 P 23 2 116.1.7.22 457342ACAE32 F F R 18 840 188.11.8.71 E34573242ACA RARP Why RARP? RARP RARP Packet (i.e. IPv4=0800H) (i.e. Ethernet=1) (Physical Address Length) (Logical Address Length) RARP in an Ethernet Frame 1. 2. 3. 4. In a _______ protocol associates a logical address with a phyisical address. A. Static mapping C. physical mapping B. Dynamic mapping D. a and b The _______ is a dynamic mapping protocol in which a logical address is found for a given physical address. A. ARP C. ICMP B. RARP D. none of the above A router reads the _______ address on a packet to determine the next hop? 1. Logical C. Source 2. Physical D. ARP A ARP reply is_______ to _______. 1. broadcast;all hosts C. unicast; all hosts 2. multicast; all hosts D. unicast; one host Chapter 9 Internet Control Message Protocol (ICMP) ICMP (Internet Control Message Protocol) Internet does not have Error Control mechanism Flow Control mechanism Assistant Mechanism ICMP compensate this two problems. ICMP Position in the network layer. ICMP encapsulation ICMP Format Types of Messages Type Message Type Message 3 Destination Unreachable 8 or 0 Echo request or reply 4 Source quench (“flow Control”) 13 or 14 Timestamp request or reply 11 Time exceeded 17 or 18 Address mask request or reply 12 Parameter Problem 10 or 9 5 Redirection Router solicitation and advertisement Types of Error Report Messages Contents of data-field for the error message Destination Unreachable 0 Nework Unreachable 8 Source Host isolated 1 Host Unreachable 9 Destination network prohibited. 2 Protocol Unreachable 10 Destination host prohibited 3 Port Unreachable 11 Network unreachable for the requested TOS. 4 Fragmentation required 12 Host unreachable for the requested TOS 5 Source Routing can’t be accomplished. 13 Destination host filtered out. 6 Destination Network Unknown 14 Host precedence violated. 7 Destination host Unknown 15 IP precedence lower the network precedence level. Source quenche (“flow control”) A message is send for every datagram is discarded by a router or the destination host. Time Exceeded 0 Number of hops exceeded 1 Final destination does not receive all the fragments. Parameter Problem 0 1 Error or ambiguity in one of the header fields Required part of an option I missed. Redirection A host usually start with a small routing table that is gradually augmented and updated. One of the tools to accomplish this is the redirection message. Format 0 Redirection for the network-specific route. 1 Redirection for host-specific route. 2 Redirection for network-specific route based on the specified TOS. 3 Redirection for the host-specific route based on the specified TOS. Types of Query Messages Used to diagnose some network problems. Echo Request and Reply For diagnostic purposes. Test if there is communication at the IP level. an intermediate router is receiving, processing and forwarding packets. another host is reachable (ping-packet internet groper). The identification and sequence number field are not formally defined, and can be used arbitrarily by the sender. Timestamp Request and Reply Used for: Round-trip time Sincronize clocks Round-trip calculation t Original tReceive t Transmit dSending tReceive t Original dReceiving t Returned tTransmit tRoundTrip dSending dReceiving Example: t Original 46 t Receive 59 t Transmit 60 t Returned 67 dSending 59 46 13 dReceiving 67 60 7 t RoundTrip 13 7 20 Syncronize Clocks t Original tReceive t Transmit dSending t Received (tOriginal done way ) done way t RoundTrip 2 Example: t Original 46 t Receive 59 t Transmit 60 t Returned 67 dSending 59 46 13 dReceiving 67 60 7 t RoundTrip 13 7 20 dt 59 (46 20/2) 3 Address Mask Request and Reply To identify network address, subnetwork address and host identifier. Router Solicitation and Advertisement In order that host knows the router connected to its network. The host should know if the router is alive. Router Solicitation and Advertisement Solicitatio n Advertisme nt Advertisme nt Advertisme nt Format Solicitation: Advertisement: Checksum Figure 9-20 1. 2. 3. 4. 5. If a host needs to syncronise its clock with another host, it sends a _____ message. A. B. timestamp-request C. router-advertisement Source-quenche D. time-exceeded The purpose of the echo request and echo reply is to _______. A. B. C. D. Report errors Check node-to-node communication Check packet lifetime Find IP address. Which field is always present in a ICMP package? A. B. Type Code C. Checksum D. all the above When the hop-count field reaches zero and the destination has not been reached, a ______ error message is sent? A. B. Destination address Time-excedeed C. Parameter problem D. redirection Error in the header or option field of an IP datagram require a _____ error message. A. B. Parameter-problem C. router-solicitation Source-quenche D. redirection 6. 7. 8. 9. The _____ packet contains information about a router. A. B. Router-solicitation C. router-advertisement Router-Information D. router-reply. Who can send ICMP error-reporting messages? A. B. Routers Destination hosts C. Source hosts D. a and b A time-exceeded message is generated if ______? A. B. C. D. The round-trip time is close to zero. The time-to-live field has a zero value. Fragments of a message do not arrive within a set time b and c In calculating the time difference between two clocks, a negative value indicates _______. 1. 2. 3. 4. An invalid calculation. The source clock lags behind the destination clock. The destination clock lags behind the source clock. The one-way time has been miscalculated.