AWS Cloud Practitioner Study Notes · Part 19

The OSI Model: A Practical Guide for Cloud Networking

AWS Cloud Practitioner study notes mapping the seven OSI layers to TCP, IP, ports, VPC networking, and common AWS services.

The Open Systems Interconnection (OSI) model is a seven-layer framework for understanding how data moves between computers. It is mainly a teaching and troubleshooting model, not a literal description of every modern network implementation.

This is Part 19 of the AWS Cloud Practitioner Study Notes series. The most useful AWS connections are at Layer 3 (IP routing), Layer 4 (TCP, UDP, and ports), and Layer 7 (application protocols and services).

The seven OSI layers

The correct order is Layer 7 at the top through Layer 1 at the bottom:

LayerNameMain question
7ApplicationWhat network service does the application use?
6PresentationHow is the data formatted, encrypted, or compressed?
5SessionHow is the communication session managed?
4TransportHow should data be delivered end to end?
3NetworkWhere should the data go?
2Data LinkHow does data move across the local network?
1PhysicalHow are the raw signals transmitted?

Two common mnemonics are:

  • Top to bottom: All People Seem To Need Data Processing
  • Bottom to top: Please Do Not Throw Sausage Pizza Away

Layer 7 — Application

The Application layer provides network services to applications. It is the layer closest to the user, although the application itself is not the same thing as the protocol.

Common examples include:

  • HTTP and HTTPS for web traffic
  • FTP for file transfer
  • SMTP for email delivery
  • DNS for name resolution

AWS services are often discussed at this layer when they expose or process application protocols. Examples include Amazon S3 over HTTPS, Amazon API Gateway, Amazon CloudFront, Amazon Route 53 for DNS, and the AWS Management Console.

Think: “What network service is the application using?”

Layer 6 — Presentation

The Presentation layer describes how data is represented so that different systems can interpret it. Its common responsibilities are:

  • Data formatting and serialization
  • Encryption and decryption
  • Compression and decompression

Examples include TLS/SSL, JSON, XML, JPEG, and PNG. AWS Certificate Manager (ACM) helps provision and manage certificates used for TLS. HTTPS is HTTP carried through a TLS-protected connection.

In modern Internet stacks, TLS does not always fit neatly into one OSI layer. It is commonly taught as a Layer 6 example because encryption and data representation are the closest conceptual match.

Think: “How is the data made readable and secure?”

Layer 5 — Session

The Session layer opens, maintains, and closes communication sessions between applications. It can coordinate conversations, checkpoints, and recovery between communicating systems.

Examples traditionally associated with this layer include NetBIOS and RPC. In modern web applications, session behaviour is often implemented inside application protocols, frameworks, cookies, tokens, or connection libraries instead of appearing as a separate visible layer.

Think: “How is the conversation kept alive?”

Layer 4 — Transport

The Transport layer provides end-to-end communication between applications. It handles concepts such as:

  • Port numbers, which identify application endpoints
  • Segmentation and reassembly
  • Reliability and ordering when the protocol supports them
  • Flow control and connection management

TCP and UDP

ProtocolCharacteristicsTypical uses
TCPConnection-oriented, ordered, and reliable; retransmits lost dataHTTP, HTTPS, SSH, SMTP
UDPConnectionless and lightweight; does not provide built-in ordering or retransmissionDNS, streaming, gaming, VoIP

With TCP, the receiver acknowledges data. If a segment is lost, TCP can detect the gap and retransmit it. UDP keeps the protocol overhead low, so the application must handle reliability itself when it needs it.

Common ports to remember:

Protocol or servicePort
HTTP80
HTTPS443
SSH22
RDP3389
DNS53

AWS security groups let you define allowed protocols, ports, and sources or destinations. They are stateful resource-level firewalls, not standalone OSI transport devices, but their TCP/UDP and port rules are strongly connected to Layer 4 exam questions. A Network Load Balancer can also use TCP, TLS, UDP, or TCP_UDP listeners.

Think: “How should the data be delivered?”

Layer 3 — Network

The Network layer is responsible for logical addressing and routing between networks. Its main concepts are:

  • IPv4 and IPv6 addresses
  • Routing between different networks
  • Choosing the next destination for a packet
  • ICMP control and error messages

AWS services and features commonly mapped to this layer include:

  • Amazon VPC and subnet IP ranges
  • VPC route tables
  • Internet gateways and NAT gateways
  • AWS Transit Gateway
  • VPC peering

An AWS route table contains rules with a destination, such as a CIDR block, and a target, such as an internet gateway, NAT gateway, peering connection, or VPN. Traffic is selected based on its destination IP address.

Think: “Where is the destination?”

The Data Link layer moves frames across a directly connected local network. It uses hardware or MAC addresses and is commonly associated with switches and local network delivery.

In AWS, an Elastic Network Interface (ENI) is a virtual network interface attached to a resource. It has network attributes such as private IP addresses and a MAC address. This makes ENIs useful for understanding the Layer 2 and Layer 3 boundary, although an ENI is not simply “a switch” or a pure OSI Layer 2 service.

Security groups are associated with network interfaces and control traffic to and from the resources using those interfaces. For Cloud Practitioner questions, remember the practical relationship: ENI connects the resource to the VPC; security groups control permitted traffic.

Think: “How does data reach the device on this local network?”

Layer 1 — Physical

The Physical layer carries raw electrical, optical, or radio signals. Examples include:

  • Fibre-optic cable
  • Ethernet cable
  • Wireless radio signals
  • Network interface and switching hardware

AWS customers do not configure the physical data-centre network directly. AWS manages the underlying facilities and hardware as part of the cloud infrastructure, while customers configure higher-level resources such as VPCs, subnets, routes, and security controls.

Think: “How are the bits physically transmitted?”

Example: visiting https://amazon.com

One request can be described from the top layer down like this:

LayerWhat happens
7 ApplicationThe browser creates an HTTPS request. DNS may resolve the hostname first.
6 PresentationTLS protects the HTTP data, and the data is represented in an agreed format.
5 SessionThe application and connection libraries maintain the conversation.
4 TransportTCP uses port 443 to provide ordered, reliable delivery.
3 NetworkIP addresses and routing determine how packets travel across networks.
2 Data LinkLocal-network frames use link-layer addressing for the next hop.
1 PhysicalBits travel through fibre, Ethernet, or wireless media.

The receiving system processes the layers in the reverse direction, from the physical signal back up to the application request.

AWS services by OSI layer

These are useful learning mappings, not strict claims that each AWS service implements only one layer:

OSI layerCommon AWS examples
7 ApplicationAPI Gateway, Amazon S3, CloudFront, Route 53, AWS Management Console
6 PresentationAWS Certificate Manager, TLS certificates and encryption
5 SessionSession handling in applications, APIs, and client libraries
4 TransportSecurity group TCP/UDP rules, Network Load Balancer listeners
3 NetworkVPC, subnet CIDR ranges, route tables, internet gateway, NAT gateway, Transit Gateway
2 Data LinkENIs, MAC addresses, local-network frames
1 PhysicalAWS-managed data-centre networking hardware

OSI compared with TCP/IP

The Internet uses the TCP/IP protocol suite. Its commonly taught four-layer model combines some of the OSI layers:

OSI modelTCP/IP model
Application, Presentation, SessionApplication
TransportTransport
NetworkInternet
Data Link, PhysicalNetwork Access or Link

The OSI model gives learners a detailed vocabulary for troubleshooting. The TCP/IP model more closely reflects how Internet protocols are grouped. For example, the Internet application layer combines much of the OSI Application and Presentation functionality, while IP provides the Internet-layer service and TCP or UDP provides transport.

Cloud Practitioner exam notes

Prioritise these connections:

  • Layer 7: HTTP, HTTPS, DNS, CloudFront, API Gateway, S3, and Route 53
  • Layer 4: TCP versus UDP, port numbers, and security-group rules
  • Layer 3: IP addresses, VPCs, subnets, route tables, internet gateways, and NAT gateways
  • Layer 2: MAC addresses and ENIs
  • Layer 1: Physical cables and hardware managed by AWS

The exam is unlikely to require detailed packet analysis. It is more likely to test whether you can recognise the right layer for a networking concept: ports and TCP/UDP belong to Transport, IP and routing belong to Network, and HTTP/HTTPS/DNS belong to Application.

Final takeaway

Use the OSI model as a troubleshooting checklist: application service, data format, session, transport, routing, local delivery, and physical transmission. For AWS, spend the most time connecting Layers 3 and 4 to VPC networking, routes, security groups, protocols, and ports.

Sources

Back to the journal