Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the largest TCP/IP network port number allowable for IPv4?

What is the highest port number one can use?

like image 262
username Avatar asked Sep 22 '08 04:09

username


People also ask

How many ports are in IPv4?

The port number is an unsigned 16-bit integer, so 65535.

Why is port number 65535 Limited?

The port identifiers are unsigned 16-bit integers, meaning that the largest number you can put in there is 216-1 = 65535.

Can port 65535 be used?

Each port has a port number for identification. Port numbers 0 - 1023 are used for well-known ports. Port numbers 1024 - 65535 are available for the following user applications: Port numbers 1024 - 49151 are reserved for user server applications.


2 Answers

The port number is an unsigned 16-bit integer, so 65535.

like image 63
Greg Hewgill Avatar answered Oct 20 '22 04:10

Greg Hewgill


The largest port number is an unsigned short 2^16-1: 65535

A registered port is one assigned by the Internet Corporation for Assigned Names and Numbers (ICANN) to a certain use. Each registered port is in the range 1024–49151.

Since 21 March 2001 the registry agency is ICANN; before that time it was IANA.

Ports with numbers lower than those of the registered ports are called well known ports; port with numbers greater than those of the registered ports are called dynamic and/or private ports.

Wikipedia : Registered Ports

like image 24
Brian R. Bondy Avatar answered Oct 20 '22 03:10

Brian R. Bondy