tailieunhanh - Lecture TCP-IP protocol suite - Chapter 8: Internet Protocol (IP)

In this chapter students will be able to: Understand the format and fields of a datagram, understand the need for fragmentation and the fields involved, understand the options available in an IP datagram, be able to perform a checksum calculation, understand the components and interactions of an IP package. | Chapter 8 Internet Protocol (IP) CONTENTS DATAGRAM FRAGMENTATION OPTIONS CHECKSUM IP PACKAGE Figure 8-1 Position of IP in TCP/IP protocol suite DATAGRAM Figure 8-2 IP datagram Figure 8-3 Service Type or Differentiated Services The precedence subfield is not used in version 4. The total length field defines the total length of the datagram including the header. Figure 8-4 Encapsulation of a small datagram in an Ethernet frame Figure 8-5 Multiplexing Example 1 An IP packet has arrived with the first 8 bits as shown: 01000010 The receiver discards the packet. Why? Solution There is an error in this packet. The 4 left-most bits (0100) show the version, which is correct. The next 4 bits (0010) show the header length, which means (2 4 = 8), which is wrong. The minimum number of bytes in the header must be 20. The packet has been corrupted in transmission. Example 2 In an IP packet, the value of HLEN is 1000 in binary. How many bytes of options are being carried by this packet? . | Chapter 8 Internet Protocol (IP) CONTENTS DATAGRAM FRAGMENTATION OPTIONS CHECKSUM IP PACKAGE Figure 8-1 Position of IP in TCP/IP protocol suite DATAGRAM Figure 8-2 IP datagram Figure 8-3 Service Type or Differentiated Services The precedence subfield is not used in version 4. The total length field defines the total length of the datagram including the header. Figure 8-4 Encapsulation of a small datagram in an Ethernet frame Figure 8-5 Multiplexing Example 1 An IP packet has arrived with the first 8 bits as shown: 01000010 The receiver discards the packet. Why? Solution There is an error in this packet. The 4 left-most bits (0100) show the version, which is correct. The next 4 bits (0010) show the header length, which means (2 4 = 8), which is wrong. The minimum number of bytes in the header must be 20. The packet has been corrupted in transmission. Example 2 In an IP packet, the value of HLEN is 1000 in binary. How many bytes of options are being carried by this packet? Solution The HLEN value is 8, which means the total number of bytes in the header is 8 4 or 32 bytes. The first 20 bytes are the main header, the next 12 bytes are the options. Example 3 In an IP packet, the value of HLEN is 516 and the value of the total length field is 002816. How many bytes of data are being carried by this packet? Solution The HLEN value is 5, which means the total number of bytes in the header is 5 4 or 20 bytes (no options). The total length is 40 bytes, which means the packet is carrying 20 bytes of data (40-20). Example 4 An IP packet has arrived with the first few hexadecimal digits as shown below: 45000028000100000102. How many hops can this packet travel before being dropped? The data belong to what upper layer protocol? Solution To find the time-to-live field, we should skip 8 bytes (16 hexadecimal digits). The time-to-live field is the ninth byte, which is 01. This means the packet can travel only one hop. The protocol field is the .

crossorigin="anonymous">
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.