When data is transmitted between layers in a network stack,
the unit of data at each layer is referred to as a PDU (Protocol Data Unit).
A PDU typically consists of:
- A header: control information specific to the layer
- A payload: the actual data being transmitted
Each layer has its own name for the PDU:
- Application Layer: Message
- Transport Layer: Segment (TCP) / Datagram (UDP)
- Internet Layer: Packet
- Link Layer: Frame
- Physical Layer: Bit
Among these, bits at the physical layer are the fastest and most efficient to transmit. However, at the application layer, data is typically transmitted as strings because it allows easy extension—such as including authorization tokens or metadata in headers.
Required Header Information
Although headers may be complex, they must always include two essential types of information:
- Layer-Specific Information (defined by the current layer)
- Transport Layer (Layer 4):
- Handles segmentation and reassembly of large data.
- Includes fields like sequence number and acknowledgment number (in TCP) to ensure reliable delivery and correct ordering.
- Internet Layer (Layer 3):
- Contains source and destination IP addresses to support logical routing.
- Link Layer (Layer 2):
- Includes source and destination MAC addresses for physical delivery within a local network.
- Transport Layer (Layer 4):
- Upper-Layer Protocol Identifier
- During decapsulation, the receiving system must determine which upper-layer protocol should handle the payload.
- Without this information in the header, the system cannot decide whether to pass the data to TCP, UDP, or other protocols.
- EtherType (at Layer 2)
- Protocol Number (at Layer 3)
- Port Number (at Layer 4)
⚠️ A common misconception is that port numbers, while defined in the Layer 4 header, actually indicate which application-layer protocol (e.g., HTTP, DNS) the payload belongs to.
Therefore, each layer's header must include metadata about the protocol used by the next upper layer, not itself.
'Computer Science > Network' 카테고리의 다른 글
ARP_Address Resolution Protocol (0) | 2025.07.30 |
---|---|
Load Balancer (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 |