Featured image

Table of Contents Link to heading

Protocols Link to heading

predetermined rules that govern all communications over a network.

  1. Proprietary protocols are controlled by a company and not for public use.
    • The protocol is treated like a copyright and can be licensed to other companies to use.
  2. Open-source protocols are written for public use at no charge. protocols.

For devices to communicate on a network, they must follow different protocols that perform the many tasks to be completed.

The protocols define the following:

  1. The format of the message, such as how much data to put into each segment.
  2. The way intermediary devices share information about the path to the destination.
  3. The method to handle update messages between intermediary devices.
  4. The process to initiate and terminate communications between hosts.

Protocol Suite Link to heading

a collection of protocols, differentiated according to functional criteria, that work together to ensure successful communication.

Protocol suites are implemented by hosts and networking devices in software, hardware, or both.

Protocol Stack Link to heading

a layered model designed to help visualise how the individual protocols within a suite interact.

The protocols are viewed in terms of layers, with each layer performing a particular function and communicating with the layers above and below it.

The lower layers of the stack are concerned with moving data over the network and providing services to the upper layers which focus on the content of the message being sent.

The benefits to using a layered model to describe network protocols and operations include:

  1. Understanding how a network functions.
  2. Assisting in protocol design because protocols that operate at a specific layer have defined information that they act upon and a defined interface to the layers above and below.
  3. Fostering competition because products from different vendors can work together.
  4. Preventing technology or capability changes in one layer from affecting other layers above and below.
  5. Providing a common language to describe networking functions and capabilities.

There are two layered models:

  1. Reference model - provides an extensive list of functions and services that can occur at each layer.
    • Open Systems Interconnection (OSI) model
  2. Protocol model - describes the functions of each protocol at each layer.
    • Transmission Control Protocol/Internet Protocol (TCP/IP) model

TCP/IP Protocol Model Link to heading

defines four communication functions that protocols perform.

LayerFunctional DescriptionTCP/IP Protocol Suite
Application LayerRepresents application data to the userName SystemHost ConfigEmailFile TransferWeb
DNSBOOTP
DHCP
SMTP
POP
IMAP
FTP
TFTP
HTTP
Transport LayerSupports communication between devices and performs error correctionTCPUDP
Internet LayerFinds the best path through the networkIPv4, IPv6IP SupportRouting Protocols
NATICMPv4, ICMPv6OSPF, EIGRP, RIP, BGP
Network Access LayerControls hardware devices and responsible for delivering the IP packet over the physical medium.ARPPPPEthernetFrame RelayInterface Drivers

Protocol Interaction in Web Client-Server Communication Link to heading

Communication between a web server and web client is an example of an interaction between several protocols within a suite.

Application Layer Link to heading

Hypertext Transfer Protocol (HTTP) governs the way a web server and a web client interact.

It defines the content and formatting of the requests and responses that are exchanged between the client and server. Both the client and the web server software implement HTTP as part of the application.

HTTP relies on other protocols to govern how the messages are transported between the client and server.

Transport Layer Link to heading

Transmission Control Protocol (TCP) manages the individual conversations between web servers and web clients.

TCP divides the HTTP messages into smaller pieces, called segments, to be sent to the destination client.

It is also responsible for controlling the size and rate at which messages are exchanged between the server and the client.

Internet Layer Link to heading

Internet Protocol (IP) is responsible for taking the formatted segments from TCP, encapsulating them into packets, assigning them the appropriate network addresses, and delivering them to the destination host.

Network Access Layer Link to heading

Network access layer protocols perform two primary functions: data-link management and the physical transmission of data on the media.

Data-link management protocols take the packets from IP and format them to be transmitted over the media.

The standards and protocols for the physical media govern how the signals are sent over the media and how they are interpreted by the receiving clients. Transceivers on the NICs implement the appropriate standards for the media that is being used.

Communication Process Link to heading

  1. Creation of data at the application layer of the originating source host.
  2. Segmentation and encapsulation of data as it passes down the protocol stack in the source host.
  3. Generation of the data onto the media at the network access layer of the stack.
  4. Transportation of the data through the internetwork, which consists of media and any intermediary devices.
  5. Reception of the data at the network access layer of the destination host.
  6. Decapsulation and reassembly of the data as it passes up the stack in the destination host.
  7. Passing this data to the destination application at the application layer of the destination host.

Web Client-Server Communication Process Link to heading

Let’s demonstrate the complete communication process using an example of a web server transmitting data to a client.

  1. The web server preparing the HyperText Markup Language (HTML) page as data to be sent.
  2. The application protocol HTTP header is added to the front of the HTML data. The header contains various information, including the HTTP version the server is using and a status code indicating it has information for the web client.
  3. The HTTP application layer protocol delivers the HTML-formatted web page data to the transport layer. The TCP transport layer protocol is used to manage individual conversations, in this example between the web server and web client.
  4. The IP information is added to the front of the TCP information. IP assigns the appropriate source and destination IP addresses. This information is known as an IP packet.
  5. The Ethernet protocol adds information to both ends of the IP packet, known as a data link frame. This frame is delivered to the nearest router along the path towards the web client. This router removes the Ethernet information, analyses the IP packet, determines the best path for the packet, inserts the packet into a new frame, and sends it to the next neighbouring router towards the destination. Each router removes and adds new data link information before forwarding the packet.
  6. This data is now transported through the internetwork, which consists of media and intermediary devices.
  7. The client receiving the data link frames that contain the data. Each protocol header is processed and then removed in the opposite order it was added. The Ethernet information is processed and removed, followed by the IP protocol information, the TCP information, and finally the HTTP information.
  8. The web page information is then passed on to the client’s web browser software.

Encapsulation and Protocol Data Units (PDUs) Link to heading

For application data to travel without being corrupted from one host to another across a network, it is wrapped with protocol information (or control information which contains control and addressing information) as it moves down the layers.

MethodPerformed ByDescription
Encapsulationthe sending hostthe process of adding control information as it moves down the stack towards
Decapsulationthe receiving hostthe process of removing control information and sending only the original application data as it moves up the stack towards the end-user application

Protocol data unit (PDU) refers to the control information attached to the data at any layer.

During encapsulation, each succeeding layer encapsulates the PDU that it receives from the layer above in accordance with the protocol being used and adds some more control information to encapsulate it and some more functionalities with the data.

These functionalities may include proper data sequencing, error detection and control, flow control, congestion control, routing information, etc.

Tip
DSPFB - Do Some People Fear Binary?
LayerPDU Name
ApplicationData
Transport(TCP) Segment / (UDP) Datagram
NetworkPacket
Data LinkFrame (a series of bits)
Physical(raw) Bits (1s and 0s)

At a transmitting device, the encapsulation method works like this:

  1. User information is converted to data for transmission on the network.
  2. Data is converted to segments, and a reliable connection is set up between the transmitting and receiving hosts.
  3. Segments are converted to packets or datagrams, and a logical address is placed in the header so each packet can be routed through an internetwork.
  4. Packets or datagrams are converted to frames for transmission on the local network. Hardware (Ethernet) addresses are used to uniquely identify hosts on a local network segment.
  5. Frames are converted to bits, and a digital encoding and clocking scheme is used.

Encapsulation in E-mail Communication Link to heading

The common task of sending an e-mail has many steps in the process.

Sending an E-mail Link to heading

When sending messages on a network, the encapsulation process works from top to bottom.

  1. An end user, using an e-mail application, creates data. The application layer codes the data as e-mail and sends the data to the transport layer.
  2. The message is segmented for transport. The transport layer adds control information in a header so that it can be assigned to the correct process and all segments put into proper order at the destination. The segment is sent down to the internet layer.
  3. The internet layer adds IP addressing information in an IP header. The segment is now an addressed packet that can be handled by routers en route to the destination. The internet layer sends the packet down to the network access layer.
  4. The network access layer creates an Ethernet frame with local network MAC address information in the header. This enables the packet to get to the local rout and out to the web. The frame also contains a trailer with error-checking information. After the frame is created, it is encoded into bits and sent onto the media to the destination.

Receiving an E-mail Link to heading

When receiving messages on a network, the process is reversed at the receiving host, and is known as decapsulation.

  1. The frame is decapsulated to a packet, then to a segment, and then the transport layer puts all segments into the proper order.
  2. When all data has arrived and is ready, it is sent to the application layer, and then the original application data goes to the receiver’s e-mail application.

Encapsulation in Web Client-Server Communication Link to heading

In the web server example, we can use the TCP/IP model to illustrate the process of sending an HTML web page to a client.

  1. The application layer protocol, HTTP, begins the process by delivering the HTML formatted web page data to the transport layer. There the application data is broken into TCP segments.
  2. Each TCP segment is given a label, called a header, containing information about which process running on the destination computer should receive the message.
    • It also contains the information that enables the destination process to reassemble the data back to its original format.
  3. The transport layer encapsulates the web page HTML data within the segment and sends it to the internet layer, where the IP protocol is implemented.
  4. Here the entire TCP segment is encapsulated within an IP packet, which adds another label, called the IP header.
  5. The IP header contains source and destination host IP addresses, as well as information necessary to deliver the packet to its corresponding destination process.
  6. Next, the IP packet is sent to the network access layer where it is encapsulated within a frame header and trailer.
    • Each frame header contains a source and destination physical address.
    • The physical address uniquely identifies the devices on the local network.
    • The trailer contains error-checking information.
  7. Finally the bits are encoded onto the media by the server network interface card (NIC).

Getting Data to the Right Application Link to heading

At the transport layer, information contained in the PDU header identifies the specific process or service running on the destination host device that will act on the data being delivered.

Hosts, whether they are clients or servers on the Internet, can run multiple network applications simultaneously.

The transport layer adds port numbers to its segment header information to ensure that the destination host knows which application process is to receive the packet. The end host assigns a port number to each type of traffic going in and out. The segment contains both source and destination ports in case the receiver needs to contact the sender.

As a result, a user can send and receive many types of traffic over a single network interface.

Common Network Ports Link to heading

Most commonly encountered ports are: 80, 443, 20, 21, 22, 23, 25, and 53.

Port NumberUsage
20File Transfer Protocol (FTP) Data Transfer
21File Transfer Protocol (FTP) Command Control
22Secure Shell (SSH)
23Telnet - Remote login service, unencrypted text messages
25Simple Mail Transfer Protocol (SMTP) E-mail Routing
53Domain Name System (DNS) service
80Hypertext Transfer Protocol (HTTP) used in World Wide Web
110Post Office Protocol (POP3) used by e-mail clients to retrieve e-mail from a server
119Network News Transfer Protocol (NNTP)
123Network Time Protocol (NTP)
143Internet Message Access Protocol (IMAP) Management of Digital Mail
161Simple Network Management Protocol (SNMP)
194Internet Relay Chat (IRC)
443HTTP Secure (HTTPS) HTTP over TLS/SSL