From 7d8f3e9569fd0089eacb862321f74619bbef1e85 Mon Sep 17 00:00:00 2001 From: glondu Date: Sat, 29 Jul 2006 11:05:24 +0200 Subject: [PATCH] Pour Momo. darcs-hash:20060729090524-68412-bdb9b14724bf73d922823f7ff1c3dddd57557eb3.gz --- gestion/gen_confs/firewall.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gestion/gen_confs/firewall.py b/gestion/gen_confs/firewall.py index ef545e50..f565bac0 100755 --- a/gestion/gen_confs/firewall.py +++ b/gestion/gen_confs/firewall.py @@ -583,6 +583,9 @@ class firewall_komaz(firewall_crans) : # Classification des adhérents dans leur classe respective for machine in adherent.machines(): ip = machine.ip() + if not AddrInNet(ip, NETs['all']): + # Cas particulier d'une machine ayant une IP non CRANS + continue subnet = IpSubnet(machine.ip(), conf_fw.mask[-1]) iptables("-t mangle -A SUBNET-%(subnet)s -o crans -d %(ip)s " "-j CLASSIFY --set-class 1:%(class_id)s" % locals())