Managing CentOS 7 firewall with firewall-cmd

firewall-cmd --state

firewall-cmd --zone=public --permanent --add-port=2812/tcp
firewall-cmd --permanent --add-rich-rule 'rule family="ipv4" source address="x.x.x.x" log reject'

firewall-cmd --reload
firewall-cmd --list-all

Leave a Reply