Jump to

    Lessons / Lesson 2, Gibson & Shelley, Ch. 3

    Switches: unicast, broadcast and locking the ports

    A switch is the hallway monitor of a network: it delivers each message to the right door, and a hardened one won’t let strangers plug in.

    Poster: Switches. A note passed to one friend (unicast), a megaphone in the dining hall stopped at a router gate (broadcast), a hallway monitor checking badges (port security), and a wall socket next to doors numbered 22, 53 and 443 (physical vs logical ports).

    Tap any panel to explore it.

    Like you’re 10

    There are two ways to share a message at school. Unicast is passing a folded note to one friend. Broadcast is standing in the dining hall and shouting “Free pizza in the gym!” so everyone hears.

    A switch is the school’s hallway monitor. It knows exactly which classroom each pupil sits in, so when a note arrives it walks it straight to the right door instead of shouting it everywhere.

    Port security is the hallway monitor checking name badges at each classroom door: only the pupils who belong in that room get in. But badges can be copied, which is why a clever school checks more than the badge.

    Grown-up version

    Delivery types:

    TypeWho receives itExample
    UnicastOne specific deviceLoading a web page
    BroadcastEvery device on the local networkA DHCP request asking “Is there a server out there?”
    MulticastA group of devices that opted inIPv6 neighbour discovery, video streams

    Broadcasts don’t cross routers. Each router interface marks the edge of a broadcast domain.

    How a switch works: it learns which MAC address (a device’s hardware ID) sits behind each port and keeps a MAC address table. Unicast frames go only to the right port; broadcasts go out of every port.

    Hardening a switch:

    • Port security: limit how many MAC addresses each port will accept, optionally “sticking” to the first one it sees, and shut the port if a stranger appears.
    • MAC filtering: allow only listed MAC addresses. Easy to defeat, because MAC addresses can be spoofed.
    • 802.1X: the strong option. A device must prove its identity, with a certificate or credentials, before the port opens. This is network access control (NAC).
    • Disable unused ports and put them in an unused VLAN, so an empty wall socket in a meeting room isn’t a free way in.

    Physical vs logical ports:

    • A physical port is a socket on a switch, router or computer that you plug a cable into.
    • A logical port is a number that identifies a service on a device: 22 for SSH, 53 for DNS, 443 for HTTPS. Hardening means closing every logical port that isn’t needed.

    A real-world example

    Penetration testers, hired to break in legally, often walk into an office with a small device the size of a phone charger, plug it into a spare wall socket behind a printer, and leave. If the port isn’t locked down, the device quietly gives them remote access to the internal network from the car park.

    Why a buyer cares

    • The risk it reduces: unknown devices joining the network, from a visitor’s laptop to an attacker’s planted device, and network-wide slowdowns from misused ports.
    • Who owns it at a company: the network team, with security setting the policy.
    • What gets bought: network access control (Cisco ISE, HPE Aruba ClearPass, Forescout) to check every device before it connects, and managed switches with security features built in.
    • A good discovery question: “If someone plugged an unknown device into a meeting room socket today, would anything stop it or alert you?”

    The one thing to remember

    Unicast is a note to one friend, broadcast is a shout to everyone. A switch delivers notes to the right door, and port security decides who may plug in.

    Buyer score

    4.5/10

    Switch hardening is configuration, not a purchase. The money is in network access control, which checks every device before it gets on.

    Share on LinkedIn
    BudgetIs there a product category companies buy for this?
    1.5/2.5
    PainDoes it cause breaches or outages people have heard of?
    1/2.5
    PressureDo regulators, insurers or auditors demand it?
    1/2.5
    OwnerIs there a clear buyer who is judged on it?
    1/2.5

    See every topic ranked by buyer score

    Check yourself

    3 quick questions. Get them all right and this lesson is marked as learned.

    1. 1A device sends one message that every device on the local network receives. What is this called?

    2. 2Why is MAC filtering a weak control on its own?

    3. 3Which control makes a device prove its identity before a switch port opens?

    Revision cards

    For later: answer out loud first, then check.

    1What is the difference between unicast and broadcast?

    Unicast goes from one device to one specific device. Broadcast goes from one device to every device on the local network.

    2Do broadcasts cross routers?

    No. A router marks the edge of a broadcast domain, so broadcasts stay on the local network. IPv6 doesn’t use broadcast at all; it uses multicast instead.

    3How does a switch know which port to send a frame to?

    It learns which MAC address sits behind each port by watching traffic, and stores this in its MAC address table.

    4Why is MAC filtering a weak control on its own?

    MAC addresses can be changed in software in seconds, so an attacker can copy an approved device’s MAC address.

    5What is the difference between a physical port and a logical port?

    A physical port is the socket you plug a cable into. A logical port is a number, such as 443 for HTTPS, that identifies a service on a device.

    Your progress is saved on this device only.

    Tap the image to zoom

    1Unicast

    Unicast sends a frame to one specific device. The switch looks up which port leads to it in its MAC address table.

    Swipe for panel 2 →

    2Broadcast

    A broadcast reaches every device on the local network. Routers mark the edge, and IPv6 has no broadcast at all.

    Swipe for panel 3 →

    3Port Security

    Port security limits which devices each switch port accepts. Badges can be copied (MAC spoofing), so 802.1X is the strong version.

    Swipe for panel 4 →

    4Physical vs Logical Ports

    A physical port is a socket for a cable. A logical port is a number for a service, like 22 for SSH or 443 for HTTPS.