Search code examples
networkingtcpipnetwork-protocolsports

Why is the maximum port range 65535 in the TCP/IP Suite?


My doubt is that - a port is just logical, so why such restriction ? Why can't I have a port of 9924593 or something like that ?


Solution

  • Look at the packet format for the TCP segment. The port identifiers are unsigned 16-bit integers, meaning that the largest number you can put in there is 216-1 = 65535.