The previous chapter explained what a network is; this one looks at how networks run in practice. It covers the devices that connect networks (modem, NIC, hub, switch, repeater, bridge, router and gateway), the protocols that govern data transfer (HTTP, FTP, TCP/IP, PPP, the email protocols, VoIP and Telnet), and internetworking concepts such as the WWW, URLs and domain names, DNS, web hosting, HTML and XML, and network protection methods.
This chapter has three sections — Devices (hardware), Protocols (rules), and Internetworking (concepts). Each builds on the previous chapter. Read the Board Exam Tips with each section, and pay particular attention to Sections 8.2, 8.3 and 8.4.11 during revision.
8.1 🏁 Introduction
In Chapter 8, we learnt what computer networks are, how they're classified, and what media carries data. Now we zoom into:
Network Devices
The physical hardware that builds a network
ModemSwitchRouterHubBridge...Network Protocols
The rules that make communication possible
HTTPTCP/IPFTPSMTPVoIP...Internetworking
How the World Wide Web actually works
WWWURLHTMLWeb 2.0Firewall...Think of it this way: Chapter 8 gave you the map of the road system. Chapter 9 gives you the traffic lights, vehicles, and highway rules that make the whole thing work!
8.2 🔧 Network Devices
Network devices are the hardware components that build, extend, connect, and control data flow in a network. Each device operates at a specific layer of the OSI model — this determines what it can "see" and "decide".
8.2.1 Modem 📡
Modem = MOdulator + DEModulator — the device that converts signals so data can travel over telephone lines!
Why is it needed? Your computer works with digital signals (binary 0s and 1s). But old telephone lines carry analog signals (continuous waves). A modem bridges this gap — it's a signal translator!
graph LR
PC["💻 Your PC\nDigital Signal\n(0s and 1s)"]
MOD["📡 MODEM\nModulates:\nDigital → Analog"]
PHONE["📞 Phone Line\nAnalog Signal\n(Sound waves)"]
DEMOD["📡 MODEM\nDemodulates:\nAnalog → Digital"]
RPC["💻 Receiver's PC\nDigital Signal\n(0s and 1s)"]
PC -->|"Send"| MOD
MOD -->|"Analog"| PHONE
PHONE -->|"Analog"| DEMOD
DEMOD -->|"Digital"| RPC
style PC fill:#4CAF50,color:#fff
style MOD fill:#9C27B0,color:#fff
style PHONE fill:#FF9800,color:#fff
style DEMOD fill:#9C27B0,color:#fff
style RPC fill:#2196F3,color:#fff
Types of Modems:
Dial-Up Modem
Uses regular phone line; connects on demand
Max 56 Kbps — very slow; makes that "screeching" dial-up sound!DSL Modem
Digital Subscriber Line; uses same phone line but separately
ADSL: 1–24 Mbps download; always-on connectionCable Modem
Uses TV cable (coaxial) infrastructure
10–1000 Mbps; shared with neighbourhoodFibre Modem (ONT)
Converts optical (light) signals to digital
Up to 1 Gbps; most modern connectionCharacteristics:
| Property | Value |
|---|---|
| Function | Modulates (digital→analog) and Demodulates (analog→digital) |
| OSI Layer | Layer 1 (Physical) |
| Connection | Between computer and ISP's telephone/cable network |
| Ports | Phone line input + Ethernet/USB output to computer |
MOdulator + DEModulator = MODEM Your modem "speaks two languages" — it speaks Digital to your computer and Analog to the phone network. It's literally a bilingual translator for signals!
8.2.2 RJ-45 🔌
RJ-45 (Registered Jack 45) is the standard connector used at the end of Ethernet (twisted pair) cables. It's not a network device per se — it's the plug that connects devices to the network.
Physical Description:
┌──────────────────────────────────┐
│ RJ-45 Connector │
│ ┌────────────────────────┐ │
│ │ Pin: 8 7 6 5 4 3 2 1│
│ │ ● ● ● ● ● ● ● ●│ ← 8 metal pins
│ └────────────────────────┘ │
│ (Wider than RJ-11 phone jack)│
└──────────────────────────────────┘
Key Facts:
| Property | Detail |
|---|---|
| Pins | 8 pins connecting to 8 wires (4 pairs) inside UTP cable |
| Used with | Cat 5e, Cat 6, Cat 7 twisted pair cables |
| Connects to | NIC port on computer, Switch port, Router port |
| Standard | IEEE 802.3 (Ethernet) |
| Looks like | A wider version of the telephone RJ-11 plug |
8.2.3 NIC — Network Interface Card 🎴
NIC (Network Interface Card) is the hardware component installed inside every computer that physically connects it to a network. Without an NIC, a computer literally cannot join a network!
Key Facts:
MAC Address
Every NIC has a unique 48-bit MAC address burned in at manufacture
No two NICs in the world have the same MAC!RJ-45 Port
Has built-in RJ-45 socket for Ethernet cable
Plug in the cable — NIC handles the restLED Indicators
Link light (green) and Activity light (amber/yellow)
Green = connected; flashing = data transferringSpeed
Supports 10/100/1000 Mbps (auto-negotiates)
Modern NICs are Gigabit capableTypes of NIC:
| Type | Description | Where Found |
|---|---|---|
| Wired NIC | Has RJ-45 port for Ethernet cable | Desktop PCs, servers |
| Wireless NIC | Built-in antenna for WiFi | Laptops, most modern devices |
| Internal NIC | Soldered onto motherboard | All modern PCs (built-in) |
| External NIC | USB dongle or expansion card | Older PCs needing network upgrade |
Think of the NIC as your computer's front door. Without a door, no visitor (data packet) can enter or leave the house. The MAC address is like your house address plate on that door — unique, permanent, identifying exactly which house it is.
8.2.4 Hub 🔵
A Hub is the simplest and dumbest network connectivity device. It connects multiple computers in a star topology — but it's completely unintelligent about where data goes!
How Hub works:
PC1 sends a frame to PC3
↓
Hub receives it on Port 1
↓
Hub BROADCASTS it to ALL other ports (2, 3, 4, 5...)
↓
ALL computers receive the frame!
PC3 accepts it; PC2, PC4, PC5 DISCARD it
Broadcasting
Sends received data to ALL ports (no intelligence)
Like shouting in a room — everyone hearsone respondsCollision Domain
All ports share ONE collision domain
Multiple simultaneous transmissions = collision!Cost
Very cheap (now largely obsolete)
Replaced entirely by switchesCharacteristics:
| Property | Detail |
|---|---|
| Intelligence | None — broadcasts to all |
| Collision Domain | Single collision domain for all ports |
| Bandwidth | Shared among all connected devices |
| Speed | 10 Mbps or 100 Mbps |
| Today | Largely obsolete — replaced by switches |
A Hub broadcasts to ALL ports — inefficient, creates collisions. A Switch sends only to the target port — intelligent, efficient. In modern networks, Hubs are almost never used. But the Hub-Switch difference is still an important exam topic.
8.2.5 Switch 🔀 (The Smart Hub!)
A Switch is the intelligent evolution of the Hub. It learns which device is connected to which port (by reading MAC addresses) and sends data only to the correct destination — no broadcasting to everyone!
How a Switch works — MAC Address Table:
Step 1: PC1 (MAC: AA:AA) connects to Port 1
PC2 (MAC: BB:BB) connects to Port 2
PC3 (MAC: CC:CC) connects to Port 3
Step 2: Switch builds a MAC Table:
┌──────────┬──────┐
│ MAC Addr │ Port │
├──────────┼──────┤
│ AA:AA │ 1 │
│ BB:BB │ 2 │
│ CC:CC │ 3 │
└──────────┴──────┘
Step 3: PC1 sends data to PC3 (MAC: CC:CC)
Switch looks up MAC table → CC:CC is on Port 3
Switch sends ONLY to Port 3 — PC2 never sees it!
graph TD
SW["🔀 SWITCH\n(MAC Address Table)\nSends only to target port!"]
P1["💻 PC 1\nMAC: AA:AA\n(Port 1)"]
P2["💻 PC 2\nMAC: BB:BB\n(Port 2)"]
P3["💻 PC 3\nMAC: CC:CC\n(Port 3)"]
P4["🖨️ Printer\nMAC: DD:DD\n(Port 4)"]
SW -->|"Port 1"| P1
SW -->|"Port 2"| P2
SW -->|"Port 3 ← data goes HERE only"| P3
SW -->|"Port 4"| P4
style SW fill:#2196F3,color:#fff
style P3 fill:#4CAF50,color:#fff
style P1 fill:#9E9E9E,color:#fff
style P2 fill:#9E9E9E,color:#fff
style P4 fill:#9E9E9E,color:#fff
Hub vs Switch — Definitive Comparison:
| Feature | Hub | Switch |
|---|---|---|
| Intelligence | None — dumb device | Smart — reads MAC addresses |
| Data Forwarding | Broadcasts to ALL ports | Sends ONLY to target port |
| Collision Domain | One big shared domain | Each port = separate collision domain |
| Bandwidth | Shared (total bandwidth divided) | Dedicated per port (full bandwidth!) |
| Security | Low — everyone sees all data | Better — only target receives data |
| Speed | 10–100 Mbps | 10/100/1000 Mbps (Gigabit) |
| Cost | Cheaper (obsolete) | Slightly more expensive |
| Modern Use? | ❌ Rarely used | ✅ Standard in all networks |
"Differentiate between Hub and Switch" — 2-mark question. Core answer: A Hub broadcasts data to ALL connected devices; a Switch maintains a MAC address table and sends data ONLY to the intended recipient's port. Switch is intelligent (Layer 2); Hub is not (Layer 1).
8.2.6 Repeater 📶
A Repeater is a device that receives a weakened/degraded signal and regenerates (amplifies) it to its original strength before retransmitting. It fights signal attenuation — the natural weakening of signals over distance!
graph LR
A["📡 Source\nStrong Signal\n████████"]
B["~~~~~~~~~~~~~\nWeak Signal Over\nLong Distance\n▒▒░░░░░░"]
REP["🔄 REPEATER\nAmplifies &\nRegenerates!"]
C["~~~~~~~~~~~~~\nStrong Signal\nAgain!\n████████"]
D["📥 Destination"]
A --> B
B --> REP
REP --> C
C --> D
style A fill:#4CAF50,color:#fff
style REP fill:#FF9800,color:#fff
style D fill:#2196F3,color:#fff
Characteristics:
| Property | Detail |
|---|---|
| Function | Regenerates and amplifies weakened signals |
| Intelligence | None — just boosts the signal |
| Placement | Placed before signal becomes too weak |
| In Ethernet (UTP) | Needed after every 100 m segment |
| In Optical Fibre | Needed every 100 km+ (much better!) |
Advantages
Extends network range beyond single segment limit; Simple; Inexpensive
Essential for long-distance runsDisadvantages
Cannot filter traffic; Amplifies noise along with signal; Cannot connect different network types
Cannot segment trafficThink of a Repeater as a signal energy drink 🥤 — the signal gets tired (weak) after travelling far, the Repeater gives it a full energy boost!
8.2.7 Bridge 🌉
A Bridge connects two LAN segments and filters traffic between them using MAC addresses. It's smarter than a Repeater — it can decide whether to forward or block frames!
How Bridge works:
Segment A ──────────[ BRIDGE ]────────────── Segment B
PC1, PC2, PC3 reads MAC PC4, PC5, PC6
Rule: IF destination MAC is in same segment → BLOCK (don't forward)
IF destination MAC is in other segment → FORWARD across bridge
graph LR
subgraph SegA["Segment A"]
PC1["💻 PC1\nMAC: A1"]
PC2["💻 PC2\nMAC: A2"]
end
BRIDGE["🌉 BRIDGE\nReads MAC\nFilters traffic"]
subgraph SegB["Segment B"]
PC3["💻 PC3\nMAC: B1"]
PC4["💻 PC4\nMAC: B2"]
end
PC1 --- BRIDGE
PC2 --- BRIDGE
BRIDGE --- PC3
BRIDGE --- PC4
style BRIDGE fill:#9C27B0,color:#fff
Characteristics:
| Property | Detail |
|---|---|
| Data Unit | Frames (reads MAC addresses) |
| Function | Connects two LAN segments; filters by MAC address |
| Collision Domains | Separates collision domains (each side is independent!) |
| Intelligence | Moderate — maintains table of MAC addresses per segment |
| Today | Largely replaced by Switches (a switch = multi-port bridge) |
Advantages
Reduces collision domains; Filters local traffic (improves performance); Connects two network segments
Larger networksextending LANsDisadvantages
Cannot connect different network types; Slower than switch; Limited ports
Replaced by switches in modern networksA Switch is essentially a multi-port bridge! While a bridge has just 2 ports (one per segment), a switch has many ports — and applies the same MAC-based intelligent filtering per port. This is why they're both Layer 2 devices.
8.2.8 Router 🗺️ (The Internet's Navigation System!)
A Router is the most intelligent and critical device in modern networking. It connects different networks and uses IP addresses to determine the best path for each packet to reach its destination.
Real-world analogy: If a Switch is like a post office that delivers letters within your city using street addresses (MAC), then a Router is like the GPS navigation system that routes letters across the country using postal codes (IP addresses)!
How Router works — Routing Table:
Packet arrives with destination IP: 192.168.2.5
Router checks its Routing Table:
┌────────────────────┬──────────────┬──────────┐
│ Destination Network│ Next Hop │ Interface│
├────────────────────┼──────────────┼──────────┤
│ 192.168.1.0/24 │ Direct │ eth0 │
│ 192.168.2.0/24 │ 10.0.0.2 │ eth1 │ ← Match! Forward here
│ 0.0.0.0/0 │ 10.0.0.1 │ eth1 │ (default route)
└────────────────────┴──────────────┴──────────┘
→ Router sends packet out through eth1 toward 10.0.0.2
graph TD
HOME["🏠 Home Network\n192.168.1.x\n(LAN)"]
ROUTER["🗺️ ROUTER\nReads IP addresses\nFinds best path\nConnects networks"]
ISP["🌐 ISP Network\n203.x.x.x\n(WAN)"]
INTERNET["🌍 The Internet\n(Multiple Networks)"]
HOME <-->|"Local IP\n192.168.1.x"| ROUTER
ROUTER <-->|"Public IP\n203.x.x.x"| ISP
ISP <-->|"Routing"| INTERNET
style HOME fill:#4CAF50,color:#fff
style ROUTER fill:#F44336,color:#fff
style ISP fill:#FF9800,color:#fff
style INTERNET fill:#2196F3,color:#fff
Characteristics:
| Property | Detail |
|---|---|
| OSI Layer | Layer 3 (Network) |
| Data Unit | Packets (reads IP addresses) |
| Function | Routes packets between different networks using IP |
| Routing Table | Maintains map of networks and best paths |
| Connects | Different networks (LAN to WAN, LAN to LAN) |
| NAT | Translates private IPs to public IP (Network Address Translation) |
| In Home | Your WiFi router connects home LAN to ISP's WAN |
Advantages
Connects different networks; Finds optimal paths; Separates broadcast domains; Provides NAT and firewall; Essential for Internet
The backbone of Internet connectivityDisadvantages
More expensive than bridge/switch; Slower (more processing); Complex to configure
Requires skilled setupRouter vs Switch vs Hub — Final Comparison:
| Feature | Hub | Switch | Router |
|---|---|---|---|
| OSI Layer | L1 | L2 | L3 |
| Addresses | None | MAC | IP |
| Connects | Devices | Devices | Networks |
| Intelligence | None | Medium | High |
| Broadcast Domain | Shared | Shared | Separated ✅ |
| Collision Domain | Shared | Separate ✅ | Separate ✅ |
| Internet Access | ❌ | ❌ | ✅ |
"What is the function of a Router in a network?" — 2-mark question. Answer: A Router operates at Layer 3 (Network Layer) and routes data packets between different networks based on IP addresses. It maintains a routing table to determine the optimal path for each packet and enables devices on a local network to communicate with the Internet.
8.2.9 Gateway 🚪 (The Universal Translator!)
A Gateway is the most complex of these network devices. It connects two completely different networks that use different protocols, architectures, or data formats — it translates everything!
Perfect Analogy: If a Router is like a GPS routing your car between two cities, a Gateway is like a customs office at an international border — translating not just addresses, but entire languages, documents, and rules between two completely different countries (protocols)!
graph LR
NET1["🏢 Corporate Network\nUsing TCP/IP\nProtocol Suite A"]
GW["🚪 GATEWAY\nProtocol Conversion\nFull Translation\n(All 7 OSI Layers)"]
NET2["🏭 Industrial Network\nUsing SNA/X.25\nProtocol Suite B"]
NET1 <-->|"Different\nprotocol"| GW
GW <-->|"Different\nprotocol"| NET2
style GW fill:#F44336,color:#fff
style NET1 fill:#4CAF50,color:#fff
style NET2 fill:#2196F3,color:#fff
Characteristics:
| Property | Detail |
|---|---|
| OSI Layer | All 7 layers (Layer 4 to Layer 7 typically) |
| Function | Protocol conversion between completely different networks |
| Examples | Email gateway (converts between email formats); VoIP gateway (converts digital voice to analog); Payment gateway |
| Processing | Most complex and slowest of all network devices |
Advantages
Connects ANY two networks regardless of protocols; Most versatile device; Can perform full protocol translation
Enterprise inter-networkinglegacy system integrationDisadvantages
Most expensive; Slowest (most processing required); Complex to configure and manage
Only when absolutely necessaryGateway ← Most intelligent (all 7 layers, protocol translation)
↑
Router ← Layer 3, reads IP, routes between networks
↑
Switch ← Layer 2, reads MAC, sends to correct port
↑
Bridge ← Layer 2, reads MAC, filters between 2 segments
↑
Repeater/Hub ← Layer 1, just amplifies/broadcasts (no intelligence)8.2.10 WiFi Card 📶
A WiFi Card (Wireless NIC / WNIC) is the wireless version of an NIC — it allows a device to connect to a network without physical cables, using radio waves instead.
Antenna
Built-in or external antenna for signal transmission/reception
You've seen the little antennas on routers!Frequency
2.4 GHz (longer range) and 5 GHz (faster but shorter range)
Dual-band cards support bothStandards
IEEE 802.11 a/b/g/n/ac/ax (WiFi 4/5/6)
WiFi 6 (802.11ax) is current fastestForm Factor
Internal (M.2, PCIe), External (USB dongle)
Built into all modern laptopsWiFi Standards Evolution:
| Standard | Max Speed | Frequency | Common Name |
|---|---|---|---|
| 802.11b | 11 Mbps | 2.4 GHz | WiFi 1 (1999) |
| 802.11g | 54 Mbps | 2.4 GHz | WiFi 3 (2003) |
| 802.11n | 600 Mbps | 2.4/5 GHz | WiFi 4 (2009) |
| 802.11ac | 3.5 Gbps | 5 GHz | WiFi 5 (2013) |
| 802.11ax | 9.6 Gbps | 2.4/5/6 GHz | WiFi 6 (2019) |
- 2.4 GHz: Better range (penetrates walls further); slower; more interference (shares with Bluetooth, microwave ovens!)
- 5 GHz: Faster speeds; shorter range; less interference Choose 2.4 GHz when far from router; 5 GHz when close for maximum speed!
8.2.11 Network Devices and Components — Checklists
Complete Summary and Comparison:
| Device | OSI Layer | Reads | Connects | Smart? | Use Today |
|---|---|---|---|---|---|
| Modem | L1 | Signal type | PC to ISP | No | ✅ Yes |
| RJ-45 | L1 | — | Cable to device | No | ✅ Yes (connector) |
| NIC | L1-2 | MAC | Device to network | No | ✅ Yes (every device!) |
| Hub | L1 | Bits only | Devices in LAN | ❌ None | Obsolete |
| Switch | L2 | MAC address | Devices in LAN | ✅ Medium | ✅ Standard |
| Repeater | L1 | Signal strength | Extends cable run | ❌ None | Sometimes |
| Bridge | L2 | MAC address | Two LAN segments | ✅ Medium | Rare (replaced by switch) |
| Router | L3 | IP address | Networks (LAN↔WAN) | ✅ High | ✅ Essential |
| Gateway | L4-7 | All protocols | Different protocol networks | ✅ Highest | ✅ Specialized use |
| WiFi Card | L1-2 | Wireless signal | Wireless to network | ❌ Hardware | ✅ All wireless devices |
Quick-Select Guide — "Which device should I use?"
graph TD
Q1{"What do you need to do?"}
Q1 -->|"Extend cable range"| REP["Use a REPEATER"]
Q1 -->|"Connect devices in same network"| Q2{"Budget / Need?"}
Q2 -->|"Basic / cheapest"| HUB["Use a HUB\n(not recommended)"]
Q2 -->|"Smart, efficient"| SW["Use a SWITCH ✅"]
Q1 -->|"Connect two LAN segments"| BR["Use a BRIDGE"]
Q1 -->|"Connect to Internet / different network"| RT["Use a ROUTER ✅"]
Q1 -->|"Connect totally different protocol networks"| GW["Use a GATEWAY"]
style REP fill:#4CAF50,color:#fff
style SW fill:#2196F3,color:#fff
style RT fill:#FF9800,color:#fff
style GW fill:#F44336,color:#fff
style HUB fill:#9E9E9E,color:#fff
style BR fill:#9C27B0,color:#fff
8.3 📋 Network Protocols
A Protocol is a set of rules and conventions that govern how data is transmitted between devices in a network. Without protocols, networked computers cannot communicate — even if all the cables and hardware are perfect!
Real-world Analogy: Imagine two people meeting. Protocol says: shake hands, introduce yourself, speak in turn, say goodbye when done. Computer protocols work exactly the same — they specify HOW to initiate, conduct, and end communication!
Protocol Key Properties:
- Syntax — What format does the data take?
- Semantics — What does each section of data mean?
- Timing — When to send? How fast?
8.3.1 HTTP — Hypertext Transfer Protocol 🌐
HTTP is the foundation protocol of the World Wide Web — the set of rules your browser uses to request web pages and web servers use to respond!
How HTTP works — Request/Response Model:
graph LR
B["🌐 Browser\n(Client)\nChrome/Firefox"]
S["🖥️ Web Server\nApache/Nginx"]
B -->|"HTTP REQUEST\nGET /index.html HTTP/1.1\nHost: csip12.in"| S
S -->|"HTTP RESPONSE\n200 OK\nContent: HTML page"| B
style B fill:#4CAF50,color:#fff
style S fill:#2196F3,color:#fff
HTTP Methods (the verbs of the Web!):
| Method | Action | Example Use |
|---|---|---|
| GET | Retrieve/fetch data | Opening a webpage |
| POST | Submit data to server | Submitting a login form |
| PUT | Update existing data | Editing a profile |
| DELETE | Delete data | Removing a post |
HTTP Response Codes — The Web's Status Messages:
| Code | Meaning | You've Seen This! |
|---|---|---|
| 200 OK | Request successful | Every working webpage |
| 301 Moved Permanently | Page moved to new URL | Old URLs redirect |
| 404 Not Found | Page doesn't exist | That sad "404" page! |
| 500 Internal Server Error | Server crashed | "Something went wrong" |
| 403 Forbidden | Access denied | No permission to view |
HTTP vs HTTPS:
HTTP (Port 80)
Data sent as plain text — anyone can intercept and read it!
Never use for passwords or paymentsHTTPS (Port 443)
HTTP + SSL/TLS encryption — data scrambled; only sender and receiver can read
Always look for the padlock 🔒 in your browser!"What is the difference between HTTP and HTTPS?" — 2-mark question. HTTP sends data as plain unencrypted text (port 80). HTTPS adds SSL/TLS encryption (port 443), making data transmission secure. HTTPS is essential for banking, shopping, and login pages. The 'S' in HTTPS stands for Secure.
8.3.2 FTP — File Transfer Protocol 📁
FTP is the standard protocol for transferring files between computers over a network. It's like having a secure courier service specifically designed for files!
FTP uses TWO connections simultaneously:
Control Connection (Port 21) — Commands: "login", "list directory", "get file"
Data Connection (Port 20) — Actual file data transfer
graph LR
FTP_C["💻 FTP Client\n(Your PC)"]
FTP_S["🖥️ FTP Server\n(Remote)"]
FTP_C -->|"Control Channel\nPort 21\nCommands"| FTP_S
FTP_C <-->|"Data Channel\nPort 20\nActual Files"| FTP_S
style FTP_C fill:#4CAF50,color:#fff
style FTP_S fill:#2196F3,color:#fff
FTP Modes:
Active Mode
Client opens random port; Server initiates data connection back
Server connects TO client for dataPassive Mode
Client initiates BOTH connections; better with firewalls
Client connects TO server for data — modern defaultCommon FTP Commands:
| Command | Action |
|---|---|
USER / PASS |
Login credentials |
LIST |
List files in directory |
GET filename |
Download file from server |
PUT filename |
Upload file to server |
QUIT |
Disconnect |
Advantages
Reliable large file transfer; Resume interrupted transfers; Directory browsing
Website file managementlarge data transfersDisadvantages
Unencrypted by default (use SFTP/FTPS for security!); Requires separate client software
Replaced by SFTP/FTPS for secure transfersWeb developers use FTP clients (like FileZilla) to upload website files to hosting servers. When you "publish" your website, you're likely using FTP or SFTP (Secure FTP) behind the scenes!
8.3.3 TCP/IP — The Internet's Core Protocol Suite 🌐
TCP/IP is not one protocol — it's a suite (family) of protocols that forms the backbone of the Internet. It's so fundamental that the Internet is sometimes called "The TCP/IP Network."
TCP/IP consists of TWO main protocols:
TCP (Transmission Control Protocol)
Ensures reliable, ordered delivery of data
Like registered post with delivery confirmation!IP (Internet Protocol)
Handles addressing and routing of packets
Like the postal addressing systemTCP — How Reliable Delivery Works:
graph LR
S["📤 Sender"]
R["📥 Receiver"]
S -->|"1. SYN\n'Can we talk?'"| R
R -->|"2. SYN-ACK\n'Yes, ready!'"| S
S -->|"3. ACK\n'Great, sending...'"| R
S -->|"4. DATA Packets\n(numbered)"| R
R -->|"5. ACK for each packet\n'Got it!'"| S
S -->|"6. Missing packet?\nRetransmit!"| R
style S fill:#4CAF50,color:#fff
style R fill:#2196F3,color:#fff
TCP vs UDP — The Two Transport Protocols:
| Feature | TCP | UDP |
|---|---|---|
| Full Form | Transmission Control Protocol | User Datagram Protocol |
| Connection | Connection-oriented (3-way handshake) | Connectionless |
| Reliability | ✅ Guaranteed delivery | ❌ No guarantee |
| Order | ✅ Packets arrive in order | ❌ May arrive out of order |
| Error Checking | ✅ Yes, with retransmission | ❌ Basic checksum only |
| Speed | Slower (overhead for reliability) | ✅ Faster (no overhead) |
| Use Case | Web, email, file transfer | Video streaming, gaming, DNS |
The TCP/IP Four-Layer Model:
graph TD
A["📱 Application Layer\n(HTTP, FTP, SMTP, DNS)\nWhat applications use"]
B["🔄 Transport Layer\n(TCP, UDP)\nEnd-to-end communication"]
C["🌐 Internet Layer\n(IP, ICMP)\nRouting and addressing"]
D["🔌 Network Access Layer\n(Ethernet, WiFi, ARP)\nPhysical transmission"]
A --> B
B --> C
C --> D
style A fill:#F44336,color:#fff
style B fill:#FF9800,color:#fff
style C fill:#4CAF50,color:#fff
style D fill:#2196F3,color:#fff
"What is the role of TCP/IP in computer networks?" — 2-mark question. Answer: TCP/IP is the fundamental protocol suite of the Internet. IP provides addressing and routing of data packets across networks. TCP ensures reliable, ordered, error-checked delivery of data between applications. Together, they define how data is packaged, addressed, transmitted, and received on the Internet.
8.3.4 SLIP and PPP 📞
These are two older protocols used for dial-up / serial line Internet connections — connecting computers over telephone lines or serial ports.
SLIP (Serial Line Internet Protocol)
Older, simpler protocol for serial line IP transmission
No error checkingno authenticationno compression — bare bones!PPP (Point-to-Point Protocol)
Improved replacement for SLIP — the modern standard
Has error detectionauthentication (username/password)compressionencryptionSLIP vs PPP Comparison:
| Feature | SLIP | PPP |
|---|---|---|
| Year | 1984 | 1994 |
| Error Checking | ❌ No | ✅ Yes |
| Authentication | ❌ No | ✅ Yes (PAP / CHAP) |
| Compression | ❌ No | ✅ Yes |
| Multiple Protocols | ❌ IP only | ✅ IP, IPX, others |
| Status | Obsolete | Still used (PPPoE for broadband) |
Your home broadband (ADSL/VDSL) connection likely uses PPPoE (PPP over Ethernet). When your router asks for a "username" and "password" to connect to the ISP, it's using PPP authentication! This is why your internet requires login credentials.
8.3.5 Protocols Used in Email 📧
Email uses three different protocols — one for sending, two for receiving!
graph LR
S["📤 Sender's\nEmail Client\n(Gmail/Outlook)"]
SMTP_S["📮 Sender's\nMail Server\n(gmail SMTP)"]
SMTP_R["📬 Receiver's\nMail Server\n(yahoo SMTP)"]
R["📥 Receiver's\nEmail Client\n(Yahoo Mail)"]
S -->|"SMTP\n(Port 25/587)\nSend"| SMTP_S
SMTP_S -->|"SMTP\n(Server to Server)"| SMTP_R
SMTP_R -->|"POP3 (Port 110)\nor IMAP (Port 143)\nDownload"| R
style S fill:#4CAF50,color:#fff
style SMTP_S fill:#FF9800,color:#fff
style SMTP_R fill:#FF9800,color:#fff
style R fill:#2196F3,color:#fff
The Three Email Protocols:
SMTP (Simple Mail Transfer Protocol)
Port 25/587 — Used to SEND emails
Your client → Your mail server → Recipient's mail serverPOP3 (Post Office Protocol v3)
Port 110 — Downloads email to your device and DELETES from server
Like taking the letter home — server keeps no copy!IMAP (Internet Message Access Protocol)
Port 143 — Keeps email ON server; sync across devices
Like reading letter at post office — server keeps original!POP3 vs IMAP — The Critical Difference:
| Feature | POP3 | IMAP |
|---|---|---|
| Email Location | Downloaded to ONE device | Stays on server |
| Multiple Devices | ❌ Access on one device only | ✅ Access from any device |
| Offline Access | ✅ After download | Limited |
| Server Storage | Uses no server space | Uses server storage |
| Sync | ❌ No sync between devices | ✅ Fully synced |
| Best For | Single-device users | Multiple device users |
| Example | Old desktop email clients | Gmail, Outlook, modern email |
| Port | 110 | 143 |
"Differentiate between POP3 and IMAP" — 2-mark question. Key: POP3 downloads email to local device and removes from server (one device only). IMAP keeps email on server and synchronises across all devices (check on phone AND laptop = same view).
8.3.6 VoIP — Voice over Internet Protocol 📞
VoIP converts your voice (analog sound) into digital data packets and sends them over the Internet — instead of through traditional telephone networks. This is how WhatsApp, Skype, and Google Meet make calls!
graph LR
MIC["🎤 Your Voice\n(Analog Sound)"]
ADC["⚙️ ADC\nAnalog → Digital\nConversion"]
PKT["📦 Voice Packets\n(Data over Internet)"]
DAC["⚙️ DAC\nDigital → Analog\nConversion"]
SPK["🔊 Friend's\nSpeaker"]
MIC --> ADC
ADC --> PKT
PKT -->|"Internet"| DAC
DAC --> SPK
style MIC fill:#4CAF50,color:#fff
style PKT fill:#2196F3,color:#fff
style SPK fill:#FF9800,color:#fff
Cost
Dramatically cheaper than traditional phone calls
Free or near-free international calls!Requirement
Needs reliable internet connection with low latency
Poor connection = choppy audioExamples
WhatsApp, Skype, Google Meet, Zoom, Discord
You use VoIP every day!Protocol Used
RTP (Real-time Transport Protocol) + SIP for signalling
Runs over UDP (speed over reliability)VoIP vs Traditional Phone:
| Feature | Traditional Phone (PSTN) | VoIP |
|---|---|---|
| Infrastructure | Dedicated phone lines | Internet connection |
| Cost (International) | Very expensive | Free / very cheap |
| Quality | High (dedicated circuit) | Variable (depends on internet) |
| Flexibility | Fixed phone number | Use from anywhere |
| Switching | Circuit switching | Packet switching |
In a voice call, if a tiny bit of audio is lost, it's better to skip it and continue (you just hear a small glitch) than to wait for retransmission (which would cause a noticeable delay). Speed beats reliability for real-time audio — that's why VoIP uses UDP!
8.3.7 Telnet 💻
Telnet (TELetype NETwork) is a protocol that allows you to remotely log in and control another computer over a network — as if you were sitting right in front of it!
graph LR
LOCAL["💻 Your PC\nLocal Terminal\n(Durgapur)"]
NET["🌐 Network\n(Internet)"]
REMOTE["🖥️ Remote Server\n(Mumbai)\nYou control this!"]
LOCAL -->|"Telnet Port 23\nKeyboard input"| NET
NET -->|"Text output\nback to you"| LOCAL
LOCAL -->|"Connected to"| REMOTE
style LOCAL fill:#4CAF50,color:#fff
style REMOTE fill:#F44336,color:#fff
Key Facts about Telnet:
| Property | Detail |
|---|---|
| Port | 23 |
| Protocol | TCP |
| Connection | Command-line text interface only |
| Security | ⚠️ NONE — sends data including passwords as plain text! |
| Today | Largely replaced by SSH (Secure Shell) |
Advantages
Remote system administration; Lightweight (text-only); Works across all platforms
Network device managementDisadvantages
No encryption — completely insecure; Anyone can sniff passwords; Outdated
NEVER use on public internet — use SSH!Never use Telnet over the public internet. Everything you type — including your username and password — travels as plain text and can be captured by anyone on the network path. Always use SSH (Secure Shell, Port 22) instead — it's the encrypted, modern replacement for Telnet.
Protocol Port Number Quick Reference:
| Protocol | Port | Purpose |
|---|---|---|
| HTTP | 80 | Web browsing |
| HTTPS | 443 | Secure web browsing |
| FTP | 20, 21 | File transfer |
| SMTP | 25 / 587 | Sending email |
| POP3 | 110 | Downloading email |
| IMAP | 143 | Syncing email |
| Telnet | 23 | Remote terminal (insecure) |
| SSH | 22 | Secure remote terminal |
| DNS | 53 | Domain name resolution |
"What port number does HTTP / FTP / SMTP use?" — 1-mark questions. Memorise the most common ones: HTTP=80, HTTPS=443, FTP=21, SMTP=25, POP3=110, IMAP=143, Telnet=23, SSH=22, DNS=53 A great memory hack: HTTP=80 (H is the 8th letter!), SMTP=25 (Send = 25).
8.4 🌐 Internetworking Terms and Concepts
This section covers the vocabulary and concepts of the World Wide Web — the part of the Internet you interact with every day. From URLs to HTML to cybersecurity, this section is critical for board exams!
8.4.1 WWW — World Wide Web 🕸️
WWW (World Wide Web) is a system of interlinked hypertext documents (web pages) that are accessed via the Internet using a web browser.
Key Facts:
| Fact | Detail |
|---|---|
| Invented by | Tim Berners-Lee at CERN (Switzerland) |
| Year | 1991 — first website went live! |
| First website | info.cern.ch (still accessible today!) |
| Protocol used | HTTP / HTTPS |
| Underlying network | The Internet |
Internet vs WWW — The Critical Distinction:
THE INTERNET (The Infrastructure)
├── World Wide Web (HTTP, websites) 🌐
├── Email (SMTP, POP3, IMAP) 📧
├── File Transfer (FTP) 📁
├── VoIP Calls (WhatsApp, Skype) 📞
├── Online Gaming 🎮
└── many more services...
The Internet is the physical highway system. The WWW is just one type of vehicle (websites) that uses those highways. Email is another vehicle, FTP is another, VoIP is another!
8.4.2 Web Browser and Web Server 🖥️
Web Browser: A web browser is client software that retrieves and displays web pages from the Internet. It's your window to the World Wide Web!
Google Chrome
Most used browser worldwide — ~65% market share
Fastsyncs with Google accountMozilla Firefox
Open-source, privacy-focused
Strong privacy featuresApple Safari
Default on Apple devices
Optimised for Mac/iPhoneMicrosoft Edge
Built into Windows 11
Replaced Internet Explorer (RIP! 😂)Web Server: A web server is software/hardware that stores, processes, and serves web pages to browsers on request.
Apache HTTP Server
Most popular open-source web server
Powers ~30% of all websitesNginx
Fast, lightweight; excellent for high traffic
NetflixAirbnbWordPress.comMicrosoft IIS
Windows-based web server
Used in .NET / ASP.NET environmentsBrowser-Server Interaction:
1. You type "www.csip12.in" in Chrome
2. Chrome sends HTTP GET request to csip12.in's web server
3. Web server processes request → finds index.html
4. Web server sends HTTP 200 response with HTML content
5. Chrome receives HTML, CSS, JS → renders the beautiful page!
8.4.3 Web Sites, Web Addresses and Web Pages 📄
Web Page
A single document written in HTML; one file
Like one page in a bookWebsite
A collection of related web pages under one domain
Like the entire bookHome Page
The first/default page of a website (usually index.html)
Like the book's coverHyperlink
Clickable text/image that takes you to another page
The links you click!Types of Web Pages:
| Type | Technology | Changes? | Example |
|---|---|---|---|
| Static Page | HTML + CSS only | ❌ Same for everyone | Simple portfolio page |
| Dynamic Page | HTML + CSS + Server-side (PHP, Python) | ✅ Content changes per user | Facebook feed, Gmail |
8.4.4 URL and Domain Names 🔗
URL (Uniform Resource Locator) is the complete web address that uniquely identifies any resource on the Internet. It's like the full postal address for any specific thing on the Web!
Anatomy of a URL:
https :// www.csip12.in :443 /chapter8 /functions.html ?topic=scope #section3
↑ ↑ ↑ ↑ ↑ ↑ ↑
Protocol Domain Name Port Directory File Name Query Anchor/
(Scheme) (optional) (Resource) Parameter Fragment
Breaking down https://mail.google.com/mail/u/0/#inbox:
| Part | Value | Meaning |
|---|---|---|
| Protocol | https |
Secure HTTP |
| Subdomain | mail |
Mail section of Google |
| Domain | google |
The organisation |
| TLD | .com |
Commercial domain |
| Path | /mail/u/0/ |
Directory path |
| Fragment | #inbox |
Jump to inbox section |
"What is the full form of URL and what does it represent?" — 2-mark question. URL = Uniform Resource Locator. It is a complete web address that specifies the location of a resource (web page, image, video, etc.) on the Internet. It includes the protocol (HTTP/HTTPS), domain name, path to the resource, and optionally port, query parameters, and fragment.
Domain Names:
Domain names are the human-readable part of URLs. Structure:
subdomain . second-level-domain . TLD
www . google . com
mail . csip12 . in
Country Code TLDs (ccTLDs):
| TLD | Country | Example |
|---|---|---|
.in |
India | bsnl.co.in, cbse.gov.in |
.uk |
United Kingdom | bbc.co.uk |
.au |
Australia | abc.net.au |
.jp |
Japan | toyota.co.jp |
.de |
Germany | siemens.de |
8.4.5 Domain Name System (DNS) 🗄️
DNS (Domain Name System) is the Internet's distributed phone book / directory service — it translates human-readable domain names into machine-readable IP addresses.
DNS Resolution — Step by Step:
graph TD
U["👤 You type:\nwww.csip12.in"]
CACHE{"🔍 Browser Cache\nKnows the IP?"}
RES["📡 Recursive Resolver\n(Your ISP's DNS server)"]
ROOT["🌍 Root Name Server\n(Knows TLD servers)"]
TLD_S["🗄️ TLD Name Server\nfor .in domain"]
AUTH["🖥️ Authoritative Server\nfor csip12.in\n(Has the answer!)"]
IP["✅ IP: 123.45.67.89"]
SITE["🌐 csip12.in\nLoads!"]
U --> CACHE
CACHE -->|"No — ask DNS"| RES
RES -->|"Ask Root"| ROOT
ROOT -->|"Try .in TLD server"| RES
RES -->|"Ask TLD"| TLD_S
TLD_S -->|"Try csip12.in auth server"| RES
RES -->|"Ask Authoritative"| AUTH
AUTH -->|"IP = 123.45.67.89"| RES
RES -->|"Cache & return IP"| U
U --> SITE
style U fill:#4CAF50,color:#fff
style AUTH fill:#F44336,color:#fff
style IP fill:#FF9800,color:#fff
style SITE fill:#2196F3,color:#fff
DNS Hierarchy:
| Level | Name | Role | Example |
|---|---|---|---|
| Root | Root Servers (13 worldwide) | Points to TLD servers | . (the invisible dot!) |
| TLD | TLD Servers | Manages .com, .in etc. |
Verisign manages .com |
| Authoritative | Domain's Own DNS | Has final IP answer | csip12.in's hosting DNS |
| Recursive Resolver | ISP's DNS | Queries on your behalf | BSNL's DNS: 61.0.0.127 |
DNS Caching means your computer remembers IP answers for a period (called TTL — Time to Live). So when you visit google.com again, your browser uses the cached IP — no DNS query needed! This is why websites load faster the second time.
8.4.6 Web Hosting 🏠
Web Hosting is the service of renting space on a web server where your website files are stored and made accessible on the Internet 24/7.
graph LR
FILES["📁 Your Website Files\n(HTML, CSS, images, JS)"]
UPLOAD["⬆️ Upload via FTP"]
HOST["🖥️ Web Hosting Server\n(Always ON, Connected to Internet)"]
VISITORS["👥 Website Visitors\nWorldwide"]
FILES --> UPLOAD
UPLOAD --> HOST
HOST -->|"HTTP Response"| VISITORS
style FILES fill:#4CAF50,color:#fff
style HOST fill:#F44336,color:#fff
style VISITORS fill:#2196F3,color:#fff
Types of Web Hosting:
Shared Hosting
Many websites share ONE server's resources
Cheapest — ₹100-500/month; like apartment in a building. Used by csip12.in type sites!VPS Hosting
Virtual Private Server — dedicated portion of a physical server
Mid-range — more control and resourcesDedicated Hosting
Entire server dedicated to YOUR website only
Expensive but best performance — bankslarge e-commerceCloud Hosting
Website hosted across multiple servers in cloud
Scalablepay-as-you-grow — AWSGoogle CloudAzurePopular Web Hosting Providers:
| Provider | Type | Known For |
|---|---|---|
| Hostinger | Shared/VPS | Cheap, good performance — popular in India |
| GoDaddy | Shared/Dedicated | Domain + hosting bundle |
| Amazon AWS | Cloud | Enterprise-grade, used by Netflix, Airbnb |
| Google Cloud | Cloud | Global CDN, powerful |
| Netlify | Static | Free tier — perfect for static websites |
8.4.7 Web 2.0 and Web 3.0 🔮
The Web has evolved through distinct generations, each transforming how we interact with the Internet!
graph LR
W1["📄 Web 1.0\n(1991-2004)\nRead-only Web\nStatic pages\nOne-way info"]
W2["👥 Web 2.0\n(2004-Now)\nRead-Write Web\nUser-generated content\nSocial media"]
W3["🔮 Web 3.0\n(Emerging)\nRead-Write-Own Web\nSemantic, AI-driven\nDecentralised"]
W1 --> W2
W2 --> W3
style W1 fill:#9E9E9E,color:#fff
style W2 fill:#2196F3,color:#fff
style W3 fill:#9C27B0,color:#fff
Web 1.0 (1991–2004) — The Read-Only Web:
Static Pages
HTML pages with fixed content — no interaction
Like an online encyclopedia that never changesRead Only
Users ONLY consume content — no creating
No commentsno likesno uploadsContent Created by
Only website owners (companies)
Users had no voiceWeb 2.0 (2004–Present) — The Interactive Web:
User-Generated Content
Anyone can create and publish content
YouTubeWikipediaRedditInstagramSocial Media
Connect, share, interact with others
FacebookTwitter/XLinkedInRich Applications
Web apps feel like desktop apps
GmailGoogle DocsCanvaMobile-First
Designed for smartphones
Appsresponsive designWeb 2.0 Examples:
| Platform | Web 2.0 Feature |
|---|---|
| YouTube | Anyone can upload videos (user-generated!) |
| Wikipedia | Anyone can edit articles |
| User profiles, posts, comments, reactions | |
| Blogs | Anyone can write and publish |
| Google Maps | User reviews, photos, contributions |
Web 3.0 (Emerging) — The Semantic / Decentralised Web:
Semantic Web
Web that computers can READ and UNDERSTAND
AI can understand contextnot just keywordsDecentralised
No single company controls your data
Blockchain-basedusers own their dataAI-Powered
Intelligent personalisation and search
ChatGPTpersonalised recommendationsMetaverse
3D immersive web experiences
VR/AR platformsvirtual meetings"Differentiate between Web 1.0 and Web 2.0" — 2-mark question. Web 1.0 was a read-only web where content was created only by website owners and users could only view static pages. Web 2.0 is a read-write web where users can create, share, and interact — enabling social media, blogs, wikis, and user-generated content. Web 2.0 introduced dynamic, interactive applications like Gmail, YouTube, and Facebook.
8.4.8 HTML — HyperText Markup Language 📝
HTML is the standard language for creating web pages. It defines the structure and content of a webpage using "tags".
What HTML does:
Structure → what's on the page and its organisation
Content → the actual text, images, links
Semantics → what elements MEAN (heading, paragraph, list)
HTML is NOT programming — it's MARKUP! It doesn't have logic or calculations. It just describes what should appear on a page.
Basic HTML Structure:
<!-- basic_page.html -->
<!DOCTYPE html> <!-- Tells browser: this is HTML5 -->
<html> <!-- Root element — wraps everything -->
<head> <!-- Metadata (not visible) -->
<title>My Web Page</title>
</head>
<body> <!-- Visible content goes here -->
<h1>Welcome to Class 12 CS!</h1>
<p>Python functions are <b>awesome</b>!</p>
<a href="https://csip12.in">Visit csip12.in</a>
<img src="python_logo.png" alt="Python Logo">
</body>
</html>
Important HTML Tags for Exams:
| Tag | Purpose | Example |
|---|---|---|
<html> |
Root element | Wraps entire page |
<head> |
Metadata container | Not visible on page |
<body> |
Page content | Everything you see |
<h1> to <h6> |
Headings (6 levels) | <h1>Big Heading</h1> |
<p> |
Paragraph | <p>Text here</p> |
<a href="url"> |
Hyperlink | <a href="csip12.in">Click</a> |
<img src="file"> |
Image | <img src="photo.jpg"> |
<b> |
Bold text | <b>Bold</b> |
<i> |
Italic text | <i>Italic</i> |
<ul> / <ol> |
Unordered / Ordered list | Bullet or numbered |
<li> |
List item | Item inside list |
<table> |
Table | <table>...</table> |
<form> |
Form container | Login, registration |
Hyper
Supports non-linear navigation (links can jump anywhere)
Click link → jump to any pageText
Content of web pages is primarily text
Written contentparagraphsheadingsMarkup
Text is "marked up" with tags that describe it
marks heading
marks paragraph
Language
A standardised language browsers understand
All browsers can display HTML8.4.9 XML — eXtensible Markup Language 📊
XML is a flexible markup language designed for storing and transporting structured data — NOT for display (unlike HTML). XML lets you create your OWN custom tags!
HTML vs XML — The Critical Difference:
| Feature | HTML | XML |
|---|---|---|
| Purpose | DISPLAY data in browsers | STORE and TRANSPORT data |
| Tags | Predefined (<h1>, <p>, <img>) |
You CREATE your own! |
| Self-descriptive? | ❌ No | ✅ Yes — data explains itself |
| Case Sensitive | No | ✅ Yes (<Name> ≠ <name>) |
| Browser Display | ✅ Renders content visually | Raw text (no styling) |
| Use Case | Web pages | Data exchange, configuration |
XML Example — Student Data:
<!-- student_data.xml -->
<?xml version="1.0" encoding="UTF-8"?>
<students>
<student id="001">
<name>Priya Sharma</name>
<class>12</class>
<section>A</section>
<percentage>91.5</percentage>
</student>
<student id="002">
<name>Arjun Kumar</name>
<class>12</class>
<section>B</section>
<percentage>88.0</percentage>
</student>
</students>
See how every tag is self-explanatory?
<name>contains the name,<percentage>contains marks! An application reading this XML instantly understands what each piece of data means — without a separate manual!
XML Use Cases:
| Use Case | Example |
|---|---|
| Data Exchange | Web services (APIs) sending data between apps |
| Configuration | Android Manifest, Java project files (pom.xml) |
| RSS Feeds | News feeds, blog post updates |
| Office Files | .docx and .xlsx are actually zipped XML! |
| SVG Images | Scalable Vector Graphics are XML-based |
"What is the difference between HTML and XML?" — 2-mark question. HTML uses predefined tags to display content in browsers. XML uses custom user-defined tags to store and transport data in a self-descriptive format. HTML is for presentation; XML is for data storage and exchange.
8.4.10 DHTML — Dynamic HTML ⚡
DHTML (Dynamic HTML) is NOT a new language — it's a combination of existing technologies working together to create interactive, dynamic web pages!
DHTML = HTML + CSS + JavaScript + DOM (Document Object Model)
↑ ↑ ↑ ↑
Structure Styling Behaviour Access/Modify
(content) (looks) (animation, (page elements
interaction) programmatically)
What each component does:
HTML
Defines the structure and content
ParagraphsheadingsimagesCSS
Defines styles, colours, layouts
FontscolourspositionsJavaScript
Adds behaviour and interactivity
Animationsform validationclick eventsDOM
Provides programmatic access to page elements
JavaScript can find and change any element!DHTML in Action — Examples:
| Feature | How DHTML Creates It |
|---|---|
| Image Carousel/Slider | JavaScript changes HTML <img> src every 3 seconds |
| Dropdown Menu | CSS hidden by default; JavaScript shows on hover |
| Form Validation | JavaScript checks input before submission |
| Popup/Modal | JavaScript changes CSS display from none to block |
| Dark/Light Mode Toggle | JavaScript changes CSS class on page body |
| Animated Counter | JavaScript increments number over time |
DHTML Example Concept:
<!-- dhtml_demo.html — Button that changes colour -->
<!DOCTYPE html>
<html>
<head>
<style>
#myBtn { background-color: blue; color: white; padding: 10px; }
</style>
</head>
<body>
<button id="myBtn" onclick="changeColour()">Click Me!</button>
<script>
function changeColour() {
// JavaScript accessing DOM to change CSS
document.getElementById("myBtn").style.backgroundColor = "red";
document.getElementById("myBtn").innerHTML = "Colour Changed!";
}
</script>
</body>
</html>
"What is DHTML? What technologies does it use?" — 2-mark question. DHTML (Dynamic HTML) is a combination of HTML, CSS, JavaScript, and DOM that enables creation of interactive and dynamic web pages. Unlike static HTML which cannot change after loading, DHTML allows web pages to respond to user actions, animate elements, and update content without reloading the page.
8.4.11 Protection Methods 🔒
As we connect more devices and share more data online, network and web security becomes critical. Here are the key protection methods!
🔥 Firewall
A Firewall is a security system (hardware or software) that monitors and controls incoming and outgoing network traffic based on predetermined security rules. It creates a protective barrier between a trusted internal network and untrusted external networks.
graph LR
INTERNET["🌐 Internet\n(Untrusted — threats!)"]
FW["🔥 FIREWALL\n✅ Allows safe traffic\n❌ Blocks threats\n📋 Applies rules"]
LAN["🏠 Your LAN\n(Trusted — safe)"]
PC["💻 Your PCs"]
INTERNET -->|"All traffic"| FW
FW -->|"Only allowed\ntraffic passes"| LAN
LAN --- PC
style INTERNET fill:#F44336,color:#fff
style FW fill:#FF9800,color:#fff
style LAN fill:#4CAF50,color:#fff
Types of Firewalls:
Packet Filtering
Checks source/destination IP, port, protocol against rules
Fast but basic — Layer 3/4 onlyStateful Inspection
Tracks active connections and their state
Smarter — knows if packet belongs to established connectionApplication Layer (WAF)
Understands application-level data (HTTP, FTP)
Can detect SQL injectionXSS attacksHardware Firewall
Physical device — dedicated firewall appliance
Cisco ASAFortinet FortiGateWhat Firewalls Can/Cannot Do:
| Can Do | Cannot Do |
|---|---|
| Block unauthorised access | Protect against insider threats |
| Filter by IP, port, protocol | Detect encrypted malware |
| Log network activity | Stop already-installed malware |
| Block specific websites | Prevent social engineering |
| Prevent certain attacks | Guarantee 100% security |
🍪 Cookies
Cookies are small text files stored by websites on your browser/device to remember information about you and your visit.
graph LR
BROWSER["🌐 Your Browser"]
SERVER["🖥️ Web Server"]
BROWSER -->|"First visit:\nNo cookie"| SERVER
SERVER -->|"Sets cookie:\nSet-Cookie: user=Arjun;\nsession=xyz123"| BROWSER
BROWSER -->|"Second visit:\nSends cookie back"| SERVER
SERVER -->|"Recognises you!\nWelcome back, Arjun!"| BROWSER
style BROWSER fill:#4CAF50,color:#fff
style SERVER fill:#2196F3,color:#fff
Types of Cookies:
Session Cookies
Temporary — deleted when browser closes
Keeps you logged in during one sessionPersistent Cookies
Stay on disk until expiry date or manual deletion
"Remember me" loginshopping cartThird-Party Cookies
Set by websites OTHER than the one you're visiting
Used by advertisers to track you across the web!Secure Cookies
Only sent over HTTPS connections
Login tokensbanking sessionsWhat Cookies Are Used For:
| Use | Example |
|---|---|
| Authentication | Staying logged into Gmail without re-entering password |
| Shopping Cart | Items remain in cart across pages |
| Preferences | Remembering dark mode, language, font size |
| Analytics | Google Analytics counting page visits |
| Advertising | Facebook tracking you across the web (controversial!) |
While session and persistent cookies are mostly harmless and helpful, third-party cookies allow advertisers to build a profile of your browsing habits across thousands of websites. This is why browsers now ask for "Cookie Consent" — GDPR (EU privacy law) requires it! Most modern browsers are phasing out third-party cookies.
🔐 Encryption
Encryption converts readable data (plaintext) into unreadable scrambled form (ciphertext) that can only be decoded with the correct key.
Plaintext: "Hello Class 12!"
↓ Encrypt with key
Ciphertext: "Xr8!@kPz#9mQ2Yx"
↓ Decrypt with key (at receiver)
Plaintext: "Hello Class 12!"
Types used in Web:
SSL/TLS
Encrypts web traffic (HTTPS)
Your browser → Web server (the padlock 🔒!)Public Key (RSA)
Two keys: public (share freely) + private (keep secret)
Used in digital certificatesHTTPSAES
Symmetric encryption — fast, used for bulk data
WiFi encryption (WPA2/WPA3)🕵️ Hackers and Crackers
Hacker (original meaning): A skilled programmer who explores systems — NOT necessarily malicious. The media misuses this term!
Types of Hackers:
- 🎩 White Hat (Ethical Hacker): Finds security vulnerabilities with permission — helps fix them! Bug bounty programmes!
- 🖤 Black Hat (Cracker): Breaks into systems illegally for theft, damage, personal gain — the actual "bad guys"!
- 🩶 Grey Hat: Somewhere in between — may break in without permission but report the flaw rather than exploit it
Cracker: Someone who breaks ("cracks") security systems, software copy-protection, or passwords with malicious intent. The proper term for what media calls "hacker"!
🛡️ Proxy Server
A Proxy Server acts as an intermediary between client and the Internet — requests go to proxy first, proxy forwards to Internet.
Privacy
Hides your real IP address from websites
Websites see proxy IPnot yoursCaching
Stores copies of popular web pages
Next user gets cached copy — faster!Content Filtering
Blocks access to certain websites
Schools/offices blocking social mediaBypass Restrictions
Access geo-blocked content
Accessing content blocked in your region🔐 VPN — Virtual Private Network
A VPN creates an encrypted "tunnel" through the Internet, making your connection secure and private even on public WiFi.
Your Device → [Encrypted Tunnel] → VPN Server → Internet → Website
Encryption
All your traffic is encrypted end-to-end
Safe on public WiFi at cafesairportsPrivacy
Your ISP can't see what sites you visit
True online privacyLocation Masking
Appear to be in another country
Access region-restricted contentCommon 2-mark question: "What is a Firewall? How does it protect a network?" Answer: A Firewall is a hardware or software security system that monitors and controls incoming and outgoing network traffic based on predefined security rules. It creates a protective barrier between a trusted internal network (LAN) and untrusted external networks (Internet), blocking unauthorised access while allowing legitimate traffic to pass.
8.4.12 Related Terms 📚
Here are some other common Web and Internet terms. They are not named in the CBSE syllabus, but they are useful background:
Content and Media Terms:
Blog
A regularly updated web diary/journal — "Web Log"
Personal opinionsnewstutorials — like csip12.in teaching notes!Podcast
Audio (or video) content distributed over the Internet via RSS
Downloadable episodes; subscribe to get new ones automaticallyWebcast
Streaming audio/video broadcast over the Internet
Live eventsYouTube Livetwitch.tvVlog
Video Blog — blog in video format
YouTube channelsInstagram Reels seriesCommerce and Business Terms:
E-Commerce
Buying and selling goods/services over the Internet
AmazonFlipkartIRCTC ticket bookingE-Banking
Banking services accessible via Internet
Internet bankingUPInet bankingE-Learning
Education delivered through electronic media
BYJU'sUnacademyKhan AcademyNCERT e-contentE-Governance
Government services delivered digitally
Passport portalAadhaarDigiLockerSocial and Community Terms:
Social Networking
Online platforms for connecting and sharing with others
FacebookInstagramLinkedInTwitter/XWiki
Collaborative website anyone can edit
Wikipedia — the world's largest wikiForum
Online discussion board where users post questions and replies
Stack OverflowRedditQuoraSearch Engine
Web service that searches and indexes web content
GoogleBingDuckDuckGoTechnical Terms:
| Term | Full Form | Meaning |
|---|---|---|
| ISP | Internet Service Provider | Company providing internet access (BSNL, Jio, Airtel) |
| IP | Internet Protocol | Rules for addressing and routing on the Internet |
| WWW | World Wide Web | System of interlinked hypertext documents |
| HTTP | HyperText Transfer Protocol | Rules for web page requests and responses |
| HTTPS | HTTP Secure | Encrypted HTTP using SSL/TLS |
| SSL | Secure Sockets Layer | Encryption protocol (now replaced by TLS) |
| TLS | Transport Layer Security | Modern, secure replacement for SSL |
| API | Application Programming Interface | Rules for apps to talk to each other |
| CDN | Content Delivery Network | Distributed servers for faster content delivery |
| Cache | — | Temporary storage for faster repeated access |
Additional Important Terms:
| Term | Explanation |
|---|---|
| Malware | Any malicious software — virus, worm, trojan, ransomware |
| Virus | Self-replicating malicious program that attaches to files |
| Worm | Self-replicating malware that spreads WITHOUT attaching to files |
| Trojan Horse | Disguised as legitimate software but carries malicious payload |
| Ransomware | Encrypts your files and demands ransom for the key |
| Phishing | Fake emails/websites that steal your login credentials |
| Spyware | Software that secretly monitors and reports your activity |
| Antivirus | Software that detects and removes malware |
| Spam | Unsolicited bulk email — junk mail of the Internet |
| Bandwidth Throttling | ISP intentionally slowing your internet speed |
One-liner definitions are common in 1-mark questions. Key terms: Blog (personal online journal), Podcast (downloadable audio/video series), E-commerce (online buying/selling), ISP (Internet Service Provider), Malware (malicious software), Phishing (fake website/email to steal credentials).
💼 Case Study Based Questions — Unit II: Computer Networks
Case Study 1: A school is setting up a new computer lab. They have 30 computers, need to share one internet connection, and want to share a common printer. The lab is on one floor of a 2-storey building.
Answer the following based on the case:
a) What type of network will this be? → LAN (Local Area Network) — within one building
b) Which topology would you recommend? → Star Topology — each PC connects to a central switch; one broken cable doesn't affect others; easy to troubleshoot
c) What central connectivity device would you recommend — Hub or Switch? Why? → Switch — intelligent, sends data only to the target PC (not broadcast like Hub), dedicated bandwidth per port, more secure
d) What transmission medium would you suggest? → UTP Cat 5e / Cat 6 (Twisted Pair Cable) — cheap, easy to install, 1 Gbps speed, sufficient for 100m within the building
e) How would all 30 computers share ONE internet connection? → Using a Router — connects the LAN to the ISP's WAN, provides NAT to share one public IP among all 30 computers
Case Study 2: An organisation in Durgapur wants to connect with its branch offices in Kolkata and Asansol, and also provide employees with secure remote access from home.
Answer the following:
a) What type of network will connect the three offices? → WAN (Wide Area Network) — connects geographically distant locations
b) What device at each office handles inter-city data routing? → Router — routes packets between the office LAN and the WAN
c) How can employees securely access the company network from home? → VPN (Virtual Private Network) — creates an encrypted tunnel over the Internet, allowing secure remote access
d) What protocol would their internal email system use? → SMTP for sending, IMAP for receiving (IMAP so employees can access emails from office PC and home laptop both)
⚠️ Common Errors and Misconceptions
| Misconception | Correct Fact |
|---|---|
| ❌ Hub and Switch are same thing | ✅ Hub broadcasts to ALL; Switch sends ONLY to target port (Layer 2) |
| ❌ Router and Switch are the same | ✅ Switch works within one network (MAC); Router connects different networks (IP) |
| ❌ Modem and Router are same | ✅ Modem converts signal types; Router routes between networks. Home "WiFi router" is actually modem + router + switch + WiFi AP combined! |
| ❌ HTTP and HTTPS are same | ✅ HTTPS adds SSL/TLS encryption — data is secure. Never enter passwords on HTTP! |
| ❌ POP3 and IMAP are same | ✅ POP3 downloads & deletes from server; IMAP keeps on server, syncs all devices |
| ❌ HTML is a programming language | ✅ HTML is a markup language — no logic, no variables, no calculations |
| ❌ Hacker always means criminal | ✅ White Hat Hackers are ethical security researchers. "Cracker" is the proper term for malicious hackers |
| ❌ Cookies are viruses/malware | ✅ Cookies are harmless text files (mostly). Third-party cookies are a privacy concern, not a security threat |
| ❌ WWW = Internet | ✅ WWW is one service ON the Internet. Internet also includes email, FTP, VoIP, gaming, etc. |
| ❌ Firewall makes network 100% secure | ✅ Firewall is one layer of security. Insider threats, phishing, encrypted malware can bypass it |
| ❌ Gateway = Router | ✅ Gateway translates between DIFFERENT protocol networks (all 7 layers). Router connects same-protocol networks (Layer 3). |
Network Devices — One-Line Summary:
- Modem → Converts Digital ↔ Analog signals (for telephone line internet)
- RJ-45 → Standard 8-pin Ethernet connector (not a device — a connector!)
- NIC → Network card with MAC address; every networked device has one
- Hub → Layer 1, broadcasts to ALL ports, dumb, obsolete
- Switch → Layer 2, reads MAC, sends to TARGET port only, smart ✅
- Repeater → Layer 1, amplifies weakened signal, extends cable range
- Bridge → Layer 2, connects two LAN segments, filters by MAC
- Router → Layer 3, reads IP, connects different networks, enables Internet ✅
- Gateway → Layer 4-7, protocol translator, connects different protocol networks
- WiFi Card → Wireless NIC, 2.4/5 GHz, IEEE 802.11
Protocols — Port Numbers to Memorise:
| Protocol | Port | One-line |
|---|---|---|
| HTTP | 80 | Web pages |
| HTTPS | 443 | Secure web |
| FTP | 20, 21 | File transfer |
| SMTP | 25 | Send email |
| POP3 | 110 | Download email (deletes from server) |
| IMAP | 143 | Sync email (keeps on server) |
| Telnet | 23 | Remote terminal (insecure!) |
| DNS | 53 | Domain → IP translation |
Internet Concepts — 10-Second Summary:
- WWW = Web pages on the Internet (HTTP); invented by Tim Berners-Lee, 1991
- URL = Complete web address (protocol://domain/path)
- DNS = Translates domain names to IP addresses
- Web 2.0 = Interactive, user-generated content (YouTube, Facebook)
- HTML = Structure of web pages; CSS = Style; JavaScript = Behaviour
- DHTML = HTML + CSS + JS + DOM = Interactive dynamic web pages
- XML = Custom tags for data storage/exchange (not for display!)
- Firewall = Controls incoming/outgoing traffic based on rules
- Cookie = Small file stored by browser to remember your preferences/session
- VPN = Encrypted tunnel for private, secure Internet browsing
🎯 Sample Board Exam Questions
Q1: Very Short Answer [1 mark each]
a) Name the protocol used for secure web browsing. → HTTPS (HTTP Secure, using SSL/TLS)
b) At which OSI layer does a Router operate? → Layer 3 (Network Layer)
c) What port number does FTP use for data transfer? → Port 20
d) What does DHTML stand for? → Dynamic HTML
e) Name any one Web 2.0 website. → Any of: Facebook, YouTube, Wikipedia, Twitter, Instagram, Blogger
f) What is the full form of VoIP? → Voice over Internet Protocol
Q2: Short Answer [2 marks]
Q: Differentiate between a Hub and a Switch.
| Feature | Hub | Switch |
|---|---|---|
| OSI Layer | Layer 1 (Physical) | Layer 2 (Data Link) |
| Data Forwarding | Broadcasts to ALL ports | Sends ONLY to target MAC address port |
| Bandwidth | Shared among all | Dedicated per port |
| Intelligence | None | Uses MAC address table |
Q3: Short Answer [2 marks]
Q: Differentiate between POP3 and IMAP.
POP3 (Post Office Protocol 3, Port 110): Downloads emails from server to local device and by default deletes them from the server. Emails accessible on one device only. Ideal for users with one device and limited server storage.
IMAP (Internet Message Access Protocol, Port 143): Keeps emails on the server and synchronises across all devices. Reading on phone AND laptop shows the same inbox. Ideal for users with multiple devices.
Q4: Short Answer [3 marks]
Q: What is a Firewall? Explain its role in network security.
A Firewall is a hardware device or software system that monitors and controls incoming and outgoing network traffic based on predetermined security rules.
Role in Network Security:
- Access Control — Blocks unauthorised users from accessing the internal network
- Traffic Filtering — Allows only traffic matching defined rules (by IP, port, protocol)
- Attack Prevention — Blocks common network attacks like port scanning, DoS attacks
- Logging — Records all traffic attempts for security auditing
- Separation — Creates a protective barrier between trusted LAN and untrusted Internet
Q5: Short Answer [3 marks]
Q: Explain Web 2.0 with examples. How is it different from Web 1.0?
Web 1.0 (1991-2004): A read-only web where content was created only by website owners. Users could only view static, pre-built HTML pages. No user interaction, no user-generated content, no social features.
Web 2.0 (2004-present): A read-write interactive web where users can create, share, and interact with content. Key features include:
- User-Generated Content: Anyone can post videos (YouTube), edit wikis (Wikipedia), write blogs
- Social Media: Facebook, Twitter/X, Instagram — connecting people globally
- Rich Web Applications: Gmail, Google Docs — web apps that feel like desktop software
- Collaboration: Real-time collaborative editing, commenting, ratings
Examples: YouTube, Facebook, Instagram, Wikipedia, Blogger, Reddit
Q6: Output/Analysis Question [2 marks]
Q: Identify what protocol/device is described in each case:
a) Sita uploads her assignment files to her school's server using username and password, and lists the server's directories. → FTP (File Transfer Protocol)
b) Raju's home network is disconnected from the Internet even though all computers work fine on the local network. → Router has failed (Router connects LAN to Internet)
c) All computers in the lab see a message saying "Collision detected" — data is resent repeatedly. → Hub is being used (single collision domain; a Switch would prevent this)
d) Priya gets an email that says "Your SBI account is blocked. Click here to verify" — the link goes to a fake website. → Phishing attack
Q7: Write Short Notes [5 marks]
Q: Write short notes on: (a) Cookies, (b) VoIP, (c) HTML vs XML
(See Sections 8.4.11, 8.3.6, and 8.4.8/8.4.9 respectively)
✏️ Practice Problems
-
Your school wants to block students from accessing social media during school hours. Which network protection device/technology would you install, and where?
-
A company's IT team notices their network performance is terrible — all 50 computers share a Hub. They replace it with a managed Switch. Explain why performance improves.
-
Explain with a diagram how DNS resolves
www.cbse.gov.into an IP address (include all DNS hierarchy levels). -
Write a simple HTML page with: a heading "CBSE CS Notes", a paragraph about Python, a link to csip12.in, and an unordered list of 3 Python topics.
-
Your friend says "HTTP and HTTPS are the same thing — HTTPS just has a 'S' at the end." Correct your friend with a proper explanation.
-
Identify each: (a) Protocol to send email, (b) Protocol to securely access web, (c) Protocol for file download from server, (d) Protocol that keeps email on server for multiple devices.
-
A hacker breaks into a company's network and encrypts all their files, demanding ₹10 lakh to decrypt. What type of malware attack is this? What security measures could have prevented it?
-
Compare Web 1.0, Web 2.0, and Web 3.0 on four parameters in a table.
-
Trace the complete journey of data when you type "www.google.com" in your browser and press Enter — include DNS, TCP/IP, HTTP, and the role of your Router.
-
A company in Delhi wants to allow its 500 employees to work from home securely, accessing the company's internal file servers. Which technology would you recommend and why?