From fa56ab75a52cb335de51783f356dca47b56f6d04 Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Sat, 27 Aug 2005 04:00:41 +0000 Subject: [PATCH] Do not mapped disabled optional interfaces. Ticket #416 --- usr/local/www/firewall_nat_out.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/usr/local/www/firewall_nat_out.php b/usr/local/www/firewall_nat_out.php index 6bb2614be0..335e3df212 100755 --- a/usr/local/www/firewall_nat_out.php +++ b/usr/local/www/firewall_nat_out.php @@ -95,6 +95,12 @@ if (isset($_POST['save'])) { for ($j = 1; isset($config['interfaces']['opt' . $j]); $j++) $ifdescrs[] = "opt" . $j; foreach($ifdescrs as $if) { + if($if <> "lan" and $if <> "wan") { + /* interface is an optional. is it enabled? */ + if(!isset($config['interfaces'][$if]['enabled'])) { + continue; + } + } $natent = array(); $osn = convert_ip_to_network_format($config['interfaces'][$if]['ipaddr'], $config['interfaces'][$if]['subnet']);