A packet is the basic unit of data transmission in a network.
It consists of three main parts: the header, payload, and trailer.
- Header
- Destination Address: The network address of the target device.
- Source Address: The network address of the sending device.
- Protocol Information: Indicates which protocol is used (e.g., TCP or UDP).
- Length: Specifies the size of the packet.
- Other Control Info: Includes sequencing, fragmentation indicators, etc.
- Error Checking: Typically includes a *checksum to verify data integrity.
- Payload (Data):
- The actual content or data being transmitted.
- Trailer:
- Additional error-checking information, often a duplicate checksum for integrity verification.
Network devices use this packet structure to efficiently transmit and process data:
- They inspect the header to determine the destination and appropriate protocol.
- Based on this information, they can route or filter the packet as needed.
- The trailer allows them to validate that the packet arrived intact and without corruption.
*Checksum by Location
1. Checksum in the Header:
- IP Header Checksum: The IPv4 header includes a checksum field. It verifies errors by calculating the checksum over the entire IP header. This field was removed in IPv6.
- TCP/UDP Header Checksum: The TCP and UDP protocols also include checksums, which are calculated over both the header and the data (payload).
2. Checksum in the Trailer:
- Frame Check Sequence (FCS): At the data link layer (e.g., Ethernet frames), a checksum may be placed in the frame trailer in the form of an FCS. This is used to detect any errors across the entire frame.
Summary
- Header-included: TCP and UDP protocols include checksums in their headers.
- Trailer-included: At the data link layer, checksums may be located in the trailer (FCS) to verify the frame.
The location of the checksum varies by protocol and layer, but it is generally placed in either the header or trailer to detect transmission errors.
'Computer Science > Network' 카테고리의 다른 글
PDU (0) | 2025.07.25 |
---|---|
The process of sending and receiving data between layers (1) | 2025.07.21 |
TCP/IP 4-layer model (0) | 2025.07.19 |
Network Bottleneck (0) | 2025.07.19 |
Throughput (0) | 2025.07.17 |