Jack Wallen shows you how to make working with CentOS 7 iptables much easier with the help of an ncurses-based GUI.
If you manage a CentOS 7 GUI-less server, you probably
know that managing the firewall can be a bit of a hassle. Wouldn't it be
nice if there was a handy, ncurses-based tool to make this process a
bit easier? Oh wait, there is. That tool is system-config-firewall-tui.
With this tool, you can easily set a service/interface/port as trusted,
to allow incoming traffic to that port. Only those trusted elements will
be allowed in.
Let's install and use system-config-firewall-tui.
Installation
The installation of the tool is pretty straightforward. Open up a terminal window and issue the command:sudo yum install system-config-firewall-tui
That will install the tool. However, when you go to run the command sudo system-config-firewall-tui, you'll be warned that firewalld is running, thus preventing the tool from opening. To get around this, issue the commands:
sudo systemctl stop firewalld.service sudo systemctl disable firewalld.service
Usage
At this point you can issue the command:sudo system-config-firewall-tui
The ncurses interface will open (Figure A). You should immediately notice that the firewall isn't enabled. Tab to the [ ] Enabled section and tap the keyboard spacebar to enable the firewall.
Figure A

You must enable the firewall to continue.
Figure B

Our list of available services.
Figure C

Adding additional ports to be considered trusted.
After you've added a custom port/protocol, tab down to Forward. In the resulting window (Figure D), you can list an interface as trusted.
Figure D

Setting a trusted interface.
Figure E

Setting up port forwarding.
Figure F

Rejecting ICMP types.
Figure H

Adding custom rules.
An easier route
Although system-config-firewall-tui isn't quite as flexible as working directly with iptables, if you're not ready to take the plunge into those deeper waters, this GUI is a much easier route to working with the firewall system on CentOS 7. Give system-config-firewall-tui a go and see if it doesn't turn into your go-to for the platform.Source : https://www.techrepublic.com/article/how-to-easily-manage-centos-firewalld-with-an-ncurses-tool/