A2.1.3 Describe the function of network devices.

A2.1.3 Describe the function of network devices. 
• Gateways, hardware firewalls, modems, network interface cards, routers, switches, wireless access points 
• How devices map to the layers of the TCP/IP model

The big idea

Every packet that reaches its destination has travelled through a chain of specialised devices, each assigned to a particular layer of the TCP/IP stack. Knowing what each device does and at which layer it operates is essential for designing, troubleshooting and securing a network.


Device functions and their position in the TCP/IP model

DevicePrimary functionTypical TCP/IP layer(s)*Design notes
Network Interface Card (NIC)Implements the host’s physical and data-link access (MAC addressing, frame check sequence, DMA to system RAM).

Direct Memory Access (DMA) is a computer architecture feature that allows peripheral hardware devices such as a Network Interface Card (NIC) to transfer data directly to and from main system RAM independently of the Central Processing Unit (CPU).
Network Interface (sometimes called Link)Each NIC has a unique MAC address; modern adapters offload checksum, segmentation and VLAN tagging.
Modem (“modulator–demodulator”)

Encodes digital bits onto an analogue or passband signal suitable for WAN media (DSL, cable, fibre, cellular) and reverses the process on receive.

If you tried to push a raw digital square wave down a 5-mile telephone line or a cable TV line without a modem, three major physical barriers would destroy the data:

  • Attenuation and Dispersion: As a square wave travels down a long wire, resistance and capacitance cause the sharp vertical edges of the wave to smear out and round over. Over distance, a crisp sequence of 1's and 0's turns into an unrecognizable, muddy electrical slope.

  • Bandwidth and Filtering Restrictions: Traditional copper telephone loops are choked to a narrow frequency band (roughly 300 Hz to 3,300 Hz) to optimize human speech. A raw digital bitstream contains high-frequency harmonics that fall completely outside this window and are filtered out entirely.

  • Noise and Interference: Long-distance lines pick up massive amounts of environmental noise (crosstalk from adjacent wires, electrical grid hum, radio frequency interference). A raw low-voltage digital pulse would be instantly drowned out by this noise floor.

Network Interface (Physical sub-layer)Performs line training, forward-error correction and rate adaptation; presents an Ethernet or USB logical interface upstream.
SwitchLearns MAC–port mappings and forwards Ethernet frames within a broadcast domain; isolates collision domains.Network Interface (Data-link sub-layer)Operates at Layer 2; a “Layer-3 switch” adds routing silicon and effectively becomes a router.
Wireless Access Point (WAP)Bridges IEEE 802.11 radio segments to a wired LAN, handling association, encryption (WPA 3), roaming and airtime scheduling.

Frame Translation (802.11 to 802.3): Wireless networks use IEEE 802.11 frames, which require four MAC addresses (source, destination, transmitter, receiver) and extra overhead to handle wireless quirks like hidden nodes. Wired networks use IEEE 802.3 Ethernet frames, which only require two MAC addresses. The WAP must strip off the 802.11 header, repackage the payload into an 802.11-to-Ethernet bridge format, and inject it onto the wired LAN.
Network InterfaceActs like a transparent switch between wired and wireless media; may implement controller-based management and RF optimisation.
RouterExamines IP headers and chooses the next hop using a routing table; decrements TTL, may perform NAT and QoS marking.InternetSeparates broadcast domains, enforces sub-networks; dynamic routing protocols (OSPF, BGP) maintain route tables.
Hardware Firewall

Inspects and filters traffic against a rule-set (5-tuple, stateful, DPI), optionally translating addresses (NAT) and terminating VPNs.

A 5-tuple is a set of five distinct values that uniquely identifies a specific network connection or session (a network flow) between two hosts across a network. Firewalls, routers, and load balancers use it to track and manage traffic flows.

The five components are:
  • Source IP Address: The IP of the sending device.
  • Destination IP Address: The IP of the receiving device.
  • Source Port: The port number on the sending device (e.g., ephemeral port.
  • Destination Port: The port number on the service/receiving device (e.g., for HTTPS).
  • Transport Layer Protocol: The protocol governing the packet (typically TCP or UDP).
Together, a unique combination like [192.168.1.50 : 54321 → 93.184.216.34 : 443 (TCP)] tells a firewall exactly which stream a packet belongs to.
 
A stateful firewall evaluates packets in the context of ongoing communication sessions, rather than inspecting each packet in isolation (stateless filtering).
  • How it works: It maintains a state table (connection tracking table). When an internal client initiates an outgoing connection (e.g., a TCP handshake to a web server), the firewall records the 5-tuple as an active, authorized session.
     
  • The Benefit: If unsolicited incoming packets arrive from the internet that do not match an existing, active entry in the state table, the firewall automatically drops them. It allows return traffic for established connections while blocking unrequested inbound attempts without requiring manual rules for every return port.

     

Deep Packet Inspection is an advanced method of packet filtering that examines not only the network headers (Layer 3/4 information like IP addresses and ports), but also the payload—the actual data content carried inside the packet.
  • Beyond the Header: Traditional firewalls see port 443 and assume it is legitimate HTTPS web traffic. A DPI-enabled firewall looks deeper into the byte stream to analyze application-layer signatures.
     
  • Use Cases:
     
    • Application Identification: Recognizing protocols even if they run on non-standard ports (e.g., detecting BitTorrent traffic or specific chat applications hiding on port 80 or 443).
    • Security: Scanning payloads for malware patterns, intrusion signatures, data exfiltration attempts, or unauthorized file types in transit.


 

Primarily Internet & Transport; advanced NGFWs also parse Application protocolsDeploys zones and policies, maintains connection state tables, can detect anomalies or signatures at line rate using ASICs.
GatewayTranslates between dissimilar protocols, addressing schemes or data formats (e.g., IPv4↔IPv6, MQTT↔HTTP, VoIP SIP↔PSTN).Potentially spans all layers up to ApplicationProvides “edge” between networks that could not otherwise interoperate; may re-encode payloads or apply security/authentication.

 


How the layers cooperate in a data path

  1. Host transmission:
    The NIC frames the packet; a modem may translate it for long-haul copper or fibre.
  2. Local forwarding:
    Switches and WAPs move the frame inside the local network while keeping layer-2 context.
  3. Inter-network forwarding:
    Routers read the IP header and forward towards the destination network; hardware firewalls on the path enforce security policy and may re-address packets.
  4. Protocol or media boundary:
    A gateway intervenes only when the source and destination use incompatible protocols or address families, rewriting headers or data so that communication can proceed.

Benefits of understanding the mapping

  • Troubleshooting focus – knowing the layer narrows diagnostic tools (e.g., ping fails ⇒ look at routers/firewalls, not switches).
  • Security zoning – firewalls/gateways protect higher layers; switches implement port-security at the link layer.
  • Performance tuning – upgrading NIC offload or replacing a hub with a switch tackles congestion without touching routers.

Grasping these roles equips you to reason about why, for example, adding a firewall cannot fix a duplex mismatch (Layer 1–2 issue), or why IPv6 reachability fails when a gateway is mis-configured even though the router table looks correct.