14.3 C
New York
Tuesday, March 25, 2025

community – What’s the distinction between a connection and a session in networking, and the way are they associated?


I’ve come throughout each “connection” and “session” in networking, however I’m unable to know the precise which means of these two phrases and the way they differ.

What defines a connection in a protocol like TCP, and what’s a session and the way they’re associated?

I’ve tried google, chat gpt. Gpt gave the next ans:

  • A connection is a decrease‑degree, short-term channel established between two endpoints (reminiscent of your laptop and an internet server) that permits knowledge to stream reliably.
  • A session is the next‑degree, logical assemble that ties collectively a number of interactions or transactions between a consumer and a server over time.

I could not wrap my thoughts round what’s a channel, logical assemble and so forth. They appear a bit summary and obscure.

From TCP/IPProtocol Suite by Behrouz A Forouzan:

  • SSL differentiates a connection from a session. A session is an affiliation between a consumer and a server. After a session is established, the 2 events have frequent data such because the session identifier, the certificates authenticating every of them (ifnecessary), the compression technique (if wanted), the cipher suite, and a grasp secretthat is used to create keys for message authentication encryption.
  • For 2 entities to change knowledge, the institution of a session is important, however not enough; they should create a connection between themselves. The 2 entitiesexchange two random numbers and create, utilizing the grasp secret, the keys and parameters wanted for exchanging messages involving authentication and privateness.
  • A session can encompass many connections. A connection between two events canbe terminated and reestablished throughout the identical session. When a connection is terminated, the 2 events may also terminate the session, however it’s not necessary. A sessioncan be suspended and resumed once more.

It tells what does it imply to have a session being began, additionally it says session is an affiliation between consumer and server. What do i infer from the time period affiliation?

Is the above session the identical as http session?

What a connection/session intuitivly imply? Why do we’d like one? What does it intuitively imply for a connection/session to begin and finish or when does a connection will get began(I do know what’s a 3 method handshake course of) and identical for a session. I can not get the crux of it.

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles