Start free →
Cybersecurity · Lesson 3
0 XP
Lesson 3 of 2015 minBeginner

The internet, explained with a courier.

Every attack in the world travels over a network. So today we'll follow one Instagram message from your phone in Hyderabad to a server far away, step by step. Think of it as sending a parcel.

Your message is a parcel

Say you send a photo to your cousin in Dubai. Your phone doesn't send it as one big piece. It cuts it into many small packets, like packing a big order into many small boxes. Each box gets a label: where it's from, where it's going, and its number (box 3 of 50). The boxes may travel by different roads and arrive in a different order, and your cousin's phone puts them back together.

The rules for labelling, sending and re-assembling these boxes are called protocols. The most famous pair is TCP/IP. You don't need to memorise how they work yet, just remember: the internet moves data in small labelled packets.

IP address: the house address

Every device on the internet needs an address so packets know where to go. That address is the IP address, something like 49.205.xx.xx.

But here's a smart trick. Think of an apartment building in Banjara Hills:

That's why everyone in your house appears to the outside world with the same public IP.

Ports: which door?

Reaching the right building isn't enough. A big post office has many counters: one for parcels, one for money orders, one for passports. On a computer these counters are ports, numbered from 0 to 65,535. Different services wait at different ports:

PortServiceIn simple words
80HTTPWebsites, without encryption
443HTTPSWebsites, with encryption (the padlock)
22SSHRemotely controlling a server's command line
53DNSLooking up website addresses
3389RDPRemote desktop on Windows

Remember the nmap command on our homepage? It knocks on every door (port) to see which ones are open. Attackers do this to find a way in. Defenders do it to close doors nobody needs. Same tool, different intention.

Quick check+10 XP

A company's server has port 3389 (remote desktop) open to the whole internet, but nobody there uses it. What should the security team do?

Right. Exposed remote-desktop ports are one of the most common ways ransomware gangs get in. Moving it to another number only hides it a little; scanners still find it. Closing what you don't need is called reducing the attack surface.

DNS: the internet's phonebook

Computers use numbers (IP addresses), but humans remember names like instagram.com. So before your phone can send the parcel, it asks a DNS server: "What's the address for instagram.com?" It's like asking the colony watchman, "Which house is Dr. Rizvi's?"

Now imagine a fake watchman who sends you to the wrong house. That's a real attack (DNS spoofing): you type the right name, but land on a fake site. It's one reason public Wi-Fi can be risky.

HTTP vs HTTPS: postcard vs sealed envelope

With HTTP, your data travels like a postcard: anyone handling it along the way can read it. With HTTPS, it travels in a sealed, locked envelope: people can see where it's going, but not what's inside. That's the padlock in your browser.

Careful, this trips up everyone

The padlock only means the envelope is sealed. It does not mean the person you're sending it to is honest. Scammers can get a padlock for sbi-kyc-update.online in five minutes. Always check the actual website name, not just the padlock.

Game: safe or not?

You're at an Irani café with free Wi-Fi. Look at each situation and decide.

Wi-Fi: "Cafe_Free_WiFi"Login page asks: "Enter your Gmail and password to get 2 hours of free internet."now

Not safe. No real Wi-Fi needs your Gmail password. This is a classic trick to steal accounts. Anyone can name their hotspot "Cafe_Free_WiFi".

Your browserYou open https://www.youtube.com on the café Wi-Fi to watch a lecture.now

Mostly safe. It's HTTPS on the correct domain, so the content of your traffic is encrypted. Watching a lecture on public Wi-Fi is fine.

Your browserYou log in to your bank app on the café Wi-Fi, and a pop-up says "Certificate error, continue anyway?"now

Not safe. Stop. A certificate warning on a bank can mean someone is sitting in the middle, reading your traffic. Switch to mobile data and never click "continue anyway" on banking.

Your task for today (10 min)

Find your own addresses. On a laptop: open Command Prompt (search "cmd") and type ipconfig. Find your IPv4 address (your private "flat number", probably starting with 192.168). Then search "what is my IP" in Google to see your public "building address". Notice they're different, and now you know why. Write both down; we'll use this idea again in the networking lessons.

Final check+20 XP

Which one is correct?

Correct. DNS is the phonebook. The padlock only means encrypted, not honest. And websites see your public IP, not your private one.

Lesson 3 complete!

Packets, IP addresses, ports, DNS and HTTPS: the five ideas behind every network attack. Next you'll type your first real Linux commands.

Next: Your first Linux commands →