firewalld change via XML file
Hello!
I have CentOS 7.6 Machine has two NICs; one NIC is assigned in public zone and second in trusted zone. What I am trying to do is: Code:
# firewall-cmd --permanent --zone=trusted --add-source=192.168.1.10 However, I am trying to figure out how to do this by XML file; zone config XML files are under: /etc/firewalld/zones, and there is trusted.xml Code:
<?xml version="1.0" encoding="utf-8"?> Code:
# firewall-cmd --zone=trusted --list-all |
are you sure the xml is correct?
I grabbed a random manpage https://www.systutorials.com/docs/li...irewalld.zone/ This is the structure of a zone configuration file: Code:
<?xml version="1.0" encoding="utf-8"?> |
Wow; Thank you!!
I had this: Code:
<sources ip="192.168.1.10"/> Code:
<source address="192.168.1.10"/> Now, it works (after --reload)! Code:
# firewall-cmd --zone=trusted --list-all |
BTW: Here is my XML file (that works):
Code:
# cat trusted.xml |
All times are GMT -5. The time now is 09:21 AM. |