The OSI Model#

The Open Systems Interconnection (OSI) model is a conceptual framework used to describe the functions of a networking system. It consists of seven layers:
- Physical Layer: Hardware specifications, cables, and switches.
- Data Link Layer: MAC addresses and frame forwarding.
- Network Layer: IP addresses and routing.
- Transport Layer: TCP/UDP, port numbers, and reliability.
- Session Layer: Establishing, maintaining, and terminating sessions.
- Presentation Layer: Data formatting, encryption, and compression.
- Application Layer: End-user applications (HTTP, FTP, SMTP).
The TCP/IP Model#
The TCP/IP model is a more practical, four-layer model that maps closely to the actual protocols used on the Internet:
- Network Access (or Link) Layer: Combines OSI layers 1 and 2.
- Internet Layer: Corresponds to the OSI Network layer.
- Transport Layer: Corresponds to the OSI Transport layer.
- Application Layer: Combines OSI layers 5, 6, and 7.