From b63f653cb4edca6d69c0aef98e8416ba41741127 Mon Sep 17 00:00:00 2001 From: Florin Grad Date: Tue, 17 Sep 2002 17:02:28 +0000 Subject: small updates --- perl-install/network/shorewall.pm | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/perl-install/network/shorewall.pm b/perl-install/network/shorewall.pm index b48275ab3..a876ff379 100644 --- a/perl-install/network/shorewall.pm +++ b/perl-install/network/shorewall.pm @@ -1,7 +1,7 @@ package network::shorewall; # $Id$ -use diagnostics; -use strict; + + use detect_devices; use network::netconnect; @@ -72,18 +72,21 @@ sub read { if (my ($e) = get_config_file('masq')) { $conf{masquerade}{subnet} = $e->[1] if $e->[1]; } + require Data::Dumper; + print "before\n"; + print Data::Dumper->Dump([\%conf], ['%conf']); + put_in_hash(\%conf, default_interfaces()); + print "after\n"; + print Data::Dumper->Dump([\%conf], ['%conf']); foreach (get_config_file('interfaces')) { my ($name, $interface) = @$_; - if ($name eq 'net') { - $conf{net_interface} = $interface; - } elsif ($name eq 'masq') { + if ($name eq 'masq') { $conf{masquerade}{interface} = $interface; - } elsif ($name eq 'loc') { - push @{$conf{loc_interface}}, $interface; - } else { - log::l("unknown interface name $name"); + $conf{loc_interface} = [ difference2($conf{loc_interface}, [$interface]) ]; } } + print "after masq\n"; + print Data::Dumper->Dump([\%conf], ['%conf']); $conf{net_interface} && \%conf; } -- cgit v1.2.1