Firewalls

Linux filters packets in the kernel (netfilter). You'll meet three front-ends:

ToolDistroExample
firewalldRHEL/Fedorafirewall-cmd --add-service=http --permanent
ufwUbuntu/Debianufw allow 22/tcp
iptables/nftablesLow-level, alliptables -A INPUT -p tcp --dport 22 -j ACCEPT

firewalld (RHCSA):

$ firewall-cmd --permanent --add-service=https
$ firewall-cmd --reload
$ firewall-cmd --list-all

ufw (Ubuntu):

$ ufw allow 22/tcp
$ ufw enable
$ ufw status verbose
Exam trap: In firewalld, changes need --permanent and a --reload to survive; without --permanent they're lost on reload/reboot.