The Role of Ports
While the IP address identifies the machine, the Port Number identifies the specific application or service running on that machine that handles the communication.
Ports are 16-bit numbers (0 to 65535).
Port Categories
- Well-Known Ports (0-1023): Reserved for the most common internet services.
- Registered Ports (1024-49151): Assigned by IANA for specific user applications.
- Dynamic/Private Ports (49152-65535): Used by client applications for outgoing connections.
Critical Well-Known Ports for Security
| Port | Protocol | Service | Security Implication |
|---|---|---|---|
| 21 | TCP | FTP (File Transfer Protocol) | Often insecure (cleartext passwords). |
| 22 | TCP | SSH (Secure Shell) | Encrypted remote access (Good). |
| 23 | TCP | Telnet | Insecure remote access (Bad). |
| 80 | TCP | HTTP | Unencrypted web traffic. |
| 443 | TCP | HTTPS | Encrypted web traffic (Secure HTTP). |
| 3389 | TCP | RDP (Remote Desktop Protocol) | Common target for brute-force attacks. |