diff --git a/firewall_config.example.py b/firewall_config.example.py index 29683c8..c3a088e 100644 --- a/firewall_config.example.py +++ b/firewall_config.example.py @@ -23,9 +23,11 @@ ### Specify each interface role +role = ['routeur', 'portail'] interfaces_type = { 'routable' : ['eth1', 'eth2'], + 'routable-portail': ['eth2'], 'sortie' : ['eth3', 'eth4'], 'admin' : ['eth5', 'eth6'] } diff --git a/main.py b/main.py index fa25d04..d589fef 100755 --- a/main.py +++ b/main.py @@ -371,7 +371,7 @@ class iptables: def capture_connection_portail(self, subtable="PORTAIL-CAPTIF-REDIRECT"): """Redirige les connexions 80 et 443 vers l'ip cible""" self.init_nat(subtable, decision="-") - for interface in self.interfaces_settings['routable']: + for interface in self.interfaces_settings['routable-portail']: self.jump_traficfrom("nat", interface, "PREROUTING", subtable, mode='4') for protocol in self.portail_settings['authorized_hosts']: