Intro to encapsulation and decapsulation in networking

2022-04-02 07:54:52 By : Mr. James Yao

Many people take networks for granted, despite the significant roles they play in our daily lives. Networks rely on a few basic concepts, some of which include encapsulation, decapsulation and network layers.

Encapsulation marks where a packet, or unit of data, begins and ends. The beginning part of a packet is called the header, and the end of a packet is called the trailer. The data between the header and trailer is sometimes referred to as the payload.

The packet header carries information in its first few bytes to mark where the packet begins and to identify the type of information it carries. As a packet travels from its source to a destination, different layers in a computing system contribute to the packet header. The header info varies depending on which protocol is used, as each protocol has a defined format.

The packet trailer indicates to a receiving device that it has reached the end of the packet. It often contains an error-check value that the receiving device can use to confirm it has received the full packet.

Decapsulation is the process of removing the header and trailer information from a packet, as it moves toward its destination. The destination device receives the data in its original form.

ISO defined a model for protocols that separates system layers by function: the Open Systems Interconnection (OSI) model. Each of the seven OSI layers provides a specific set of functions.

In the encapsulation process, a source computer sends a packet from Layer 7, the application layer, to Layer 1, the physical layer. Data encapsulation doesn't begin until a packet reaches Layer 4, the transport layer. After that, the remaining layers add corresponding information to the packet, enabling it to travel through the system.

Decapsulation moves in the reverse order, from Layer 1 to Layer 7 in the OSI model, as the packet travels to the receiving computer.

This is the lowest layer that manages the electrical signals of a network device in use. The physical layer adds the bit sequence that marks the beginning of the packet and the trailer.

The link layer manages the interaction across the local network between the sending and receiving systems. In encapsulation, it adds the local destination address to the header.

The network layer routes the packet across the network. It encapsulates the packet with the internet address header.

Some transport protocols, such as Transmission Control Protocol (TCP), guarantee that all packets reach their destination. Other transport protocols do not guarantee delivery, such as User Datagram Protocol (UDP). Transport protocols add byte counts to headers.

The session layer manages the flow of information between systems. It provides information about how the information is allowed to flow throughout the system.

The presentation layer modifies the information to a form an application can use. It provides information about data formats.

As the highest layer, the application layer interacts with the end device.

The most widely used network protocols are in the Internet Protocol suite, commonly referred to as TCP/IP, which was developed under contract by the U.S. Department of Defense. The TCP/IP model was designed to operate on a variety of computer types.

While the TCP/IP model follows the same design principles as the OSI model, the two differ. The main difference is the TCP/IP model consolidates Layers 5 through 7 of the OSI model into a single application layer. It also commonly combines the physical and data link layers, sometimes called the network interface or network access layer.

The encapsulation and decapsulation processes with TCP/IP follow the same progression through the layers as with the OSI model.

The lowest layer, the physical layer, encapsulates the packet, adding a bit sequence specific for each type of network medium. Each type of network -- e.g., Ethernet, fiber and Wi-Fi -- operates differently. Therefore, the sequence of bytes that marks the beginning of a packet differs for each. The trailer format also varies by type of medium.

Every packet makes its first hop across the local network. The data link layer adds the media address control (MAC) identifier, which is installed in each network interface by the system manufacturer. The first bytes identify the manufacturer, and the following bytes uniquely specify every network interface that the manufacturer has ever produced. Consequently, no two interfaces worldwide have identical MAC addresses.

When a packet is sent, every system that shares a local network reads that packet's destination MAC address. But only the system with that specific assigned MAC address reads the remainder of the packet.

The network layer routes the packet through the larger network. In many cases, the first hop across the local network, which the data link layer handles, takes the packet to a system with a router.

The packet requires an internet address to address the destination system across the larger network. The network layer adds the destination internet address -- which is assigned to a system when it is installed in the network -- to the packet header.

A variety of transport protocols are available, including TCP, UDP and Stream Control Transmission Protocol (SCTP):

The TCP/IP model combines the session and presentation layers into the application layer. Session can control whether a connection transmits in both directions simultaneously, one direction at a time or simply in one direction.

The presentation layer operates above session and ensures that the application receives data in a usable form. It can offer encryption and decryption, as well as compression and decompression.

The application layer defines the human interface to the network, such as functions like email, file transfer and the web.

Existing protocols may be enhanced, but they won't be fundamentally changed in order to retain compatibility. Over time, network practitioners can expect the development of new protocols that will likely keep the layered format. And, even though details change, encapsulation as a concept will stay the same.

What is the difference between TCP/IP model vs. OSI model?

Google's upcoming Meet updates will include letting multiple workers communicate over video while collaborating on a document, ...

HP plans to acquire Poly to appeal to companies looking for conference gear, headsets and other devices for hybrid work. HP ...

Experts agree that VR could one day play an important role in business collaboration -- but it will take 10 years or more for the...

Finding the right mobile application management tool is about its features and what the organization needs to efficiently use ...

Samsung Galaxy smartphones and tablets will get the One UI 4.1 user interface. The premium UI for the company's flagship phones ...

Cisco's MV Sense is available as a subscription with Meraki MV cameras. Companies can use the service to count boxes in a ...

Despite the deployment and cost advantages of hyper-converged infrastructures, learn how disaggregated HCI can overcome compute, ...

To improve performance of workloads spanning multiple clouds and on-premises environments, Intel acquired Granulate Cloud ...

Proper backup and DR at the edge requires an awareness of the specific challenges edge devices present, and appropriate plans and...

MSP mergers and acquisitions may frequent the news, but how is the value of an MSP determined, how are deals structured and what ...

E-card platform JibJab sought a better way to crop images for a new physical book product. Mission improved the process's ...

Some MSP perspectives of the market may be pessimistic for the next year; however, new CompTIA research shows that most feel ...

All Rights Reserved, Copyright 2000 - 2022, TechTarget Privacy Policy Cookie Preferences Do Not Sell My Personal Info