In this lesson, you will learn terms multiplexing and demultiplexing and how TCP and UDP can support multiple network applications using port numbers.
Transport Layer protocols (TCP and UDP) are responsible for supporting multiple network applications at the same instance and these applications can send and receive network data simultaneously. Transport Layer Protocols are capable of doing this by making use of application level addressing, known as port numbers. The data from different applications operating on a network device are multiplexed at the sending device using port numbers and demultiplexed at the receiving device, again using port numbers.
The two 16 bit fields in the TCP Header, Source port and Destination port identifies the port number which the application is listening at the sending device and receiving device. Since port number is a 16 bit number, the maximum possible value is 65535 ((2^16)-1).
To explain this concept more clearly, consider you are sitting comfortably at your home are using your laptop which is connected to internet. Consider you have only one network card attached to your laptop (so, you have only one MAC Address) and only one IP address. You are using a email client (Microsoft outlook or Mozilla Thunderbird), a web browser to view news online, a Java Chat application to chat with your online friends, and a Video sharing network utility, simultaneously. Devices located in the internet can see your laptop only as an IP address only.
Since you have only one MAC Address and IP address, how your TCP/IP protocol suit can find the exact application (which is waiting for its network data) to deliver the incoming data from internet for different network applications? What will happen if the incoming data for Video sharing utility is forwarded to Microsoft outlook or Mozilla Thunderbird email application?
Above questions are answered by port numbers. Each network application will bind itself to an available port number, so that TCP/IP protocol suit can identify the network application based on port numbers. So we can view port numbers as an application level address for network communication.
The port numbers are divided into three ranges.
The Well Known Ports are those in the range 0 - 1023. The Well Known Ports are assigned by the IANA (Internet Assigned Numbers Authority) for major protocols.
The Registered Ports are those in the range 1024 - 49151.
The Private Ports are those in the range 49152 - 65535.
||TCP Port Service Multiplexer (TCPMUX)
||Remote Job Entry (RJE)
||Message Send Protocol (MSP)
||FTP - Data
||FTP - Control
||SSH Remote Login Protocol
||Simple Mail Transfer Protocol (SMTP)
||Host Name Server (Nameserv)
||Login Host Protocol (Login)
||Domain Name System (DNS)
||Trivial File Transfer Protocol (TFTP)
||SNA Gateway Access Server
||Simple File Transfer Protocol (SFTP)
||NetBIOS Name Service
||NetBIOS Datagram Service
||Interim Mail Access Protocol (IMAP)
||NetBIOS Session Service
||Border Gateway Protocol (BGP)
||Gateway Access Control Protocol (GACP)
||Internet Relay Chat (IRC)
||Directory Location Service (DLS)
||Lightweight Directory Access Protocol (LDAP)
||Novell Netware over IP
||Simple Network Paging Protocol (SNPP)
Visit the following IANA link to know more about assigned ports.
You have learned the terms TCP multiplexing and demultiplexing and application addressing using port numbers. Click "Next" to continue.