Data Communication

Chapter 2
Layered Architectures, Standards and Protocols

Bachelors Program in IT
Data Communication   •   Bachelor

Layered Architectures, Standards and Protocols

Introduction

Data communication is possible only when communicating systems agree on how information will be represented, transmitted, interpreted, and managed. A networked application does not communicate directly with a physical cable or radio channel. Instead, communication is organized into layers. Each layer performs a defined group of functions, uses services provided by the layer below, and offers services to the layer above.

Layered architecture reduces complexity, encourages interoperability, and allows one technology to be changed without redesigning the entire communication system. For example, a web application can continue to operate when an Ethernet connection is replaced by Wi-Fi because the application is separated from the physical transmission technology by several protocol layers.

This chapter examines protocol syntax, semantics, and timing; the OSI and TCP/IP reference models; encapsulation and addressing; and the contributions of major standards organizations. It also considers practical protocol analysis, interoperability, security, and contemporary developments such as encrypted transport protocols and software-defined networking.

Learning Objectives

After studying this chapter, you should be able to:

  1. Define protocols and distinguish syntax, semantics, and timing.
  2. Explain the purpose and limitations of layered network architectures.
  3. Compare the OSI reference model with the TCP/IP model.
  4. Trace encapsulation and decapsulation through a communication stack.
  5. Distinguish physical, data-link, network, transport, and application addressing.
  6. Explain the roles of ISO, IEEE, ITU-T, and IETF.
  7. Analyze a communication problem using layers, protocols, and standards.
  8. Evaluate practical and governance issues associated with protocol design.

1. Protocols as Rules of Communication

A protocol is a set of rules that governs communication between entities. The entities may be application programs, operating-system components, network devices, or hardware interfaces. A protocol specifies what messages may be exchanged, how messages are structured, what each field means, and when messages should be sent or acknowledged.

A useful protocol definition has three dimensions:

  • Syntax: the structure and format of messages.
  • Semantics: the meaning of fields and actions.
  • Timing: when messages are transmitted, how quickly responses are expected, and how long a system waits before retrying or abandoning an exchange.

1.1 Syntax

Syntax describes the organization of information. It includes field order, field length, encoding, byte order, delimiters, and permitted values. For example, an Ethernet frame contains fields including destination address, source address, a type or length field, payload, and a frame-check sequence. If a receiver cannot identify the field boundaries, it cannot interpret the frame reliably.

Syntax may be fixed or variable. A fixed-format message is relatively easy to parse but may be less flexible. A variable-format message can support extensions but requires length indicators, type codes, or delimiters. Protocol designers must also decide whether multi-byte numbers are transmitted most-significant byte first or least-significant byte first.

1.2 Semantics

Semantics explains what a field means and what an action signifies. A value in a header may identify a destination, indicate a protocol version, specify payload length, report an error, or request a particular service. Two messages can have syntactically valid formats but different meanings if their protocol interpretations differ.

Semantics also includes state. For example, a connection-establishment message may be valid only before a connection exists, while a termination message may be meaningful only after communication has begun. Protocol state machines therefore describe valid transitions between states such as closed, listening, established, and terminated.

1.3 Timing

Timing determines the temporal behavior of communication. Important timing considerations include:

  • transmission order;
  • maximum response time;
  • timeout duration;
  • retransmission interval;
  • synchronization requirements; and
  • flow-control behavior.

Timing is essential in both ordinary data transfer and real-time systems. A file transfer can tolerate delay if data eventually arrives, whereas a voice or industrial-control system may fail if packets arrive too late, even when no packets are lost.

Timing should not be confused with transmission rate. Bandwidth describes a capacity or frequency range, while delay describes elapsed time. A high-capacity link can still have substantial delay because of propagation distance, routing, queuing, or processing.

2. Why Layered Architectures Are Used

A layered architecture divides communication into functional levels. Each layer has a defined responsibility and communicates with its peer layer in another system through a protocol. In the same system, a layer uses an interface to request services from the layer below.

The major advantages are:

  1. Modularity: components can be designed and tested separately.
  2. Interoperability: independent vendors can implement compatible protocols.
  3. Abstraction: higher layers need not know the physical details of lower layers.
  4. Change management: a new link technology can be introduced without rewriting applications.
  5. Troubleshooting: faults can be localized by examining layers.
  6. Reuse: a transport protocol can support many applications, and an application protocol can operate over different networks.

Layering also has limitations. Real protocols sometimes cross layer boundaries for performance, security, or management reasons. Network address translation, firewalls, quality-of-service mechanisms, and wireless optimization may inspect information belonging to several layers. Strict layering can therefore provide conceptual clarity without being a perfect description of implementation.

A layer is not the same as a physical device. A router commonly operates primarily at the network layer but may also process link-layer frames, security rules, and management protocols. Similarly, an operating system may implement several layers in software, while a network interface card implements selected functions in hardware.

3. The OSI Reference Model

The Open Systems Interconnection (OSI) model was developed by the International Organization for Standardization (ISO) as a seven-layer reference framework. It is primarily a conceptual model rather than a complete set of protocols.

LayerNameMain responsibilitiesTypical examples
7ApplicationServices directly used by applicationsHTTP, DNS, SMTP
6PresentationData representation, translation, compression, encryptionCharacter encoding, data serialization
5SessionDialog control, synchronization, session managementSession checkpoints and control
4TransportEnd-to-end delivery, reliability, flow control, multiplexingTCP, UDP, SCTP
3NetworkLogical addressing and routing between networksIP, routing protocols
2Data LinkFraming, local delivery, media access, link error detectionEthernet, Wi-Fi MAC
1PhysicalSignals, media, connectors, bit transmissionCopper, fiber, radio

3.1 Physical Layer

The physical layer transmits an unstructured stream of bits across a medium. Its concerns include voltage or light levels, modulation, timing, connectors, pin arrangements, radio frequencies, and data rates. It does not decide which application generated the bits or which remote application should receive them.

3.2 Data-Link Layer

The data-link layer organizes bits into frames and supports communication across one local link. It may provide hardware addressing, media-access control, error detection, and sometimes retransmission. Ethernet and Wi-Fi are important examples. A switch generally forwards frames using data-link addresses.

3.3 Network Layer

The network layer provides logical addressing and forwarding across interconnected networks. Internet Protocol (IP) addresses identify interfaces in an internetworking scheme, while routers select paths based on network prefixes and routing information. The network layer generally provides best-effort delivery rather than guaranteeing that every packet arrives.

3.4 Transport Layer

The transport layer provides process-to-process communication. It may provide reliability, sequencing, duplicate suppression, flow control, congestion control, and multiplexing. TCP provides a reliable byte stream, while UDP provides a connectionless datagram service with minimal transport functionality. Port numbers help deliver data to the appropriate process.

3.5 Session, Presentation, and Application Layers

The OSI session layer manages logical dialogues, including establishment, synchronization, and termination. The presentation layer addresses representation issues such as character encoding, serialization, compression, and encryption. In modern Internet implementations, these functions are often integrated into application libraries or protocols rather than implemented as separate universal layers.

The application layer provides network services to software. HTTP supports web transfer, DNS maps names to information such as IP addresses, and SMTP supports electronic mail transfer. An application-layer protocol may depend on transport, network, data-link, and physical protocols beneath it.

4. The TCP/IP Model

The TCP/IP architecture developed from protocols sponsored by research and government networking programs. It is the practical architectural foundation of the Internet. A commonly used four-layer representation is:

TCP/IP layerMain functionExamples
ApplicationNetwork services and application dataHTTP, DNS, SMTP, SSH
TransportProcess-to-process communicationTCP, UDP, QUIC
InternetLogical addressing and routingIPv4, IPv6, ICMP
LinkLocal delivery and physical transmissionEthernet, Wi-Fi, fiber, cellular

Some descriptions divide the Link layer into separate Data Link and Physical layers, producing a five-layer teaching model. The TCP/IP model does not map exactly to OSI. TCP/IP Application functions include many OSI Application, Presentation, and Session functions. TCP/IP Link functions include OSI Data Link and Physical functions.

The OSI model is valuable for teaching, design analysis, and standardization vocabulary. The TCP/IP model more closely reflects the deployed Internet protocol suite. Neither model should be treated as a claim that every implementation has exactly seven or four software modules.

5. Encapsulation and Decapsulation

When an application sends data, each lower layer normally adds control information. This process is encapsulation. At the destination, corresponding layers remove and interpret the control information; this is decapsulation.

A simplified sequence is:

  1. An application creates data, such as an HTTP request.
  2. The transport layer adds a header containing information such as source and destination ports.
  3. The Internet layer adds an IP header containing source and destination IP addresses.
  4. The link layer adds a frame header and trailer containing local-link addressing and error-detection information.
  5. The physical layer transmits the resulting bits.
  6. The receiving system reverses the process.

The names commonly used for data units are application data or message, segment for TCP, datagram for UDP or IP, frame for the data-link layer, and bits for the physical layer. Terminology can vary by protocol documentation.

Total transmitted size = application data size + Σ(header and trailer sizes)

The summation includes every header and trailer added on the path being considered. This expression is applicable when the sizes are measured consistently, normally in bytes. It does not account for padding, fragmentation, tunnels, retransmissions, or lower-layer encoding overhead unless those are explicitly included.

Worked Example: Encapsulation Overhead

Suppose an application creates 1,000 bytes of data. A transport header adds 20 bytes, an IP header adds 20 bytes, and a link-layer header and trailer add 18 bytes.

Total frame size = 1,000 + 20 + 20 + 18 = 1,058 bytes.

The protocol overhead is 58 bytes. The payload efficiency, ignoring physical encoding overhead, is:

Efficiency = (payload size ÷ total transmitted size) × 100%

Therefore, efficiency = (1,000 ÷ 1,058) × 100% ≈ 94.5%. The result applies only to this single frame and assumes no retransmission, padding, fragmentation, or tunnel headers.

6. Addressing at Different Layers

A central source of confusion is that one communication exchange can use several kinds of addresses simultaneously.

Address typeLayerPurposeExample
Application identifierApplicationIdentifies a resource, service, or user-level endpointURL or email address
Port numberTransportIdentifies a process or service endpointTCP port 443
IP addressInternet/networkIdentifies a logical interface or destination in an internetworkIPv4 or IPv6 address
Link-layer addressData linkIdentifies an interface on a local networkEthernet MAC address
Physical identifierPhysical or access systemMay identify a radio subscription or hardware elementCellular equipment identity

These addresses are related but not interchangeable. A web browser may use a domain name to obtain an IP address through DNS. The transport layer then uses a destination port to identify the server process. On each local link, an IP-to-link-address resolution mechanism may identify the next-hop interface.

A router normally changes the link-layer frame as a packet crosses each link. The source and destination link addresses therefore change at every hop. The IP source and destination normally remain end-to-end, although mechanisms such as network address translation can modify them. Transport ports identify application endpoints, but middleboxes may also translate them.

7. Standards and Standards Organizations

Standards make interoperability possible by defining common technical expectations. A standard may specify electrical characteristics, frame formats, addressing rules, encoding, security procedures, or application behavior. Standards can be formal, de facto, proprietary, open, mandatory within a regulation, or voluntary but widely adopted.

7.1 ISO

The International Organization for Standardization is an international standards body composed of national standards organizations. ISO develops standards across many fields. In networking education, ISO is especially associated with the OSI reference model and related standards work. ISO standards are produced through structured international consensus and are often adopted or referenced by national and sector-specific organizations.

7.2 IEEE

The Institute of Electrical and Electronics Engineers develops standards in electrical engineering, computing, and networking. The IEEE 802 family is particularly important. IEEE 802.3 defines Ethernet standards, while IEEE 802.11 defines wireless local-area networking standards. IEEE standards commonly address physical and data-link technologies, including media access, frame structures, and transmission characteristics.

7.3 ITU-T

The International Telecommunication Union Telecommunication Standardization Sector develops recommendations for telecommunications, numbering, signaling, multimedia, transport networks, and related services. ITU-T recommendations have been influential in public telephone networks, digital subscriber technologies, optical transport, video coding, and mobile telecommunications. The word “recommendation” reflects the formal status of many ITU-T documents, although their practical influence can be substantial.

7.4 IETF

The Internet Engineering Task Force develops Internet standards through an open process based on technical discussion and published documents called Requests for Comments (RFCs). IETF work includes IP, TCP, DNS, HTTP, routing, security, and many other Internet protocols. Not every RFC is a standard; RFCs may also document experiments, information, historical material, or best current practices.

The IETF process emphasizes running code and operational experience. Internet standards evolve through implementation, deployment, review, and revision rather than solely through centralized design.

7.5 Standards Selection in Practice

Organizations should select standards according to requirements rather than popularity alone. Relevant questions include:

  • Is the standard openly documented?
  • Are interoperable implementations available?
  • Is it stable and supported by vendors?
  • Does it meet performance and security requirements?
  • Are licensing or patent obligations acceptable?
  • Does it support migration and backward compatibility?
  • Is it appropriate for the legal and regulatory environment?

Open standards can reduce vendor lock-in, but openness alone does not guarantee security, performance, or suitability. Governance teams should examine the specific version, profiles, extensions, and implementation practices involved.

8. Protocol Analysis in Practice

Layered reasoning is a practical troubleshooting method. When a user cannot access a service, an engineer can test progressively:

  1. Is the device powered and physically connected?
  2. Is the local interface functioning and associated with the network?
  3. Does the device have a valid IP configuration?
  4. Can it reach the default gateway?
  5. Can it resolve the service name?
  6. Can it establish transport communication with the destination port?
  7. Does the application-layer exchange succeed?

Tools such as cable testers, interface statistics, ping, traceroute, DNS diagnostic utilities, socket tests, and packet analyzers support this process. A packet capture can reveal malformed syntax, incorrect addresses, retransmissions, unexpected flags, fragmentation, or protocol negotiation failures.

However, successful testing at one layer does not prove that all higher layers work. A host may respond to ICMP while its web server is stopped. Similarly, a DNS lookup may succeed while a firewall blocks the requested application port.

9. Applied Case: Interoperability Failure in a University Network

Background

This illustrative case concerns a university that replaced several wired access switches with equipment from a different vendor. Users reported that some laptops could connect to the wireless network but could not access internal learning-management services.

Problem

Basic physical tests were successful. Devices received IP addresses, and the wireless controller reported successful association. However, applications intermittently failed, especially when students moved between access points.

Analysis

The network team examined the problem by layers. The physical and link layers showed successful radio association and frame exchange. IP configuration was valid, and ping to the gateway worked. DNS resolution also succeeded. Packet captures showed that transport connections were being reset during movement between access points.

Further analysis found inconsistent support for a mobility-related feature and different interpretations of a vendor extension. Although both products claimed compatibility with the relevant wireless standards, their optional implementations were not equivalent.

Approach and Solution

The team first documented the standards and optional profiles supported by each device. It then disabled the incompatible extension, upgraded firmware, and configured a common security and roaming profile. Testing was performed with multiple client operating systems and under realistic movement conditions.

Outcome

Roaming became stable, and application sessions no longer failed during ordinary movement. The investigation also produced a standards-compliance checklist for future procurement.

Learning Points

The case demonstrates that “standard compliant” does not always mean universally interoperable. Compatibility depends on versions, mandatory requirements, optional features, interpretations, and implementation quality. Layered troubleshooting prevented the team from repeatedly replacing cables or IP settings when the problem was actually associated with link-layer roaming and transport behavior.

10. Challenges, Security, and Governance

Layered protocols improve organization but create security challenges. Attackers may exploit weaknesses in any layer: physical tampering, unauthorized wireless access, forged link-layer information, malicious routing advertisements, transport exhaustion, or application-layer injection. Security must therefore be designed across layers rather than added only at the perimeter.

Encryption can also blur traditional layer boundaries. TLS protects application exchanges while operating above the transport layer. QUIC integrates transport-like functions with encryption over UDP. Virtual private networks encapsulate one protocol inside another, adding headers and potentially changing path behavior.

Protocol governance raises ethical and regulatory questions. Designers should consider privacy, accessibility, lawful interception requirements, data sovereignty, and the effects of standards on less-resourced communities. A protocol that exposes unnecessary metadata can enable surveillance even when payloads are encrypted. Procurement decisions should consider long-term maintenance, open documentation, vulnerability disclosure, and equitable access.

Artificial intelligence is increasingly used to analyze packet traces, detect anomalies, and recommend network configurations. Such systems can assist engineers but should not replace validation. Training data may contain sensitive information, and automated decisions may incorrectly classify legitimate unusual traffic as malicious. Human review, audit logs, data minimization, and clear accountability remain necessary.

11. Contemporary Developments and Best Practices

Modern networking increasingly combines traditional layers with virtualization, cloud services, programmable infrastructure, and encrypted protocols. Software-defined networking separates control decisions from packet-forwarding mechanisms. Network functions may run as virtual machines or containers. Overlay networks encapsulate traffic to create logical topologies over physical infrastructure.

Best practices include:

  • document protocol versions and optional extensions;
  • separate logical addressing plans from physical layouts;
  • use open, well-supported standards where appropriate;
  • validate interoperability with equipment from multiple vendors;
  • capture and inspect traffic during testing;
  • apply security controls at multiple layers;
  • monitor latency, loss, jitter, errors, and retransmissions;
  • design for version negotiation and graceful failure;
  • protect management interfaces and credentials; and
  • record assumptions, dependencies, and known limitations.

A technically correct protocol can still fail operationally if configuration, monitoring, patching, or staff training is inadequate. Professional competence therefore requires both conceptual knowledge and disciplined implementation.

Chapter Summary

Protocols define the syntax, semantics, and timing of communication. Layered architectures divide networking responsibilities into manageable functions and allow technologies to interoperate through defined services and interfaces. The OSI model provides a seven-layer conceptual framework, while the TCP/IP model more closely represents the deployed Internet protocol suite.

Encapsulation adds headers and trailers as data moves downward through a sender’s stack; decapsulation removes and interprets them at the receiver. Different layers use different forms of addressing, including application identifiers, port numbers, IP addresses, and link-layer addresses. A packet’s link-layer addresses may change at every hop, while higher-level identifiers usually support end-to-end communication.

ISO, IEEE, ITU-T, and IETF make distinct but complementary contributions to networking standards. Standards improve interoperability, but implementation versions, optional features, security requirements, and governance must be evaluated carefully. Layered analysis provides a systematic method for troubleshooting, designing, procuring, and securing communication systems.

Key Terms

Protocol: A set of rules governing communication between entities.

Syntax: The structure and format of protocol messages.

Semantics: The meaning of protocol fields and actions.

Timing: The temporal rules governing transmission, response, and retransmission.

Layered architecture: A design that divides communication functions into levels.

OSI model: A seven-layer reference model developed through ISO standardization work.

TCP/IP model: The practical architectural model underlying the Internet protocol suite.

Encapsulation: Adding control information as data moves down a protocol stack.

Decapsulation: Removing and interpreting control information at the receiver.

Message: Application-level data exchanged by an application protocol.

Segment: A common name for a TCP transport-layer data unit.

Datagram: A self-contained data unit, commonly associated with UDP or IP.

Frame: A data-link-layer data unit.

Port number: A transport-layer identifier for an application process or service.

IP address: A logical address used for internetwork delivery.

MAC address: A data-link identifier associated with a network interface.

Interoperability: The ability of independent systems to work together correctly.

ISO: International Organization for Standardization.

IEEE: Institute of Electrical and Electronics Engineers.

IETF: Internet Engineering Task Force.

Review Questions

Short Answer Questions

  1. What are the three principal dimensions of a communication protocol?
  2. Why is layering useful in network architecture?
  3. What is the primary responsibility of the transport layer?
  4. Distinguish an IP address from a link-layer address.
  5. What is encapsulation?

Long Answer Questions

  1. Explain the seven OSI layers and give an example of a technology or function associated with each.
  2. Compare the OSI and TCP/IP models, including their similarities and important differences.
  3. Describe the complete encapsulation and decapsulation process for a web request.
  4. Explain the roles of ISO, IEEE, ITU-T, and IETF in networking standards.
  5. Discuss the advantages and limitations of strict layering in modern networks.

Analytical / Application Questions

  1. A user can ping a server but cannot open its web page. Analyze the problem layer by layer and identify possible causes.
  2. A packet crosses three routers. Explain which addresses are likely to change at each hop and which addresses normally remain end-to-end.
  3. A university is purchasing wireless equipment from several vendors. Develop a standards and interoperability evaluation plan, including technical, security, and governance criteria.

Multiple Choice Questions with Answers

Question 1

Which protocol characteristic specifies the structure and field arrangement of a message?

A. Timing

B. Syntax

C. Semantics

D. Routing

Correct Answer: B. Syntax

Question 2

Which layer is primarily responsible for logical addressing and routing between networks?

A. Physical

B. Data Link

C. Network or Internet

D. Application

Correct Answer: C. Network or Internet

Question 3

What is added to data during encapsulation?

A. Only user passwords

B. Headers and, in some cases, trailers

C. Only physical cables

D. A new operating system

Correct Answer: B. Headers and, in some cases, trailers

Question 4

Which identifier normally helps deliver data to a particular process on a host?

A. Port number

B. MAC address

C. Optical wavelength

D. Connector type

Correct Answer: A. Port number

Question 5

Which organization is strongly associated with Ethernet and Wi-Fi standards?

A. IEEE

B. IETF

C. ISO

D. ITU-T

Correct Answer: A. IEEE

Question 6

Which statement best describes the OSI model?

A. It is a seven-layer reference framework

B. It is a single physical cable specification

C. It is a web browser protocol

D. It is a database design method

Correct Answer: A. It is a seven-layer reference framework

Question 7

A frame crosses a router onto a different local network. Which address type normally changes at the new link?

A. Application resource identifier

B. Transport port number

C. Link-layer address

D. File name

Correct Answer: C. Link-layer address

Question 8

An application creates 1,000 bytes of data and headers and trailers add 58 bytes. What is the total transmitted size, ignoring other overhead?

A. 942 bytes

B. 1,000 bytes

C. 1,058 bytes

D. 1,580 bytes

Correct Answer: C. 1,058 bytes

Question 9

Which organization develops Internet standards through RFC-based open technical processes?

A. IETF

B. IEEE

C. ISO

D. ITU-T

Correct Answer: A. IETF

Question 10

Why does successful pinging not prove that a web application is functioning?

A. Ping operates only at the physical layer

B. Ping tests a different protocol and does not validate the application exchange

C. Web applications never use IP

D. Ping always uses TCP port 443

Correct Answer: B. Ping tests a different protocol and does not validate the application exchange

Data Communication
Chapter 2 of 14