Ports are end-to-end identifiers used in network communications between different end systems. On an end system, at the software level, ports are used to map network data transmissions to a specific process.
Port numbers are 16-bit unsigned integer values and consist of the following three ranges:
- Well-Known Ports: 0-1023
- Registered Ports: 1024-49151
- Dynamic Ports: 49152-65535
Ports are used by transportation protocols including Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) and are always associated with an IP address. For example, an HTTP request sent to a host with an IP address of
123.46.789 can be represented as
80 is the specified port.
Examples of well-known ports include
80 for HTTP requests,
53 for domain name service (DNS), and
25 for SMTP. These ports have been long-since defined and, given the early stages of the evolution of the Internet during which they were defined, there’s some really not-so-well-known entries. For example; port 17 is reserved for quote of the day services.
For a complete listing of all well-known, registered, and dynamic ports visit the related Wikipedia page.