Multiplexing vs Demultiplexing

Before we get the the main question at hand, you should know that both multiplexing and demultiplexing takes place in the Transport Layer, which deals with send and receiving messages/packets among the Application and Network Layers via sockets.

What is multiplexing?

Multiplexing handles the data from multiple sockets and adds a transport layer header encapsulating the data so that it can be received/read  for demultiplexing.

What is de-multiplexing?

Demultiplexing is the receiving of the encapsulated data in the header to read the header and determine which socket to send it to.

In demultiplexing, when the data is received the destination host it looks at the “IP address” and “port #” to make sure it was sent to the right destination.

 

In demultiplexing there are 2 types:

Connectionless Demultiplexing: requires the “IP Address” and “destination port #” weather it be TCP or UDP. It requires only that two -tuple to identify where to send the datagram.

Connection-Oriented Demultiplexing: is only TCP viable and reuqires a four-tuple, meaning in order for the datagram to know where to be sent it needs (source IP address, source port number, destination IP address, destination port number).

You may also like...

2 Responses

  1. yara says:

    thanks! it help me to understand clearly

  2. Salman says:

    Thanks <3

Leave a Reply

Your email address will not be published. Required fields are marked *