fixed set iptables exception for each rules

This commit is contained in:
mh4x0f 2020-04-17 21:29:10 -03:00
parent 6eac18be5a
commit d3c43782cf
2 changed files with 6 additions and 4 deletions

View File

@ -117,6 +117,7 @@ All notable changes to this project will be documented in this file.
- Removed all files *.py compiler. [mh4x0f]
### Fixed
- fixed set iptables exception for each rules [mh4x0f]
- fixed typo name on readme.md [mh4x0f]
- fixed disable security auth wireless by default [mh4x0f]
- added depedency PyQt5-sip==12.7.2 to requirements.txt [mh4x0f]

View File

@ -105,16 +105,17 @@ class Mode(Qt.QObject):
self.interfacesLink = Refactor.get_interfaces()
print(display_messages("sharing internet connection with NAT...", info=True))
self.ifaceHostapd = self.conf.get("accesspoint", "interface")
try:
for ech in self.conf.get_all_childname("iptables"):
for ech in self.conf.get_all_childname("iptables"):
try:
ech = self.conf.get("iptables", ech)
if "$inet" in ech and self.interfacesLink["activated"][0] != None:
ech = ech.replace("$inet", self.interfacesLink["activated"][0])
if "$wlan" in ech:
ech = ech.replace("$wlan", self.ifaceHostapd)
popen(ech)
except Exception as e:
print(e)
except Exception as e:
print(e)
def Stop(self):
self.Shutdown()