7 Major Functions of Session layer in OSI Model

Do you know about the session layer in OSI model? & functions of session layer. If you want to know the answer to all these questions, then you have to read this article completely. In this, the session layer of the OSI model has been described in detail. So, let’s start without delay.

What is the Session layer?

The session layer is the 5th layer of the OSI model. The important function of this layer is to create a session between the client and the server.

All of you people in today’s time will be browsing all the websites, in which some websites will ask you to login. By logging into these sites, a session is created between the client and the server, so that the data transmission is done well between the user and the server.

There are also some sites in which after logging in, you are not asked to login again. This site automatically redirects the user to his/her account when the next time the user comes to the login page.

Apart from this, there are other sites in which the site shuts down after logging in due to an internet problem or some error while doing some transaction. Then the site refreshes and goes to the login page and asks to log in again. All this happens in banking transactions. It asks you to log in again to secure your transaction.

Responsibility of Session Layer

The session layer in OSI model has a lot of responsibilities so that it can establish a connection between the user to the server. Hence the data transmission process is done smoothly.


When we access a server from our device like mobile, laptop or computer, we have to do authentication. This means that when you access a server site like Gmail, Google Drive or SBI Internet Banking, this website only asks you to login. We verify our identity by providing a username and password to the server. This process is called authentication. The session layer uses this process to establish an accurate connection between the user and the server. After this a session is created between the client and the server.


When we login to a site by giving login credentials, and all the services that are there in it, the same service is all authorized to use. For example, when you login to Google by giving your user ID and password, then Google gives you access to use its service. Such as Gmail, Google Drive, Photos, Maps, YouTube, Calendar, etc. Basically, all these services give you authorization only after you login to Google’s server. 

All of you must have opened your account on many sites. Some of them will give you access to all the services on that site. There are also some sites in which you have got the authorization to access some services and some get the authorization after purchase. It is also the responsibility of session layer.


When you are using a browser like Google Chrome, Firefox, Microsoft Edge, etc., only then the system shut down for some reason. When you start the system and open the browser, then the option of restore comes on the right side. Pressing that restore option opens all the sites that you had opened in the browser before the system shutdown. The session layer saves the browsing data and helps in restoring it later. This restoration is possible because of the session layer. Because session beans are used to do the restoration in this layer.

If you are using any Internet banking like SBI Internet Banking and OTP has to be given, you have reached that far. But your system suddenly shuts down for some reason. When you start the computer again and open the browser and click on the restore option, then only this Internet banking site redirects you to the login page and asks you to log in again.

On these Internet banking sites, the session is restored. But the session at that time has to be discarded or cancelled here. So that no hacker can hijack that transaction.

For some security concerns, some companies allow to restore of the session and some cancel that session and ask to login with a new session.


When downloading large files from the Internet, pause and resume after some time, the download starts from where it was stopped. This happens because, when a large file starts downloading, only then some checkpoint is created in it automatically. This has the advantage that when the download is stopped due to some problem and starting it again, the download starts from the same point.

When you download large files from the Internet, only then some checkpoints are created by that download. For example, if you have a 1 GB file, then it can have a checkpoint every 200 MB. If 400 MB has been downloaded and due to some error, the download stops. If you resume that downloaded file again, it will start downloading from 400 MB and not from the beginning. That’s why checkpoint responsibility is very important for the session layer.


Sometimes when you are watching a video, first lisping occurs, and then audio comes. Or sometimes the audio comes first and is followed by the lisping. This happens because the audio file and the video file in that video are not synchronized properly.

Both audio and video are separate files that are synchronized through the session layer. The video is well synchronized, its audio and video play simultaneously. Therefore, the session layer has an important role in the synchronization process.

Functions of Session layer

Important functions of session layer is to establish, maintain, and terminate these sessions, allowing for reliable and synchronized data exchange. Here are some main functions of session layer.

Session Establishment

The session layer is responsible for establishing a session or connection between two devices before data can be exchanged. It sets up the necessary parameters, negotiates protocols and encryption methods, and ensures that both devices are ready for communication.

Session Management

Once a session is established, the session layer in OSI model manages and controls the ongoing communication. In this, the session layer manages some important information such as session id, session duration, and some session settings. It handles issues such as session re-establishment in the event of interruptions or failures.


The session layer in OSI model ensures that data exchange between the two devices remains synchronized. It defines checkpoints within the session to ensure that both devices are in agreement about the progress of the communication. If there are any errors or disruptions, the session layer can request retransmission or take corrective actions to maintain synchronization.

Data Segmentation

In some cases, the session layer may need to segment the data into smaller units before transmission. This segmentation allows for efficient transfer over the network and can also help manage flow control and congestion control within the session.

Session Termination

Once the communication between devices is complete, the session layer is responsible for terminating the session in an orderly manner. It ensures that all necessary data has been exchanged and that both devices are ready to end the session. This termination process may include closing open files, releasing resources, and notifying the network about the session closure.

Session Security

The session layer includes security mechanisms to protect the session and the data being exchanged. It may establish encryption methods, authentication procedures, and data integrity checks to ensure that sessions are protected from unauthorized access or tampering.

Session Recovery

In the event of a network failure or interruption, the session layer facilitates session recovery. This allows the session to be reestablished and communication to begin once network or device connectivity is restored.

Protocol of Session layer

There are many protocols used to create the session in the session layer. The table given below lists some of those protocols.

1ADSPAppleTalk Data Stream Protocol
2ASPApple Talk Session Protocol
3PAPPassword Authentication Protocol
4PPTPPoint-to-Point Tunnelling Protocol
5RPCRemote Produce Call Protocol
6RTCPReal-Time Transport Control Protocol
7SMPPShort Message Peer-to-Peer
8SCPSession Control Protocol
9ZIPZone Information Protocol
10SDPSockets Direct Protocol


In conclusion, in this article, we have provided complete information about the session layer in OSI model. In this, what is the session layer? what are the functions of session layer in OSI model? and also know what protocols are used in this layer. All these things have been told in this.

I hope you all have understood the session layer in OSI model. If you have any doubt regarding the session layer then definitely tell us in the comment box. We will do our best to solve your doubts. If you liked this article, then share it with your friends and family and share it on social media. Thanks for reading this article

Leave a Comment