Free tools · CompTIA Security+
Ports cheat sheet + quiz
Every port the CompTIA Security+ (SY0-701) objectives expect you to know, with protocol and job. Then a quiz that drills them the way the exam asks: port plus symptom, pick the service.
| Port | Proto | Service | Job |
|---|---|---|---|
| 20 | TCP | FTP (data) | FTP active-mode data channel |
| 21 | TCP | FTP (control) | File Transfer Protocol control channel; cleartext credentials |
| 22 | TCP | SSH | Secure Shell remote administration; also SCP and SFTP |
| 23 | TCP | Telnet | Cleartext remote terminal; insecure, replace with SSH |
| 25 | TCP | SMTP | Simple Mail Transfer Protocol, server-to-server mail relay |
| 49 | TCP/UDP | TACACS+ | Cisco terminal access AAA; encrypts full payload |
| 53 | TCP/UDP | DNS | Domain Name System lookups (UDP) and zone transfers (TCP) |
| 67 | UDP | DHCP (server) | DHCP server listens; assigns addresses |
| 68 | UDP | DHCP (client) | DHCP client port |
| 69 | UDP | TFTP | Trivial FTP; unauthenticated, used for PXE/config backup |
| 80 | TCP | HTTP | Unencrypted web traffic |
| 88 | TCP/UDP | Kerberos | Network authentication tickets |
| 110 | TCP | POP3 | Post Office Protocol v3 mailbox download |
| 123 | UDP | NTP | Network Time Protocol; accurate time underpins log correlation |
| 135 | TCP | RPC | Microsoft RPC endpoint mapper |
| 137 | UDP | NetBIOS (name) | NetBIOS name service |
| 138 | UDP | NetBIOS (datagram) | NetBIOS datagram distribution |
| 139 | TCP | NetBIOS (session) | NetBIOS session service / legacy SMB |
| 143 | TCP | IMAP | Internet Message Access Protocol mailbox sync |
| 161 | UDP | SNMP (manager) | SNMP polling of managed devices |
| 162 | UDP | SNMP (trap) | SNMP trap alerts from managed devices |
| 389 | TCP/UDP | LDAP | Lightweight Directory Access Protocol directory queries |
| 443 | TCP | HTTPS | HTTP over TLS |
| 445 | TCP | SMB | Server Message Block file/print sharing; common lateral-movement target |
| 465 | TCP | SMTPS | SMTP over implicit TLS |
| 500 | UDP | IKE | Internet Key Exchange for IPsec VPN setup |
| 514 | UDP | Syslog | Centralized log forwarding to SIEM |
| 587 | TCP | SMTP (submission) | Authenticated mail client submission (STARTTLS) |
| 636 | TCP | LDAPS | LDAP over TLS |
| 993 | TCP | IMAPS | IMAP over TLS |
| 995 | TCP | POP3S | POP3 over TLS |
| 1194 | TCP/UDP | OpenVPN | Default OpenVPN tunnel port |
| 1433 | TCP | MSSQL | Microsoft SQL Server database |
| 1521 | TCP | Oracle DB | Oracle database listener |
| 1812 | UDP | RADIUS (auth) | RADIUS authentication (encrypts password only) |
| 1813 | UDP | RADIUS (acct) | RADIUS accounting |
| 3306 | TCP | MySQL | MySQL/MariaDB database |
| 3389 | TCP/UDP | RDP | Remote Desktop Protocol; gatekeep from the internet |
| 4500 | UDP | IPsec NAT-T | IPsec NAT traversal encapsulation |
| 5060 | TCP/UDP | SIP | Session Initiation Protocol VoIP signaling |
| 5061 | TCP | SIPS | SIP over TLS |
| 5432 | TCP | PostgreSQL | PostgreSQL database |
| 8080 | TCP | HTTP (alt) | Alternate HTTP / proxy port |
| 8443 | TCP | HTTPS (alt) | Alternate HTTPS port |
44 of 44 ports shown. Port numbers and services verified against the official objectives and IANA assignments.
How to learn ports for the exam
Exams rarely ask "what is port 443?" in isolation. They ask which port to open for a service to work, which to block to stop an attack, or what a firewall log means. Learn each port with its job and its direction:
- Know the pairs: 20/21 (FTP), 67/68 (DHCP), 80/443 (web), 110/143/993/995 (mail). Pairs are the exam's favorite trap.
- Know the secure replacements: Telnet 23 → SSH 22, FTP 21 → SFTP 22, HTTP 80 → HTTPS 443, LDAP 389 → LDAPS 636, SNMP 161 → SNMPv3.
- Say the protocol out loud: DNS is 53 UDP *and* TCP (zone transfers). Kerberos 88, LDAP 389, SMB 445, RDP 3389, syslog 514, NTP 123.
Worked example
A firewall log shows blocked outbound traffic to port 53 UDP and users report "the internet is down, but ping 8.8.8.8 works". DNS resolution is failing. The rule blocks name lookups while raw IP connectivity works. That reasoning pattern (port + symptom → service) is the whole quiz below.
Practice this in the app
Free to start. No card.
Port questions
22 SSH, 23 Telnet, 25 SMTP, 53 DNS, 67/68 DHCP, 69 TFTP, 80 HTTP, 110 POP3, 123 NTP, 143 IMAP, 161 SNMP, 389 LDAP, 443 HTTPS, 445 SMB, 514 syslog, 636 LDAPS, 993/995 secure mail, 1433/1521/3306 databases, 3389 RDP. All on this sheet. Filter by the search box and quiz yourself on the weak ones.
Ports are one row of the firewall lab
In SecLern's topology labs you write real allow/block rules with these ports. Then prove them with ping and port scans. The sheet above becomes muscle memory.
Free tier, no card. Pro starts with a 7-day trial; a card is required and you can cancel before day 7.