Allow Ports Over Specific IP - Firewalld

  Print
  • 19 June 2016 9:29 PM

1) Rule for allowing port 2408 in IP block 103.21.244.0/22 is as below:

firewall-cmd --permanent --zone=public --add-rich-rule='rule family="ipv4" source address="103.21.244.0/22" port protocol="tcp" port="2408" accept'

2) Allow port 443 for all IP's

firewall-cmd --permanent --zone=public --add-port=443/tcp

3) Reload firewall

firewall-cmd --reload

4) List all firewall rules

firewall-cmd --list-all


Did you find this article useful?   0 out of 0 people found this article useful.

Related Articles

Login

 
Forgot password?
Register now

Language