Firewalld is a powerful and simple to use tool to manage a firewall on CentOS/RHEL 8 Server. By default, few services to receive incoming traffic are enabled. You can set up rules to either block or allow traffic. In CentOS/RHEL 8 nftables replaces iptables as the default Linux network packet filtering framework.
We can verify the active zone using the following command.
# firewall-cmd --get-active-zones
You can change the default zone also. Use the mentioned command to change the zone.
# firewall-cmd --set-default-zone=dmz
You can see all zone files at the below location.
# ls -l /usr/lib/firewalld/zones/
Use the cat command to view the external zone:
# cat /usr/lib/firewalld/zones/external.xml
Check the firewalld status.
# firewall-cmd --state
Configure Firewalld Temporary
You need to configure the firewall rules to the default zone so that your service will be accessible based on your requirement. But below changes will be temporary, When you reboot the server, changes will go.