TCP/IP Model
- The TCP/IP model predates the OSI model and has a different structure.
- It consists of five layers: Application, Transport, Network, Data Link, and Physical.
- The first four layers of the TCP/IP model encompass functions equivalent to the first four layers of the OSI model, consolidated within the TCP/IP Application layer.
- TCP/IP is hierarchical, with each upper-layer protocol supported by two or more lower-level protocols.
Function of TCP/IP Model
Network Access Layer
- A Network layer in the TCP/IP model corresponds to the combination of the Physical and Data Link layers in the OSI reference model. It dictates the physical transmission of data across the network, primarily handling data transmission between two devices on the same network.
- Functions of this layer include encapsulating IP datagrams into frames for network transmission and mapping IP addresses to physical addresses.
- Protocols commonly associated with this layer include Ethernet, Token Ring, FDDI, X.25, and Frame Relay.
Internet Layer
- The internet layer, also referred to as the network layer, occupies the second position in the TCP/IP model.
- Its main task is to ensure that packets sent from any network reach their destination, regardless of the route they take.
Following are the protocol used in this layer are:
IP Protocol: The IP protocol operates at this layer and is the most crucial component of the entire TCP/IP suite.
Following are the responsibilities of this protocol:
- IP Addressing: This protocol assigns logical host addresses, known as IP addresses. These addresses are utilized by the internet and higher layers to identify devices and enable internetwork routing.
- Host-to-Host Communication: It determines the path for data transmission between hosts.
- Data Encapsulation and Formatting: The IP protocol receives data from the transport layer, encapsulates it into a message known as an IP datagram, and ensures secure transmission and reception.
- Fragmentation and Reassembly: The Data Link layer protocol imposes a limit on the size of the IP datagram, known as the Maximum Transmission Unit (MTU). If the datagram exceeds the MTU, the IP protocol fragments it into smaller units for local network travel. Fragmentation can occur at the sender or an intermediate router, and the receiver reassembles the fragments to form the original message
- Routing: Direct delivery occurs when an IP datagram is sent within the same local network (LAN, MAN, WAN). For distant networks, the datagram is routed indirectly through various devices such as routers to reach its destination.
ARP Protocol
- ARP stands for Address Resolution Protocol.
- It operates at the network layer of the OSI model.
- Its primary function is to find the physical address (MAC address) associated with a given IP address.
- ARP is essential for communication between devices on a local network.
- It facilitates the mapping of IP addresses to MAC addresses, enabling data transmission within the network.
There two terms are mainly associated with the APL Protocol:
- ARP Request: When a sender needs the physical address of a device, it broadcasts an ARP request across the network.
- ARP Reply: Every device on the network processes the ARP request, but only the device with the matching IP address responds with its physical address in an ARP reply. The recipient device adds this physical address to its cache memory and incorporates it into the datagram header.
ICMP Protocol
- ICMP stands for Internet Control Message Protocol.
- Hosts or routers utilize ICMP to send notifications regarding datagram issues back to the sender.
- A datagram progresses from router to router until it reaches its destination. If a router encounters obstacles such as disabled links, device malfunctions, or network congestion, ICMP is employed to notify the sender that the datagram is undeliverable.
- An ICMP Protocol mainly used two terms:
- ICMP Test: ICMP Test is employed to verify the reachability of a destination.
- ICMP Reply: ICMP Reply is utilized to ascertain if the destination device is responsive.
- The ICMP protocol's core responsibility is to report encountered problems during data transmission, rather than correcting them.
- Correction of issues identified by ICMP falls under the responsibility of the sender.
- ICMP messages are sent only to the source, not to intermediate routers.
- This limitation arises because the IP datagram contains addresses only for the source and destination, not for intermediate routers.
Transport Layer
- The transport layer manages reliability, flow control, and data correction during network transmission.
- Two key protocols utilized within the transport layer are the User Datagram Protocol (UDP) and the Transmission Control Protocol (TCP).
- User Datagram Protocol
- Provides connectionless service.
- User Datagram Protocol (UDP) detects errors.
- UDP includes key fields such as:
- Source port address: Identifies the application program that created the message.
- Destination port address: Identifies the application program that will receive the message.
- Total length: Indicates the total size of the user datagram in bytes.
- Checksum: A 16-bit field used for error detection.
- Unlike some protocols, UDP does not contain packet identification for lost packets; it only includes a checksum for error detection, without segment IDs.
- Transmission Control Protocol
- TCP provides full transport layer services to applications.
- Establishes a virtual circuit between the sender and receiver.
- The virtual circuit remains active throughout the transmission.
- Reliable protocol:
- Detects errors.
- Retransmits damaged frames.
- Ensures all segments are received and acknowledged.
- Transmission is considered complete only after all segments are received and acknowledged.
- Virtual circuit is terminated once the transmission is complete.
- At the sending end:
- TCP divides the message into smaller units called segments.
- Each segment contains a sequence number for reordering.
- At the receiving end:
- TCP collects all segments.
- Reorders segments based on sequence numbers to reconstruct the original message.
Application Layer
- The application layer is the topmost layer in the TCP/IP model.
- Responsible for handling high-level protocols and representation issues.
- Enables user interaction with applications.
- Forwards data to the transport layer when one application layer protocol communicates with another.
- Ambiguity exists regarding which applications belong in the application layer.
- Only applications interacting with the communication system are included.
- Example: A text editor is not in the application layer.
- Example: A web browser using HTTP is in the application layer.
Function of Application Layer
- HTTP: HTTP stands for Hypertext Transfer Protocol. This protocol allows us to access data over the World Wide Web, transferring data in the form of plain text, audio, and video. It is known as a Hypertext Transfer Protocol because it is efficient in a hypertext environment, enabling rapid jumps from one document to another.
- SNMP: SNMP stands for Simple Network Management Protocol. It is a framework used for managing devices on the internet using the TCP/IP protocol suite.
- SMTP: SMTP stands for Simple Mail Transfer Protocol. This TCP/IP protocol supports email communication, allowing data to be sent from one email address to another.
- DNS: DNS stands for Domain Name System. An IP address uniquely identifies a host's connection to the internet, but people prefer using names instead of addresses. The system that maps these names to addresses is known as the Domain Name System.
- TELNET: TELNET stands for Terminal Network. It establishes a connection between a local computer and a remote computer, making the local terminal appear as a terminal on the remote system.
- FTP: FTP stands for File Transfer Protocol. FTP is a standard internet protocol used for transmitting files from one computer to another.

