diff --git a/gestion/gen_confs/firewall.py b/gestion/gen_confs/firewall.py index 490125b5..519e2ce7 100755 --- a/gestion/gen_confs/firewall.py +++ b/gestion/gen_confs/firewall.py @@ -504,7 +504,6 @@ class firewall_komaz(firewall_crans) : # On ne va pas plus loin si il ne s'agit pas de bittorrent iptables("-t mangle -A POSTROUTING -m mark ! --mark %s -j ACCEPT" % conf_fw.mark['bittorrent']) - print OK # On marque les paquets bittorrent uniquement iptables("-t mangle -A PREROUTING -p tcp -j CONNMARK --restore-mark") @@ -535,6 +534,7 @@ class firewall_komaz(firewall_crans) : prev_chain = "SUBNET-%s" % prev_subnet next_chain = "SUBNET-%s" % subnet redirect_chain('mangle', prev_chain, next_chain, subnet) + print OK adherents = db.search('paiement=ok')['adherent'] # On calcule le débit garanti pour un adhérent @@ -645,7 +645,7 @@ class firewall_komaz(firewall_crans) : if not recherche : # Il faut supprimer cette entrée option = '-D' - subnet = IpSubnet(ip.split, conf_fw.mask[len(conf_fw.mask)-1]) + subnet = IpSubnet(ip, conf_fw.mask[len(conf_fw.mask)-1]) regles = iptables("-t mangle -L SUBNET-%s -n | grep %s" % (subnet, ip)).split('\n') # On sélectionne la première qui doit contenir ce que l'on veut regle = regles[0].split()