Skip to content
🎯⭐ INTERACTIVE LESSON

The Internet & Protocols

Learn step-by-step with interactive practice!

The Internet & Protocols - Complete Interactive Lesson

Part 1: TCP/IP, HTTP, and How the Internet Works

🔗 Internet Protocols

Part 1 of 7 — TCP/IP, HTTP, and How the Internet Works


The Internet Runs on Open Protocols

The Internet is a computer network made of interconnected networks that use standardized, open (nonproprietary) communication protocols. A protocol is an agreed-upon set of rules that specify the behavior of a system. Because the Internet's protocols are open, anyone can connect a new device by following them.

ProtocolJob
IP (Internet Protocol)Gives each device an address and routes packets across networks
TCP (Transmission Control Protocol)Makes sure all packets arrive, asks for lost ones to be resent, and puts the data back in order
UDP (User Datagram Protocol)Sends packets without checking that they arrive or keeping them in order; less waiting, but some data may be lost
HTTP (HyperText Transfer Protocol)The protocol the World Wide Web uses to request and deliver pages

🔑 IP, TCP, and UDP are common protocols on the Internet. HTTP is a protocol used by the World Wide Web, which runs on top of the Internet.


IP Addresses and Scalability

Every device on the Internet needs an address, and an address is just a group of bits.

  • IPv4 uses 32-bit addresses: 2322^{32}, about 4.3 billion addresses
  • IPv6 uses 128-bit addresses: 21282^{128}, vastly more
  • IPv6 was created because the Internet keeps growing and IPv4 addresses are running out; the Internet was designed to be scalable

Concept Check 🎯

How a Web Page Reaches You

When you open a web page:

  1. HTTP request: your browser sends a request for the page to the web server
  2. Packets: the server's response is split into chunks of data, each wrapped in a packet with metadata
  3. Routing: IP routes each packet across the Internet; different packets may take different paths
  4. Reassembly: TCP checks that every packet arrived, asks for missing ones again, and puts the data in order
  5. Display: the browser shows the page

TCP vs. UDP

ProtocolEvery packet arrives?Kept in order?Typical use
TCPYes, lost packets are resentYesWeb pages, email, file transfer
UDPNo guaranteeNo guarantee (packets may arrive in any order)Live video and voice calls, online games

Why UDP Sometimes?

  • Video calls: a few dropped frames are better than waiting for missing data to be resent
  • Games: an old position update is useless even if it arrives

Encryption and Certificate Authorities

  • Web traffic sent with plain HTTP can be read by anyone who intercepts it; HTTPS encrypts it
  • Certificate authorities issue digital certificates that validate the ownership of the encryption keys used in secure communications
  • The lock icon in your browser means the connection is encrypted and the site's certificate was validated

Applied Recall ✍️

  1. An agreed-upon set of rules that specify the behavior of a system is called a _______.

  2. TCP guarantees reliable delivery; _______ makes no such guarantee and is used for live video calls.

  3. HTTPS adds _______ to HTTP, so intercepted data cannot be read.

Protocol Selection 🔍

AP Exam Strategy: Internet Protocols

  • A protocol is an agreed-upon set of rules; the Internet's protocols are open
  • TCP = every packet arrives and data are put in order. UDP = no such guarantee, less waiting
  • IP addresses and routes packets; HTTP is the Web's protocol
  • IPv4 (32-bit) vs IPv6 (128-bit): more bits, more addresses, so the Internet can keep scaling
  • Encryption protects data in transit; certificate authorities validate encryption keys

AP-Style Application 🎯

Part 2: Key Processes

🌐 The Internet & Protocols

Part 2 of 7 — Key Processes


How Information Travels The Internet

  1. Information is passed through the Internet as a data stream.
  2. The stream is split into chunks of data, and each chunk is wrapped in a packet.
  3. Each packet carries metadata used to route it from origin to destination and to reassemble the data.
  4. Routing is dynamic: each packet's path is found as it travels, not fixed in advance.
  5. Packets may arrive in order, out of order, or not at all, so the receiver uses the metadata (and TCP) to rebuild the original data.
StepWho does it
Split data into packetsThe sending device
Find a path for each packetRouters along the way
Put packets back in order, ask for missing onesTCP on the receiving device

Concept Check 🎯

Worked Example: Packets Out of Order

A message is split into five packets, numbered 1 to 5 in their metadata. They arrive in this order: 2, 1, 5, 3. Packet 4 never arrives.

  • The receiver uses the numbers in the metadata to place packets 1, 2, 3, and 5.
  • With TCP, the receiver notices that packet 4 is missing and asks for it to be sent again, then rebuilds the full message in order.
  • With UDP, there is no guarantee: the missing data is simply lost, and the program must cope (a video call might skip a frame).

Why Open Protocols?

  • Anyone can join: because the protocols are open (nonproprietary), any company or person can build a device that connects to the Internet.
  • Access depends on connecting a device to an Internet-connected device.
  • Scalability: the Internet was designed so it can grow to meet new demands, from a few thousand devices to billions.

This is abstraction at scale: a person sending a message does not need to know how it is split up, which path each packet takes, or how it is put back together.

Applied Recall ✍️

  1. A set of agreed-upon rules for how computers communicate is called a _______.

  2. The data that a packet carries for routing and reassembly is called _______.

  3. The basic unit of data that travels across the Internet is called a _______.

Targeted Practice 🔍

AP Exam Strategy: How Data Travels

  • Data stream → chunks → packets (data + metadata) → routed dynamically → reassembled.
  • Packets may arrive in order, out of order, or not at all.
  • "Reliable + ordered" → TCP. "Fast, real-time, can drop packets" → UDP. Routing → IP.
  • Open protocols make it easy to connect new devices; the Internet was designed to scale.

AP-Style Application 🎯

Part 3: Patterns & Examples

🌐 The Internet & Protocols

Part 3 of 7 — Patterns & Examples


The Internet vs. the World Wide Web

People often use the two names as if they meant the same thing. They do not.

InternetWorld Wide Web
What it isA computer network of interconnected networksA system of linked pages, programs, and files
ProtocolsIP, TCP, UDPHTTP
RelationshipCarries data for many usesUses the Internet

Email apps, video-call apps, and online games all use the Internet. Only some of what happens on the Internet is the Web.

Concept Check 🎯

Patterns in Packet Delivery

Packets may arrive at the destination in order, out of order, or not at all.

What happensWith TCPWith UDP
All packets arrive in orderData delivered as isData delivered as is
Packets arrive out of orderPut back in order using metadataNo guarantee of order
A packet never arrivesIt is requested againThat data is lost

A Single Server Is a Weak Point

If a service runs on one server, that server is a single point of failure: when it goes down, the service is gone. Adding redundant servers, so that another can take over, makes the service fault-tolerant. The Internet itself follows the same idea with redundant paths between devices.

Scalability in Action

The Internet grew from a few thousand connected devices to billions without being redesigned, because it was built to scale: open protocols let anyone add devices, and routing finds paths through whatever networks are connected.

Applied Recall ✍️

  1. The World Wide Web uses the _______ protocol.

  2. A web browser and an email app both send their data over the _______.

  3. Packets may arrive in order, out of order, or not at _______.

Targeted Practice 🔍

AP Exam Strategy: Patterns

  • Internet = network of networks (IP, TCP, UDP). Web = linked pages, programs, files (HTTP). The Web uses the Internet.
  • Packets: in order, out of order, or not at all. TCP repairs order and loss; UDP does not.
  • "Single point of failure" → add redundancy.
  • "How did the Internet grow so large?" → it was designed to be scalable, with open protocols.

AP-Style Application 🎯

Part 4: Connections & Interactions

🌐 The Internet & Protocols

Part 4 of 7 — Connections & Interactions


Internet Connections Across the Course

The Internet is the substrate everything else runs on.

ConnectionWhy it matters
Internet ↔ Binary (BI 2)All packets are bit sequences.
Internet ↔ Algorithms (BI 3)Routing, finding a path, is an algorithm.
Internet ↔ Security (BI 5)Encryption protects traffic; certificate authorities establish trust.
Internet ↔ Impact (BI 5)Global reach amplifies both benefit and harm.

Concept Check 🎯

Open Standards As The Internet's Superpower

Anyone can implement TCP/IP. Any vendor's router can interoperate with any other's. Because the protocols are open, users can easily connect additional devices, which is a big reason the Internet scaled to billions of devices.

Routing As An Algorithm

Routing is the process of finding a path from sender to receiver, and on the Internet it is dynamic. Paths adapt to:

  • New networks coming online.
  • Failed devices or connections.
  • Busy connections, shifting traffic to other paths.

If a device or connection fails, later data are sent along a different route if one exists, so the network keeps working. This is fault tolerance, made possible by redundant paths.

Encryption On The Internet

Data sent over public networks can be intercepted, analyzed, and modified. Encryption encodes data to prevent unauthorized access; only someone with the right key can decrypt it. When you see https:// and a padlock:

  • The traffic between you and the site is encrypted.
  • The site presented a digital certificate. Certificate authorities issue these certificates to validate who owns the encryption keys, based on a trust model.

Global Reach And Impact

A single webpage can reach billions instantly. This is the Internet's greatest gift and gravest danger:

  • Beneficial: open access to knowledge, global collaboration.
  • Harmful: misinformation spreads at the same global speed.

Big Idea 5 examines these consequences.

Applied Recall ✍️

  1. The "S" in HTTPS stands for _______ (the word that tells you the connection is encrypted).

  2. An open _______ enables any device to join the Internet.

  3. When data are rerouted after a router fails, this is made possible by _______ paths between devices.

Targeted Practice 🔍

AP Exam Strategy: Cross-Topic Internet Questions

  • "Open standards" + "interoperability" + "scalability" = Internet design wins.
  • HTTPS = HTTP + encryption, with a certificate from a certificate authority.
  • Dynamic routing + redundant paths = fault tolerance.
  • A question about "single point of failure" is asking about redundancy / distributed design.

AP-Style Application 🎯

Part 5: Scalability and Growth

🌐 The Internet & Protocols

Part 5 of 7 — Scalability and Growth


Built to Scale

The scalability of a system is its capacity to change in size and scale to meet new demands. The Internet was designed to be scalable, and it has grown from a few thousand devices to billions.

Design featureHow it helps the Internet grow
Open protocolsAnyone can connect new devices by following the rules.
Dynamic routingPaths are found as data travel, so new networks can join at any time.
Redundant pathsExtra routing options increase reliability and help the Internet scale to more devices and more people.
PacketsMany conversations share the same connections at once.

Concept Check 🎯

Addresses Are Bits

An address is a group of bits, so the number of possible addresses is 2n2^{n} for n-bit addresses.

VersionBitsPossible addresses
IPv4322322^{32} ≈ 4.3 billion
IPv612821282^{128} ≈ 3.4×10383.4 \times 10^{38}

Each extra bit doubles the number of addresses, so going from 32 to 128 bits multiplies the count by 2962^{96}. Moving to longer addresses is one way the Internet scales to meet new demand.

More Devices, More to Protect

Smart sensors, cameras, and thermostats are computing devices too. Every real-world system has errors or design flaws that can be exploited, and regular software updates help fix them. A network with thousands of connected devices needs every one of them kept up to date.

Encryption Everywhere

As more personal information travels over the Internet, more of it is encrypted. Data sent over public networks can be intercepted, so web sites now commonly use HTTPS, with digital certificates issued by certificate authorities.

Applied Recall ✍️

  1. IPv4 addresses are _______ bits long.

  2. The successor with 128-bit addresses is _______.

  3. A system's capacity to change in size and scale to meet new demands is called _______.

Targeted Practice 🔍

AP Exam Strategy: Internet Growth

  • The Internet was designed to be scalable; open protocols and dynamic routing let it grow.
  • n-bit addresses → 2n2^{n} addresses; each extra bit doubles the count.
  • Redundant paths improve reliability AND help the Internet scale.
  • More connected devices means more systems that need regular updates.

AP-Style Application 🎯

Part 6: Problem-Solving Workshop

🌐 The Internet & Protocols

Part 6 of 7 — Problem-Solving Workshop


Internet & Protocols Workshop

Apply packets, protocols, routing, and fault tolerance to scenarios.

Concept Check 🎯

Worked Scenario 1: Choose A Protocol

Use caseBest fit
File downloadTCP (every byte must arrive).
Live video callUDP (low delay; small drops tolerated).
Online banking pageTCP, with encryption (HTTPS).
Software updateTCP (must arrive complete and correct).

Worked Scenario 2: Reassemble A Message

A message is split into packets 1 to 6. They arrive as 4, 1, 6, 2.

  • Packets 3 and 5 are missing.
  • With TCP, the receiver requests packets 3 and 5 again, then uses each packet's metadata to put all six in order: 1, 2, 3, 4, 5, 6.
  • With UDP, packets 3 and 5 are simply lost.

Worked Scenario 3: Will It Keep Working?

Network: Home–R1, Home–R2, R1–R3, R2–R3, R3–Server.

  • If R1 fails, data go Home → R2 → R3 → Server. Still works (redundant path).
  • If R3 fails, every path is broken. R3 is a single point of failure.
  • Adding a connection R2–Server would make the network tolerate the loss of R3.

Applied Recall ✍️

  1. A real-time game uses _______ for low-delay position updates.

  2. A banking page is sent with HTTPS so that the data are _______.

  3. A message is split into 6 packets, and only packets 1, 2, 4, and 6 arrive. With TCP, how many packets does the receiver request again? _______

Targeted Practice 🔍

AP Exam Strategy: Protocol Workshops

  • Ask "what does this app prioritize?": complete data or low delay?
  • Complete and in order → TCP. Real-time, drops tolerated → UDP. Routing → IP. Web pages → HTTP.
  • Track packets by number: which arrived, which are missing, what order they go back in.
  • For network diagrams, look for a device or connection that is on every path.

AP-Style Application 🎯

Part 7: AP Review

🌐 The Internet & Protocols

Part 7 of 7 — AP Review


AP Exam Recap — Internet & Protocols

The protocol facts and architectural ideas most likely to appear on the exam.

Concept Check 🎯

One-Line Definitions

TermDefinition
ProtocolAn agreed set of rules for communication.
PacketA chunk of data plus metadata used for routing and reassembly.
IPAddresses packets and routes them across networks.
TCPAdds reliable, ordered delivery: lost packets are resent.
UDPNo guarantee of delivery or order; less waiting.
HTTPThe protocol of the World Wide Web.
HTTPSHTTP with encryption, using a certificate from a certificate authority.
World Wide WebA system of linked pages, programs, and files that uses the Internet.
RouterA device that forwards packets toward their destination.
ScalabilityThe capacity to change in size and scale to meet new demands.
IPv6Successor to IPv4 with 128-bit addresses.

Common Exam Pitfalls

  • "TCP and IP are the same protocol." (No — TCP makes delivery reliable, IP routes packets.)
  • "UDP is unreliable, so it's bad." (No — it's a deliberate trade-off for low delay.)
  • "HTTPS protects me from any threat." (No — it protects data in transit, not from phishing or compromised servers.)
  • "The Internet and the Web are the same thing." (No — the Web uses the Internet.)

Applied Recall ✍️

  1. The protocol used by the World Wide Web is _______.

  2. The transport protocol that guarantees ordered, reliable delivery is _______.

  3. The protocol used for real-time apps that prefer low delay over resending lost data is _______.

Targeted Practice 🔍

Final Exam Tips

  • Be ready to identify: TCP vs UDP, IP vs HTTP, HTTPS vs HTTP, the Internet vs the Web.
  • Packets carry data + metadata and may arrive in order, out of order, or not at all; TCP adds reliability.
  • Open protocols and a scalable design let the Internet grow; redundant paths make it fault-tolerant.
  • HTTPS protects data in transit; it does not stop phishing or a compromised server.

AP-Style Application 🎯