Greetings!We have recently published 100+ articles on android tutorials with kotlin and java. If you need, you may visit Android Tutorial for beginners page. You can also check Kotlin Tutorial for beginners. Also, if you are interested in content writing, you can mail us at firstname.lastname@example.org.
In previous tutorials, we have studied about the various aspects of transport layer protocol. We explored about different functions that occur at this layer. In this tutorial, we will look at the session layer protocol, presentation layer protocol and their responsibilities.
Session Layer Protocol
Session Layer Protocol is the fifth layer, responsible for controlling the connections between multiple computers. This layer tracks the dialogs between various computers called sessions. The session layer establishes the sessions, controls and ends the sessions between local and remote applications.
The session layer manages any session by initiating the opening and closing of sessions between end-user application processes. Not just that, this layer controls the single or multiple connections for each end-user application, and is responsible for directly communicating with both the presentation and the transport layers. The services offered by the session layer are generally implemented in application environments using remote procedure calls (RPCs).
Sessions controlled by the session layer are most commonly implemented on Web browsers using protocols such as the Zone Information Protocol, the AppleTalk Protocol and the Session Control Protocol. These protocols also manage session restoration through checkpointing and recovery.
The session layer supports full-duplex and half-duplex operations and creates procedures for checkpointing, adjournment, restart and termination. It is also responsible for synchronizing information from different sources.
Thus, the main responsibilities for the session layer protocol are:
- Authentication and authorization: This layer is responsible for authenticating and authorising critical info such as the user passwords, digital signatures etc.
- Checkpointing: Let us understand this point through an example. While downloading a movie using torrent the internet connection may suddenly go off. In that case, if we do not use checkpoints, we will have to begin the download from the initial point, but checkpointing maintains a record of where the downloading had stopped through checkpoints and thus the download is resumed from where it was left off.
- Synchronisation: Sometimes the audio and video may be in different files and they may need to be synchronised. This task is performed at the session layer.
- Dialog Control: Let us consider the web conferences. We are able to control who speaks and who is to be muted through dialog controls. Thus, even though the link is full duplex, we have the power to use it as half duplex due to the presence of session layer.
- Logical Grouping Of Operations: The session layer ensures that the operations are performed atomically. Atomicity is maintained in the databases by ensuring that either all the sent commands have to be executed or none of them need are to be executed.
Presentation Layer Protocol
Presentation layer protocol is the 6th layer of the OSI model. This is responsible for presenting the data to the application layer in an accurate, well defined and standardised format. It is sometimes called the Syntax Layer.
The main responsibilities of the presentation layer protocol are:
- Character Translation: The presentation layer translates the characters and bytes appropriately for the two hosts to communicate. It follows data programming structure schemes which are developed for different languages and provides the real time syntax which is required for communication between two layers or networks.
- Encryption and decryption: The encryption and decryption is necessary for wherever security comes into picture. The presentation layer makes sure that appropriate encryption and decryption is done whenever and wherever needed.
- Compression and Decompression: The functions like zipping and unzipping are performed at the presentation layer.
- Graphic Handling: All the required graphics are handled at the presentation layer.
Q. Why are presentation and session layers not provided by OS?
Answer: The responsibilities taken by these two layers are completely optional and subject to change as per requirements. Thus, it is left to application to decide if it requires the layer or not. These layers are thus not provided by the operating system.
Q. Match the following layers with their functionality.
|Column 1||Column 2|
|i. Encryption||a. Data Link Layer|
|ii. Maintaining synchronization points||b. Network Layer|
|iii. Feedback Messages||c. Session Layer|
|iv. Physical Addressing System||d. Presentation Layer|
Answer: i-d, ii-c, iii-b, iv-a
Q. TCP/IP model does not have __ but OSI model has this layer.
a. Session Layer and Presentation layer
b. Application Layer
c. Network Layer
d. Transport Layer
That’s end of tutorial on session layer and presentation layer protocol.