Open In App

Session Layer Messaging Protocols in IoT

Last Updated : 23 Jul, 2024
Summarize
Comments
Improve
Suggest changes
Like Article
Like
Share
Report
News Follow

The Session Layer (Layer 5 of the OSI model) manages and controls device connections. It initiates, manages, and ends communication sessions. Several protocols have been developed for the session layer in IoT to provide efficient and reliable communication. In this article, we will discover various Session Layer Messaging Protocols in IoT.

What are Session Layer Messaging Protocols in IoT?

The Session Layer manages the connection between two endpoints of a network by controlling data between sender and receiver whereas session layer protocols are responsible for the actual transmission of data in the IoT ecosystem. That’s why these Session Layer protocols are called IoT Messaging Protocols sometimes referred to as IoT Data Protocols. Most IoT applications use TCP and UDP for transport and these messaging protocols can operate over TCP or UDP.

Types of Session Layer Messaging Protocols

Different types of messaging protocols are present by different standardization organizations and depending upon their implementations they are used. Below are some of the popular IoT Messaging protocols used in the IoT ecosystem.

1. Message Queue Telemetry Transport (MQTT)

Message Queue Telemetry Transport is most widely adopted M2M(machine-to-machine) messaging protocol which was introduced by IBM in 1999. It uses a Publisher-Subscriber mechanism to operate means Publishers are lightweight sensors that collect data and connect to a mediation layer i.e. to a broker(or dealer) to send their data. Then subscribers are applications that collect required sensory data from the broker. This mechanism minimizes the payload. It is mainly used when a huge network of low-power small devices or where IoT devices may have limited bandwidth and need to be monitored or managed via the Internet.

Introduction-of-Message-Queue-Telemetry-Transport-Protocol-(MQTT)

MQTT

2. Advanced Message Queuing Protocol (AMQP)

Advanced Message Queuing Protocol is an open standard session layer protocol useful for sending transnational messages that is why mainly used in the financial industry. It runs over TCP (Transmission Control Protocol) or UDP (User Datagram Protocol) which is nearly similar to that of MQTT. But only difference is that Broker(Dealer) contains Exchange and Queues as a result it is focused on not losing messages. The exchange receives messages from publishers and distributes them to respective queues. Different subscribers collect topic wise sensory data from respective topic queues.

AMQP

AMQP

3. Constrained Application Protocol (CoAP)

Constrained Application Protocol is a session layer protocol that uses RESTful architecture which is a standard interface between HTTP clients and servers. It uses UDP (User Datagram Protocol) protocol for lightweight implementation so it is based on two sublayers i.e messaging and request/response for interaction. This protocol is designed to address IoT systems based on HTTP protocols. So, CoAP utilizes all HTTP methods like GET, PUT, PUSH, DELETE for message transmission, and accessing resources. It is a specialized web transfer protocol which uses constrained nodes/devices on same constrained networks in Internet of Things.

4. Secure Message Queue Telemetry Transport (SMQTT)

SMQTT works as an extension to MQTT protocol. It is based on an encryption messaging mechanism that’s why it provides a secure messaging standard. In this protocol, subscriber sends encrypted messages to all nodes and nodes receive encrypted message and use message after decryption. The encryption and decryption activities are carried out by using master key. This protocol follows four main stages i.e., Setup, Encryption, Publish, Decryption.

  • In Setup, both publisher and subscriber register themselves near broker and get master keys.
  • In the Encryption stage, broker encrypts published message.
  • In the Published stage, broker gives encrypted data to subscribers.
  • In the Decryption stage which is last stage, data /message is decrypted by subscriber using that master key.

5. Data Distribution Service (DDS)

Data Distribution Service is another publish-subscribe protocol but it is different from MQTT which connects them to server but here DDS protocol is a Broker-less architecture that’s why it is a high speed and high-performance protocol than MQTT as it is not dependent upon any intermediary system. It is designed by the OMG (Object Management Group) for device to device communications. This protocol has two fundamental sublayers i.e., Data-Centric Publish-Subscribe (DCPS) and Data Local Reconstruction Layer (DLRL). The DCPS layer is responsible for message delivering to subscriber and DLRL layer is responsible for simple integration of DDS in application layer but it is optional.

6. XMPP (Extensible Messaging and Presence Protocol)

XMPP is a short form for Extensible Messaging Presence Protocol. It’s protocol for streaming XML elements over a network in order to exchange messages and present information in close to real-time. Let’s dive into each character of word XMPP:

  • X : It means eXtensible. XMPP is an open-source project which can be changed or extended according to the need.
  • M : XMPP is designed for sending messages in real time. It has very efficient push mechanism compared to other protocols.
  • P : It determines whether you are online/offline/busy. It indicates the state.
  • P : XMPP is a protocol, that is, a set of standards that allow systems to communicate with each other.

Conclsuion

Session Layer Messaging Protocols are essential for managing and controlling connections in IoT systems, enabling efficient and dependable communication. Protocols such as MQTT, AMQP, CoAP, SMQTT, DDS, and XMPP cover a variety of needs, ranging from secure messaging and real-time data sharing to lightweight implementations for limited devices. Each protocol offers distinct features and uses, contributing to the complex and dynamic environment of IoT communication.

Frequently Asked Questions on Session Layer Messaging Protocols – FAQs

What is meant by session termination?

Session termination is defined as a process of ending the session communication. This process of session termination is important because it releases the resources and makes sure that both the communicating devices know that session has been ended.

What is authentication in session layer?

Authentication is the process of authenticating the identity of a person (or system) by confirming their credentials.

What are the functions of session layer?

The session layer is responsible for maintaining, establishing, synchronizing, and terminating sessions between them.

Can applications interact directly with session layer?

No, applications cannot directly interact with the session layer. They interacts with other higher layers namely presentation layer and application layer.



Next Article
Article Tags :

Similar Reads

three90RightbarBannerImg