CC ยท Network security fundamentals
Common ports: insecure vs secure
Well-known ports and protocols (HTTP/S, SSH, DNS, DHCP, SMTP, RDP...) and secure vs insecure variants.
Key points
- Know the pairs: HTTP 80 -> HTTPS 443
- Telnet 23 -> SSH 22
- FTP 21 -> SFTP (over SSH, 22) or FTPS
- SMTP 25 (server relay), DNS 53, DHCP 67/68 (UDP), RDP 3389, SNMP 161.
- Telnet, FTP and HTTP send data and credentials in cleartext.
- A port number is only a convention: moving a service to another port does not encrypt it.
Source: https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xhtml
Practice questions
Which TCP port does HTTPS use by default?
- 80
- 22
- 25
- 443
Show answer
Answer: D. 443
HTTPS is HTTP over TLS on port 443. Port 80 is plain HTTP, 22 is SSH and 25 is SMTP.
Which of these protocols send data without encryption by default?
- Telnet
- FTP
- HTTP
- SSH
- HTTPS
Show answer
Answer: A. Telnet, B. FTP, C. HTTP
Telnet, FTP and HTTP are cleartext. SSH and HTTPS encrypt traffic.
Moving a service to a non-standard port encrypts its traffic.
Show answer
Answer: False
False. The port number only says where the service listens. Encryption comes from the protocol, such as TLS or SSH.
Practice 8 questions on this topic in Bitzu
Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.
