4.3.2 · D5Computer Networks
Question bank — TCP - IP model — 4 layers, mapping to OSI
Before you start, make sure these words feel solid (each is built in the parent or a linked note):
- Layer = one swappable "job" in the communication chain (separation of concerns).
- Encapsulation = wrapping the data from above in a new header as it moves down — see Encapsulation and Decapsulation.
- Data unit names: message → segment → packet → frame → bits (top to bottom).
- Merge pattern 3-1-1-2 = how the 7 OSI layers fold into the 4 TCP/IP layers.
True or false — justify
Every item here is a claim. Decide true/false and say why in your own words, then check.
The TCP/IP model has exactly 4 layers in its original form.
True. The classic model is Application, Transport, Internet, Network Access. The "5-layer" version is a teaching hybrid that splits Network Access into Data Link + Physical — not the original.
TCP/IP and OSI describe two completely different journeys for data.
False. Same journey, different chopping. TCP/IP just groups OSI's top 3 and bottom 2 into fatter layers because real apps handle session/presentation themselves.
The TCP/IP Transport layer maps to two OSI layers.
False. Transport is one-to-one with OSI Transport (Layer 4). Only the top three and bottom two OSI layers merge; the middle two stay solo — hence the 3-1-1-2 pattern.
The Internet layer and OSI's Application layer are the same thing.
False. TCP/IP Internet ↔ OSI Network (Layer 3): it does IP addressing and routing. The name "Internet" is misleading — it has nothing to do with browsing.
Port numbers are an Internet-layer concept because they help route data.
False. Ports live in the Transport layer; they demultiplex to the right program on a host. Routing between hosts uses IP addresses at the Internet layer — see Port Numbers and Sockets.
MAC addresses are used by the Internet layer to find the destination host.
False. MAC addresses belong to the Network Access layer and identify the next physical hop, not the final host. The final host is found via its IP at the Internet layer — see Ethernet and MAC Addresses.
As data goes up the stack at the receiver, each layer adds a header.
False. Going up is decapsulation — each layer strips its own header. Adding headers happens going down at the sender.
UDP data at the Transport layer is called a "segment".
False. TCP units are segments; UDP units are datagrams. Calling everything a "packet" or "segment" loosely is a classic exam trap — see TCP vs UDP.
The Application layer in TCP/IP includes protocols like HTTP, SMTP, and DNS.
True. All three are user-facing protocols. In OSI these duties would be spread across Application, Presentation, and Session, but TCP/IP folds them into one Application layer.
Layering exists mainly to make networks run faster.
False. Layering is about separation of concerns (swappability), not speed. Your browser shouldn't care whether it's on WiFi or Ethernet; each layer solves one problem independently.
Every packet at the Internet layer is guaranteed to arrive in order.
False. IP is best-effort — no ordering or reliability guarantee. If you want that, TCP (Transport layer) provides it by reordering and retransmitting. Plain IP does not.
The OSI Presentation and Session layers have no equivalent job in TCP/IP.
False. The jobs still exist (encryption/formatting, dialogue control) — they're just handled inside the application rather than as separate layers.
Spot the error
Each statement contains one mistake. Name it and correct it.
"When you send an HTTP request, IP adds a port number so the server knows which app to reach."
Error: ports come from TCP at the Transport layer, not IP. IP adds source/destination IP addresses for routing; ports are Transport's job.
"The stack from top to bottom is: Application, Internet, Transport, Network Access."
Error: Transport and Internet are swapped. Correct order is Application → Transport → Internet → Network Access (mnemonic "All The Internet Needs").
"OSI has 4 layers and TCP/IP has 7."
Error: the numbers are reversed. OSI has 7 layers; TCP/IP has 4.
"Encapsulation means the receiver wraps the frame in an IP header before reading it."
Error: two mistakes — the sender encapsulates (adds headers going down), and the receiver decapsulates (strips headers going up). No wrapping happens at the receiver.
"Data at the Network Access layer is called a packet, then it becomes bits."
Error: the Network Access unit is a frame, then bits. Packet is the Internet-layer unit. Precise names matter.
"TCP/IP merges OSI's Transport and Network layers into one."
Error: Transport (→ Transport) and Network (→ Internet) each map one-to-one; they are not merged. Only the top 3 and bottom 2 merge.
"Since HTTPS runs on port 443, port 443 is defined at the Application layer."
Error: the protocol HTTPS is Application layer, but the port number 443 is a Transport-layer identifier used to reach that application.
Why questions
These have no single "keyword" answer — explain the reasoning.
Why does TCP/IP merge OSI's top three layers but keep Transport separate?
Because in practice a single application program handles its own session management and data formatting, so those never became separate shipped components. Transport (reliability + ports) is a genuinely distinct, reusable job, so it stays its own layer.
Why does each lower layer treat everything above it as "opaque payload"?
So layers stay independent and swappable. The Internet layer routes a packet without caring whether it holds HTTP or email; it only adds what it needs. This is separation of concerns in action.
Why can the same web request travel over WiFi on your phone and Ethernet on a server without changing the HTTP message?
Because only the Network Access layer differs between WiFi and Ethernet. The upper layers (Application/Transport/Internet) are untouched — the whole point of layering is that swapping the bottom leaves the top identical.
Why does the receiver decapsulate in the exact reverse order of encapsulation?
Because headers are wrapped like nested envelopes: the last one added (outermost, the frame header) must be the first one removed. Reverse order is the only way to peel back to the original message.
Why is it wrong to say "the Internet layer connects you to the internet"?
The Internet layer's job is addressing and routing packets across networks using IP — not providing app-level connectivity. "Connecting to a website" is the Application layer's user-facing view; routing is a lower, invisible job.
Why do exams insist on distinguishing segment / packet / frame if they all "carry data"?
Because each name tells you which layer and what header is attached, which pins down what work has been done (ports vs IPs vs MACs). Using them interchangeably hides the layer boundaries the question is testing.
Why might a textbook show 5 layers instead of the classic 4?
For teaching clarity: splitting Network Access into Data Link (framing/MAC) and Physical (raw bits) makes those two distinct jobs easier to explain. But the original TCP/IP model deliberately keeps them as one layer.
Edge cases
Boundary and degenerate scenarios the model still has to handle cleanly.
You send a request with zero bytes of application data (e.g. an empty HTTP HEAD-style body). Does encapsulation still happen?
Yes. Even with an empty payload, each layer still adds its header (ports, IPs, MAC/framing). Headers exist to deliver data; they're required regardless of how little payload there is.
A UDP message is dropped somewhere in the network. Which layer, if any, notices or fixes it?
None fixes it automatically. UDP (Transport) is connectionless and does not retransmit; IP is best-effort. If reliability is needed, the application itself must detect and handle the loss — contrast with TCP, which would retransmit.
A packet is destined for a host on the same local network — no routing across networks is needed. Do we still use the Internet layer?
Yes. The Internet layer still assigns IP addresses and decides the packet is local (no router hop needed). The Network Access layer then delivers it directly via MAC. The Internet layer is used even when routing is trivial.
Two different applications on the same computer both receive data at the same time (same IP). How does the data reach the correct one?
The Transport layer uses port numbers to demultiplex: same IP (same host) but different ports route to different programs. Without ports, a host couldn't run more than one network app at once.
An intermediate router forwards your packet. How far up the stack does the router process it?
Only up to the Internet layer — it reads the IP header to route, then re-frames for the next hop. It does not open the Transport or Application data; those are the endpoints' business.
The physical wire is replaced from copper to fiber mid-connection. Which layers must change?
Only the Network Access (specifically its physical part). Everything from Internet upward is unaffected, because the medium is abstracted away below them — this is exactly why layering is valuable.
Recall One-line self-test before you leave
Cover everything above. Say out loud: which layer owns ports, which owns IPs, which owns MACs, and what data unit each produces. Ports → Transport → segment/datagram. IPs → Internet → packet. MACs → Network Access → frame → bits.
Connections
- 4.3.02 TCP - IP model — 4 layers, mapping to OSI (Hinglish)
- OSI Model — 7 Layers
- TCP vs UDP
- IP Addressing and Routing
- Encapsulation and Decapsulation
- Port Numbers and Sockets
- Ethernet and MAC Addresses
- HTTP and the Application Layer