Download as pdf or txt
Download as pdf or txt
You are on page 1of 18

Session Layer: Design

Issues and RPC


Diya Baweja (2203425)
Session
Layer In
OSI Model
• CHECKPOINTING
• Imagine you're downloading a large software update for your
computer, which is approximately 1 GB in size. You initiate
the download, and your download manager (e.g., a web
browser or dedicated download manager software) employs
checkpointing to ensure a smooth and efficient download
Functions
process.
• AUTHENTICATION AND AUTHORIZATION
Of Session
• Consider a secure online banking system. When you log in,
you provide your username and password (authentication) to
Layer
prove your identity. Once authenticated, the system checks
your account permissions to determine what actions you're
allowed to perform, such as viewing your account balance or
making transactions (authorization).
• ESTABLISHMENT, MAINTENANCE AND TERMINATION OF
SESSIONS
• Think of a phone call. When you dial a number
(establishment), you need to maintain the call to have a
conversation (maintenance). When you're finished, you say
goodbye and hang up (termination). These processes are
analogous to establishing, maintaining, and terminating
Functions
network sessions in communication systems.
• SYNCHRONIZATION
Of Session
• In a multi-user document editing application, multiple users
can simultaneously edit a shared document. Synchronization
Layer
mechanisms ensure that when one user is editing a specific
section of the document, other users can't edit the same
section at the same time. This prevents conflicts and data
corruption, ensuring that the document remains coherent
and consistent.
Design Issues In Session Layer
In the context of the session layer in networking, "design issues" refer
to the specific challenges and considerations that must be addressed
when designing, implementing, and managing this layer of a network
protocol or system. These issues are crucial to ensure that sessions
(connections) between devices or applications are established,
maintained, and terminated effectively, and that data exchange is
secure, reliable, and efficient.
Session Establishment:
• Negotiating Session Parameters: This is like agreeing
on how you'll communicate with someone over a
phone call. Before making the call, you both need to
decide if you're going to talk on a regular phone line,

DESIGN a video call, or some other way. This negotiation


ensures both parties understand how they'll
communicate.

ISSUES • Security Concerns: Think of this like the security


measures when you meet someone for the first time.
In the digital world, during session establishment,
you exchange digital "ID cards" to make sure you're
both who you say you are. For example, when you
visit a secure website, your browser and the
website's server exchange certificates to verify their
identities.
Session Maintenance:
• Data Exchange: Imagine you're playing an online
game with your friends. To keep the game running
smoothly, the game server must manage the
constant exchange of your game moves and those of
DESIGN other players. It breaks the game data into small
pieces, sends them, and your computer reassembles
these pieces to keep the game going.
ISSUES • Session Timeouts: This is similar to your computer
screen locking after a period of inactivity. For security
reasons, your computer requires you to re-enter your
password. Similarly, in a networked environment, if
you're not active, the session might "lock" to prevent
unauthorized access, and you'll need to "unlock" it by
logging in again.
Session Termination:
• Graceful Termination: This is like politely ending a
conversation or hanging up the phone after you've
finished talking. In digital terms, it means ensuring

DESIGN that any data that's in the process of being sent is


completed and received before the session ends, just
like making sure you finish saying what you need to

ISSUES before hanging up.


• Abrupt Termination: Sometimes, your call might get
disconnected suddenly because of a network
problem. In the digital world, it's like making sure you
don't lose important information when the
connection suddenly drops. This can be challenging
because you don't want to lose any data.
Managing Multiple Sessions:
• Session Multiplexing: Think of this as a traffic officer managing
several lanes of traffic onto a highway. They make sure cars from
different lanes merge smoothly without causing traffic jams.
Similarly, in a network, multiple sessions need to share the same

DESIGN "communication road" efficiently.


• Session Demultiplexing: Now, imagine you're the traffic officer at
the highway exit, and you need to make sure each car goes to the

ISSUES
correct destination. In the digital world, this is like ensuring that
data from various sources is correctly directed to the right place
in a high-traffic environment.
• Session Prioritization: In a busy restaurant, they prioritize serving
food based on how hungry the customers are. Similarly, in a
network, some sessions are more important than others. For
example, video calls are more important than background
software updates, so the network must give more "food"
(bandwidth) to the video call.
Error Handling:
• Error Detection: Think of it like putting a label on
your package when sending it through the mail. If
the label gets messed up or torn, the post office can
notice the problem and try to fix it. In the digital
DESIGN world, error detection means labeling data, so if it
gets messed up during transmission, the system can
spot the issue and ask for a fresh copy.
ISSUES • Error Recovery: Imagine you're writing a letter, and
your little brother accidentally scribbles over a word.
To fix it, you ask for a clean sheet and rewrite that
part. In the digital world, error recovery is like having
a plan to replace or repair any data that gets
damaged or changed during transmission, just like
rewriting that word in your letter.
• Remote Procedure Call (RPC) is a
protocol which works in the session
layer of the OSI model and in the
REMOTE Application Layer of TCP/IP model.
• It is useful in developing network
PROCEDURE applications which need services from
a remote computer in the network.
CALL(RPC) • With the help of Remote Procedure
Call, the programmer need not worry
about the complex structure of OSI
layer.
1
ELEMENTS OF RPC
MECHANISM
• Client
• Client Stub
• RPC Runtime
• Server Stub
• Server
RPC
EXECUTION
RPC EXECUTION
1. Client procedure calls client stub in normal way.
2. Client stub builds message, calls local OS.
3. Client's OS sends messages to remote OS.
4. Remote OS gives message to server stub.
5. Server stub unpacks parameters, calls server.
6. Server does work, returns result to the stub.
7. Server stub packs it in message, calls local OS.
8. Server's OS sends message to client's OS.
9. Client's OS gives message to client stub.
10. Stub unpacks the result, returns to client.
PARAMETER PASSING SEMANTICS

1 2 3
CALL BY VALUE CALL BY REFERENCE CALL BY
• Call by Value copies all • Call by reference passes COPY/RESTORE
parameters into a pointers to the • Call by copy/restore
message before parameters that are uses temporary storage
transmission. passed from the client accessible to both the
to the server. programs.
THANK YOU

You might also like