Sie sind auf Seite 1von 5

King Saud University

College of Computer and Information Sciences


Information Technology Department

First Semester 1436/1437


IT224: Networks 1
Sheet# 5 (chapter 20-21)

Multiple-Choice Questions
1. _____is a dynamic mapping protocol in which a physical address is found for a
given IP address.
a. ARP
b. RARP
c. ICMP
d. None of the above

2. A router reads the _______ address on a packet to determine the next hop.
a. IP
b. MAC
c. Source
d. ARP

3. An ARP replay is ________ to _______


a. Broadcast; all hosts
b. Multicast; one host
c. Unicast; all hosts
d. Unicast; one host

4. An ARP request is _______ to ________


a. Broadcast; all hosts
b. Multicast; one host
c. Unicast; all hosts
d. Unicast; one host

5. When the hop-count field reaches zero and the destination has not been reached, a
________ error message is sent.
a. Destination unreachable
b. Time-exceeded
c. Parameter-problem
d. Redirection

6. When not all fragments of a message have been received within the designated
amount of time, a ________ error message is sent.
a. Source-quench
b. Time-exceeded
c. Parameter-problem
d. Time-stamp-request

1
7. Errors in the header or option fields of an IP datagram require a _______ error
message.
a. Parameter-problem
b. Source-quench
c. Router-solicitation
d. Redirection

8. One method to alert a source host of congestion is the ________ message.


a. Redirection
b. Echo-request
c. Source-quench
d. Destination-unreachable

9. In __________, each packet of a message need not to follow the same path from
sender to receiver.
a. Message switching
b. the virtual approach to packet switching
c. the datagram approach to packet switching
d. none of the above

10. A best-effort delivery service such as IP does not include ________


a. Error checking
b. Error correction
c. Datagram acknowledgment
d. All the above

11. An HLEN value of decimal 10 means ________.


a. There is 10 bytes of options
b. There is 40 bytes of options
c. There is 10 bytes in the header
d. There is 40 bytes in the header

12. In IPv4, what is the value of the total length field in bytes if the header is 28 bytes
and the data field is 400 bytes?
a. 428
b. 407
c. 107
d. 427

13. A datagram is fragmented into three smaller datagrams. Which of the following is
true?
a. The do not fragment bit is set to 1 for all three datagrams.
b. the more fragment bit is set to 0 for all three datagrams.
c. The identification field is the same for all three datagrams.
d. The offset field is the same for all three datagrams.

14. If the fragment offset has a value of 100, it means that ________
a. The datagram has not been fragmented
b. The datagram is 100 bytes in size
c. The first byte of the datagram is byte 100

2
d. The first byte of the datagram is byte 800

15. What is needed to determine the number of the last byte of a fragment?
a. Identification number
b. Offset number
c. Total data length
d. (b) and (c)

3
Exercises:

1. Which fields of the IPv4 header change from router to router?

2. Calculate the HLEN (in IPv4) value if the total length is 1152 bytes, 1100 of
value is data from the upper layer. header length: 1152 - 1100 = 52 byte /4
=> HLEN = 52/4 = 13 (1101)
3. The value of HLEN in an IPv4 datagram is 15. How many option bytes are
present? header size = HLEN *4 = 15*4 = 60 byte
option bytes = 60 - 20 = 40 bytes
4. The size of the option field of an IPv4 datagram is 20 bytes. What is the value
of HLEN? What is the value in binary? Header size = 20+ size of the option field = 20 + 20 = 40
HLEN = 40 / 4 = 10 => binary = 1010
5. An lPv4 datagram is carrying 540 bytes of data. If there is no option
information. What is the value of the header length field? What is the value of
the total length field? HLEN = 20 /4 = 5 = 0101
Total length field = data length + header length = 540 + 5*4 = 560 bytes
6. An lPv4 fragment has arrived with an offset value of 480. How many bytes of
data were originally sent by the source before this fragment data?
number of the first byte in the datagram = 8* offset = 480 * 8 = 3840 / 3840 bytes of data sent before
7. In an lPv4 datagram, the M bit is 1; the value of HLEN is 5. The value of total
length is 250, and the offset value is 240. What is the number of the first byte
and number of the last byte in this datagram? Is this the last fragment, the first
fragment, or a middle fragment? first byte# = 240 * 8 = 1920 / last byte# = first byte + data size -1
data size = 250 - 20 = 230 bytes / last byte = 1920+230 -1 = 2149
8. An IPv4 datagram has arrived with the following information in the header ( in
hexadecimal):

0x45 00 00 68 00 09 32 30 17 11 F6 EB 7B 4E 53 02 A4 0E 08 02

0x4 0x5 0x00 0x00 68


0x00 09 0x32 30
0x17 0x11 F6EB
0x7B 4E 53 02
0xA4 0E 08 02

a) Are there any options? No / header size is only 20

b) Is the packet fragmented? Yes / flags and fragmentation field has a value

c) What is the size of the data? 68h = 104 d / 104-20 = 84 bytes

d) How many more routers can the packet travel to? 17h = 23d routers

e) What is the identification number of the packet? 9h = 9 in decimal

4
9. Suppose a router receives an IP packet containing 4180 bytes of data and ID 2231;
it has to forward the packet to a network with maximum transmission unit of 1500
bytes. Assume that the IP header is 20 byte long. Show the fragments that router
creates and specify the values in each fragment header.
total length | Data length | ID | D | M | fragment offset
original packet 4200 4180 2231 0 0 0
fragment 1 1500 1480 2231 0 1 0
fragment 2 1500 1480 2231 0 1 1480/8 = 185
fragment 3 1240 1220 2231 0 0 2960/8 = 370

Das könnte Ihnen auch gefallen