summaryrefslogtreecommitdiffstats
path: root/knetworkconf/backends/network.pl.in
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-18 20:34:22 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-18 20:34:22 +0000
commitb09bffed6b43262948018dfb0f11890850ddf7c1 (patch)
tree138696bfcc7ac01070d0e8ecaa1cdf94611a2bd8 /knetworkconf/backends/network.pl.in
parent6d43944a7130b9d1b4ae3fba37b774aced8612cf (diff)
downloadtdeadmin-b09bffed6b43262948018dfb0f11890850ddf7c1.tar.gz
tdeadmin-b09bffed6b43262948018dfb0f11890850ddf7c1.zip
TQt4 port kdeadmin
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeadmin@1237416 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'knetworkconf/backends/network.pl.in')
-rw-r--r--knetworkconf/backends/network.pl.in166
1 files changed, 83 insertions, 83 deletions
diff --git a/knetworkconf/backends/network.pl.in b/knetworkconf/backends/network.pl.in
index 19c021a..6441761 100644
--- a/knetworkconf/backends/network.pl.in
+++ b/knetworkconf/backends/network.pl.in
@@ -37,7 +37,7 @@ if ($SCRIPTSDIR =~ /^@scriptsdir[@]/)
require "$SCRIPTSDIR/general.pl$DOTIN";
require "$SCRIPTSDIR/file.pl$DOTIN";
require "$SCRIPTSDIR/parse.pl$DOTIN";
-require "$SCRIPTSDIR/replace.pl$DOTIN";
+require "$SCRIPTSDIR/tqreplace.pl$DOTIN";
require "$SCRIPTSDIR/service.pl$DOTIN";
require "$SCRIPTSDIR/util.pl$DOTIN";
require "$SCRIPTSDIR/xml.pl$DOTIN";
@@ -161,10 +161,10 @@ sub gst_network_config_wireless
sub gst_network_enable_iface
{
my ($hash, $dev, $command_ifconfig) = @_;
- my ($address, $netmask, $bootproto, $remote_address);
+ my ($address, $nettqmask, $bootproto, $remote_address);
$address = $$hash{"configuration"}{"address"};
- $netmask = $$hash{"configuration"}{"netmask"};
+ $nettqmask = $$hash{"configuration"}{"nettqmask"};
$bootproto = $$hash{"configuration"}{"bootproto"};
$remote_address = $$hash{"configuration"}{"remote_address"};
@@ -188,7 +188,7 @@ sub gst_network_enable_iface
$command = $command_ifconfig;
$command .= " $dev";
$command .= " $address" if ($address);
- $command .= " netmask $netmask" if ($netmask);
+ $command .= " nettqmask $nettqmask" if ($nettqmask);
$command .= " dstaddr $remote_address" if ($remote_address);
$command .= " up";
}
@@ -432,19 +432,19 @@ sub gst_network_ipv4_vec2str
# Gets the subnet, in bitmap.
sub gst_network_ipv4_calc_subnet_vec
{
- my ($addr, $mask) = @_;
- my ($addrvec, $maskvec);
+ my ($addr, $tqmask) = @_;
+ my ($addrvec, $tqmaskvec);
$addrvec = &gst_network_ipv4_str2vec ($addr);
- $maskvec = &gst_network_ipv4_str2vec ($mask);
+ $tqmaskvec = &gst_network_ipv4_str2vec ($tqmask);
- return $addrvec & $maskvec;
+ return $addrvec & $tqmaskvec;
}
# What you're looking for.
sub gst_network_ipv4_calc_subnet
{
- my ($addr, $mask) = @_;
+ my ($addr, $tqmask) = @_;
return &gst_network_ipv4_vec2str (&gst_network_ipv4_calc_subnet_vec);
}
@@ -452,18 +452,18 @@ sub gst_network_ipv4_calc_subnet
# The broadcast, bitmap.
sub gst_network_ipv4_calc_bcast_vec
{
- my ($addr, $mask) = @_;
+ my ($addr, $tqmask) = @_;
$addrvec = &gst_network_ipv4_str2vec ($addr);
- $maskvec = &gst_network_ipv4_str2vec ($mask);
+ $tqmaskvec = &gst_network_ipv4_str2vec ($tqmask);
- return $addrvec | ~$maskvec;
+ return $addrvec | ~$tqmaskvec;
}
# And this returning the quad-dot notation.
sub gst_network_ipv4_calc_bcast
{
- my ($addr, $mask) = @_;
+ my ($addr, $tqmask) = @_;
return &gst_network_ipv4_vec2str (&gst_network_ipv4_calc_bcast_vec);
}
@@ -870,7 +870,7 @@ sub gst_network_freebsd_interfaces_get_info
{
$ifaces{$dev}{"hwaddr"} = $1 if /ether[ \t]+([^ \t]+)/i;
$ifaces{$dev}{"addr"} = $1 if /inet[ \t]+([^ \t]+)/i;
- $ifaces{$dev}{"mask"} = $1 if /netmask[ \t]+([^ \t]+)/i;
+ $ifaces{$dev}{"tqmask"} = $1 if /nettqmask[ \t]+([^ \t]+)/i;
$ifaces{$dev}{"bcast"} = $1 if /broadcast[ \t]+([^ \t]+)/i;
}
}
@@ -905,7 +905,7 @@ sub gst_network_linux_interfaces_get_info
{
$ifaces{$dev}{"hwaddr"} = $1 if /HWaddr[ \t]+([^ \t]+)/i;
$ifaces{$dev}{"addr"} = $1 if /addr:([^ \t]+)/i;
- $ifaces{$dev}{"mask"} = $1 if /mask:([^ \t]+)/i;
+ $ifaces{$dev}{"tqmask"} = $1 if /tqmask:([^ \t]+)/i;
$ifaces{$dev}{"bcast"} = $1 if /bcast:([^ \t]+)/i;
$ifaces{$dev}{"enabled"} = 1 if /^UP[ \t]/i;
}
@@ -1028,17 +1028,17 @@ sub gst_network_interface_ensure_broadcast_and_network
{
my ($iface) = @_;
- if (exists $$iface{"netmask"} &&
+ if (exists $$iface{"nettqmask"} &&
exists $$iface{"address"})
{
if (! exists $$iface{"broadcast"})
{
- $$iface{"broadcast"} = &gst_network_ipv4_calc_bcast ($$iface{"address"}, $$iface{"netmask"});
+ $$iface{"broadcast"} = &gst_network_ipv4_calc_bcast ($$iface{"address"}, $$iface{"nettqmask"});
}
if (! exists $$iface{"network"})
{
- $$iface{"network"} = &gst_network_ipv4_calc_subnet ($$iface{"address"}, $$iface{"netmask"});
+ $$iface{"network"} = &gst_network_ipv4_calc_subnet ($$iface{"address"}, $$iface{"nettqmask"});
}
}
}
@@ -1660,7 +1660,7 @@ sub gst_network_interfaces_get
{
delete $$hash{$i}{"addr"};
delete $$hash{$i}{"bcast"};
- delete $$hash{$i}{"mask"};
+ delete $$hash{$i}{"tqmask"};
}
foreach $i (@ifaces)
@@ -2182,7 +2182,7 @@ sub gst_network_suse70_interface_activate
sub gst_network_slackware91_interface_activate_by_dev
{
my ($dev, $enabled) = @_;
- my ($address, $netmask, $gateway);
+ my ($address, $nettqmask, $gateway);
my ($file) = "/etc/rc.d/rc.inet1.conf";
my ($ret) = 0;
@@ -2206,10 +2206,10 @@ sub gst_network_slackware91_interface_activate_by_dev
else
{
$address = &gst_parse_rcinet1conf ($file, $dev, "IPADDR");
- $netmask = &gst_parse_rcinet1conf ($file, $dev, "NETMASK");
- $gateway = &gst_network_get_gateway ($file, "GATEWAY", $address, $netmask);
+ $nettqmask = &gst_parse_rcinet1conf ($file, $dev, "NETMASK");
+ $gateway = &gst_network_get_gateway ($file, "GATEWAY", $address, $nettqmask);
- $ret = &gst_file_run ("ifconfig $dev $address netmask $netmask up");
+ $ret = &gst_file_run ("ifconfig $dev $address nettqmask $nettqmask up");
# Add the gateway if necessary
if ($gateway ne undef)
@@ -3526,34 +3526,34 @@ sub gst_network_suse90_set_auto
}
}
-# Return IP address or netmask, depending on $what
+# Return IP address or nettqmask, depending on $what
sub gst_network_pld10_get_ipaddr
{
my ($file, $key, $what) = @_;
- my ($ipaddr, $netmask, $ret, $i);
- my @netmask_prefixes = (0, 128, 192, 224, 240, 248, 252, 254, 255);
+ my ($ipaddr, $nettqmask, $ret, $i);
+ my @nettqmask_prefixes = (0, 128, 192, 224, 240, 248, 252, 254, 255);
$ipaddr = &gst_parse_sh($file, $key);
return undef if $ipaddr eq "";
if($ipaddr =~ /([^\/]*)\/([[:digit:]]*)/)
{
- $netmask = $2;
- return undef if $netmask eq "";
+ $nettqmask = $2;
+ return undef if $nettqmask eq "";
if($what eq "address")
{
return $1;
}
- for($i = 0; $i < int($netmask/8); $i++)
+ for($i = 0; $i < int($nettqmask/8); $i++)
{
$ret .= "255.";
}
- $ret .= "$netmask_prefixes[$b%8]." if $netmask < 32;
+ $ret .= "$nettqmask_prefixes[$b%8]." if $nettqmask < 32;
- for($i = int($netmask/8) + 1; $i < 4; $i++)
+ for($i = int($nettqmask/8) + 1; $i < 4; $i++)
{
$ret .= "0.";
}
@@ -3564,7 +3564,7 @@ sub gst_network_pld10_get_ipaddr
return undef;
}
-# Writes IP address or netmask, depending in $what, to $file
+# Writes IP address or nettqmask, depending in $what, to $file
sub gst_network_pld10_set_ipaddr
{
my ($file, $key, $what, $value) = @_;
@@ -3580,7 +3580,7 @@ sub gst_network_pld10_set_ipaddr
"254" => 7,
"255" => 8
);
- my ($ipaddr, $netmask);
+ my ($ipaddr, $nettqmask);
$ipaddr = &gst_parse_sh($file, $key);
return undef if $ipaddr eq "";
@@ -3593,8 +3593,8 @@ sub gst_network_pld10_set_ipaddr
{
if($value =~ /([[:digit:]]*).([[:digit:]]*).([[:digit:]]*).([[:digit:]]*)/)
{
- $netmask = $prefixes{$1} + $prefixes{$2} + $prefixes{$3} + $prefixes{$4};
- $ipaddr =~ s/\/[[:digit:]]*/\/$netmask/;
+ $nettqmask = $prefixes{$1} + $prefixes{$2} + $prefixes{$3} + $prefixes{$4};
+ $ipaddr =~ s/\/[[:digit:]]*/\/$nettqmask/;
}
}
@@ -3605,25 +3605,25 @@ sub gst_network_pld10_set_ipaddr
# it checks if a IP address is in the same network than another
sub gst_network_is_ip_in_same_network
{
- my ($address1, $address2, $netmask) = @_;
- my (@add1, @add2, @mask);
+ my ($address1, $address2, $nettqmask) = @_;
+ my (@add1, @add2, @tqmask);
my ($i);
return 0 if (($address1 eq undef) ||
($address2 eq undef) ||
- ($netmask eq undef));
+ ($nettqmask eq undef));
@add1 = split (/\./, $address1);
@add2 = split (/\./, $address2);
- @mask = split (/\./, $netmask);
+ @tqmask = split (/\./, $nettqmask);
for ($i = 0; $i < 4; $i++)
{
$add1[$i] += 0;
$add2[$i] += 0;
- $mask[$i] += 0;
+ $tqmask[$i] += 0;
- return 0 if (($add1[$i] & $mask[$i]) != ($add2[$i] & $mask[$i]));
+ return 0 if (($add1[$i] & $tqmask[$i]) != ($add2[$i] & $tqmask[$i]));
}
return 1;
@@ -3633,14 +3633,14 @@ sub gst_network_is_ip_in_same_network
sub gst_network_get_gateway_dev_from_address
{
my ($interface, $gateway) = @_;
- my ($address, $netmask, $key);
+ my ($address, $nettqmask, $key);
foreach $key (keys %$interface)
{
$address = $$interface{$key}{"address"};
- $netmask = $$interface{$key}{"netmask"};
+ $nettqmask = $$interface{$key}{"nettqmask"};
- return $$interface{$key}{"dev"} if (&gst_network_is_ip_in_same_network ($address, $gateway, $netmask));
+ return $$interface{$key}{"dev"} if (&gst_network_is_ip_in_same_network ($address, $gateway, $nettqmask));
}
return undef;
@@ -3658,23 +3658,23 @@ sub gst_network_get_plip_gateway
sub gst_network_get_gateway
{
- my ($file, $key, $address, $netmask) = @_;
+ my ($file, $key, $address, $nettqmask) = @_;
my ($gateway);
return undef if ($address eq undef);
$gateway = &gst_parse_sh ($file, $key);
- return $gateway if &gst_network_is_ip_in_same_network ($address, $gateway, $netmask);
+ return $gateway if &gst_network_is_ip_in_same_network ($address, $gateway, $nettqmask);
return undef;
}
sub gst_network_suse90_get_gateway
{
- my ($file, $address, $netmask) = @_;
+ my ($file, $address, $nettqmask) = @_;
my ($gateway) = &gst_parse_split_first_array_pos ($file, "default", 0, "[ \t]+", "[ \t]+");
- return $gateway if &gst_network_is_ip_in_same_network ($address, $gateway, $netmask);
+ return $gateway if &gst_network_is_ip_in_same_network ($address, $gateway, $nettqmask);
return undef;
}
@@ -3689,10 +3689,10 @@ sub gst_network_suse90_get_plip_gateway
sub gst_network_suse90_replace_gateway
{
- my ($file, $dev, $address, $netmask, $value) = @_;
+ my ($file, $dev, $address, $nettqmask, $value) = @_;
- return &gst_replace_split ($file, "default", "[ \t]+", "$value \- $dev") if &gst_network_is_ip_in_same_network ($address, $value, $netmask);
+ return &gst_replace_split ($file, "default", "[ \t]+", "$value \- $dev") if &gst_network_is_ip_in_same_network ($address, $value, $nettqmask);
# return &gst_replace_split ($file, "default", "[ \t]+", "$value \- $dev") ;
return undef;
@@ -4039,7 +4039,7 @@ sub gst_network_ensure_loopback_interface
"user" => 0,
"dev" => "lo",
"address" => "127.0.0.1",
- "netmask" => "255.0.0.0",
+ "nettqmask" => "255.0.0.0",
"broadcast" => "127.255.255.255",
"network" => "127.0.0.0",
"bootproto" => "none",
@@ -4674,7 +4674,7 @@ sub gst_network_get_interface_parse_table
# [ "user", \&gst_parse_sh_bool, IFCFG, USERCTL ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -4737,7 +4737,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_trivial, IFACE ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -4807,7 +4807,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_trivial, IFACE ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -4874,7 +4874,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_sh, IFCFG, NAME ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -4938,7 +4938,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_sh, IFCFG, NAME ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -5003,7 +5003,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_sh, IFCFG, NAME ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
[ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -5069,7 +5069,7 @@ sub gst_network_get_interface_parse_table
[ "auto", \&gst_parse_interfaces_option_kw_not, [INTERFACES, IFACE], "noauto" ],
# [ "name", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "name" ],
[ "address", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "address" ],
- [ "netmask", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "netmask" ],
+ [ "nettqmask", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "nettqmask" ],
[ "broadcast", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "broadcast" ],
[ "network", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "network" ],
[ "gateway", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "gateway" ],
@@ -5124,7 +5124,7 @@ sub gst_network_get_interface_parse_table
[ "auto", \&gst_network_debian_woody_get_auto, [INTERFACES, IFACE]],
# [ "name", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "name" ],
[ "address", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "address" ],
- [ "netmask", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "netmask" ],
+ [ "nettqmask", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "nettqmask" ],
[ "broadcast", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "broadcast" ],
[ "network", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "network" ],
[ "gateway", \&gst_parse_interfaces_option_str, [INTERFACES, IFACE], "gateway" ],
@@ -5176,7 +5176,7 @@ sub gst_network_get_interface_parse_table
[ "name", \&gst_network_suse70_parse_iface_sh, [IFCFG, IFACE], GST_IFACE_NAME ],
[ "dev", \&gst_network_suse70_parse_iface_sh, [IFCFG, IFACE], NETDEV ],
[ "address", \&gst_network_suse70_parse_iface_sh, [IFCFG, IFACE], IPADDR ],
- [ "netmask", \&gst_network_suse70_get_ifconfig_arg, [IFCFG, IFACE], netmask ],
+ [ "nettqmask", \&gst_network_suse70_get_ifconfig_arg, [IFCFG, IFACE], nettqmask ],
[ "broadcast", \&gst_network_suse70_get_ifconfig_arg, [IFCFG, IFACE], broadcast ],
# [ "network", \&gst_parse_trivial, 0 ], # not supported.
# [ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ], # not supported
@@ -5203,12 +5203,12 @@ sub gst_network_get_interface_parse_table
[ "auto", \&gst_network_suse90_get_auto, IFCFG, STARTMODE ],
[ "bootproto", \&gst_network_parse_bootproto, IFCFG, BOOTPROTO ],
[ "address", \&gst_parse_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_parse_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_parse_sh, IFCFG, NETMASK ],
[ "remote_address", \&gst_parse_sh, IFCFG, REMOTE_IPADDR ],
[ "essid", \&gst_parse_sh, IFCFG, WIRELESS_ESSID ],
[ "key_type", \&gst_network_get_wep_key_type, [ \&gst_parse_sh, IFCFG, WIRELESS_KEY ]],
[ "key", \&gst_network_get_wep_key, [ \&gst_parse_sh, IFCFG, WIRELESS_KEY ]],
- [ "gateway", \&gst_network_suse90_get_gateway, ROUTE_CONF, "%address%", "%netmask%" ],
+ [ "gateway", \&gst_network_suse90_get_gateway, ROUTE_CONF, "%address%", "%nettqmask%" ],
[ "gateway", \&gst_network_suse90_get_plip_gateway, ROUTE_CONF, "%remote_address%" ],
# Modem stuff goes here
[ "serial_port", \&gst_parse_sh, IFCFG, MODEM_DEVICE ],
@@ -5252,7 +5252,7 @@ sub gst_network_get_interface_parse_table
# [ "name", \&gst_parse_sh, IFCFG, DEVICE ],
[ "dev", \&gst_parse_sh, IFCFG, DEVICE ],
[ "address", \&gst_network_pld10_get_ipaddr, IFCFG, IPADDR, "address" ],
- [ "netmask", \&gst_network_pld10_get_ipaddr, IFCFG, IPADDR, "netmask" ],
+ [ "nettqmask", \&gst_network_pld10_get_ipaddr, IFCFG, IPADDR, "nettqmask" ],
# [ "broadcast", \&gst_parse_sh, IFCFG, BROADCAST ],
# [ "network", \&gst_parse_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ],
@@ -5300,8 +5300,8 @@ sub gst_network_get_interface_parse_table
[ "user", \&gst_parse_trivial, 0 ], # not supported.
[ "dev", \&gst_parse_trivial, IFACE ],
[ "address", \&gst_parse_rcinet1conf, [RC_INET_CONF, IFACE], IPADDR ],
- [ "netmask", \&gst_parse_rcinet1conf, [RC_INET_CONF, IFACE], NETMASK ],
- [ "gateway", \&gst_network_get_gateway, RC_INET_CONF, GATEWAY, "%address%", "%netmask%" ],
+ [ "nettqmask", \&gst_parse_rcinet1conf, [RC_INET_CONF, IFACE], NETMASK ],
+ [ "gateway", \&gst_network_get_gateway, RC_INET_CONF, GATEWAY, "%address%", "%nettqmask%" ],
[ "auto", \&gst_network_slackware91_get_auto, [RC_INET, RC_LOCAL, IFACE]],
[ "bootproto", \&gst_network_slackware91_parse_bootproto, [RC_INET_CONF, IFACE]],
[ "essid", \&gst_parse_wireless_opts, [ WIRELESS, IFACE ], \&gst_network_get_wireless_ifaces, ESSID ],
@@ -5348,7 +5348,7 @@ sub gst_network_get_interface_parse_table
[ "user", \&gst_parse_trivial, 0 ], # not supported.
[ "dev", \&gst_parse_trivial, IFACE ],
[ "address", \&gst_parse_confd_net_re, NET, "config_%dev%", "^[ \t]*([0-9\.]+)" ],
- [ "netmask", \&gst_parse_confd_net_re, NET, "config_%dev%", "netmask[ \t]+([0-9\.]*)" ],
+ [ "nettqmask", \&gst_parse_confd_net_re, NET, "config_%dev%", "nettqmask[ \t]+([0-9\.]*)" ],
[ "remote_address", \&gst_parse_confd_net_re, NET, "config_%dev%", "dest_address[ \t]+([0-9\.]*)" ],
# [ "gateway", \&gst_parse_sh_re, NET, "gateway", "%dev%/([0-9\.\:]*)" ],
[ "gateway", \&gst_network_gentoo_parse_gateway, [ NET, IFACE ]],
@@ -5396,15 +5396,15 @@ sub gst_network_get_interface_parse_table
# we need to double check these values both in the start_if and in the rc.conf files, in this order
[ "address", \&gst_parse_startif, STARTIF, "inet[ \t]+([0-9\.]+)" ],
[ "address", \&gst_parse_sh_re, RC_CONF, "ifconfig_%dev%", "inet[ \t]+([0-9\.]+)" ],
- [ "netmask", \&gst_parse_startif, STARTIF, "netmask[ \t]+([0-9\.]+)" ],
- [ "netmask", \&gst_parse_sh_re, RC_CONF, "ifconfig_%dev%", "netmask[ \t]+([0-9\.]+)" ],
+ [ "nettqmask", \&gst_parse_startif, STARTIF, "nettqmask[ \t]+([0-9\.]+)" ],
+ [ "nettqmask", \&gst_parse_sh_re, RC_CONF, "ifconfig_%dev%", "nettqmask[ \t]+([0-9\.]+)" ],
[ "remote_address", \&gst_parse_startif, STARTIF, "dest_address[ \t]+([0-9\.]+)" ],
[ "remote_address", \&gst_parse_sh_re, RC_CONF, "ifconfig_%dev%", "dest_address[ \t]+([0-9\.]+)" ],
[ "essid", \&gst_parse_startif, STARTIF, "ssid[ \t]+(\".*\"|[^\"][^ ]+)" ],
[ "essid", \&gst_parse_sh_re, RC_CONF, "ifconfig_%dev%", "ssid[ \t]+([^ ]*)" ],
# this is for plip interfaces
[ "gateway", \&gst_network_get_plip_gateway, RC_CONF, "defaultrouter", "%remote_address%" ],
- [ "gateway", \&gst_network_get_gateway, RC_CONF, "defaultrouter", "%address%", "%netmask%" ],
+ [ "gateway", \&gst_network_get_gateway, RC_CONF, "defaultrouter", "%address%", "%nettqmask%" ],
[ "enabled", \&gst_network_interface_active, IFACE, \&gst_network_freebsd5_active_interfaces_get ],
[ "bootproto", \&gst_network_parse_bootproto, RC_CONF, "ifconfig_%dev%" ],
# Modem stuff
@@ -5961,7 +5961,7 @@ sub gst_network_get_interface_replace_table
[ "dev", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6020,7 +6020,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6082,7 +6082,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6142,7 +6142,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6202,7 +6202,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6262,7 +6262,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
[ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6324,7 +6324,7 @@ sub gst_network_get_interface_replace_table
[ "auto", \&gst_replace_interfaces_option_kw_not, [INTERFACES, IFACE], "noauto" ],
[ "name", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "name" ],
[ "address", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "address" ],
- [ "netmask", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "netmask" ],
+ [ "nettqmask", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "nettqmask" ],
[ "broadcast", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "broadcast" ],
[ "network", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "network" ],
[ "gateway", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "gateway" ],
@@ -6372,7 +6372,7 @@ sub gst_network_get_interface_replace_table
[ "bootproto", \&gst_network_deb22_replace_bootproto, [INTERFACES, IFACE]],
[ "auto", \&gst_network_debian_woody_set_auto, [INTERFACES, IFACE]],
[ "address", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "address" ],
- [ "netmask", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "netmask" ],
+ [ "nettqmask", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "nettqmask" ],
[ "gateway", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "gateway" ],
[ "essid", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "wireless-essid" ],
[ "key", \&gst_replace_interfaces_option_str, [INTERFACES, IFACE], "wireless-key" ],
@@ -6432,7 +6432,7 @@ sub gst_network_get_interface_replace_table
[ "name", \&gst_network_suse70_replace_iface_sh, [IFCFG, IFACE], GST_IFACE_NAME ],
[ "address", \&gst_network_suse70_replace_iface_sh, [IFCFG, IFACE], IPADDR ],
[ "address", \&gst_network_suse70_set_ifconfig_ip, [IFCFG, IFACE] ],
- [ "netmask", \&gst_network_suse70_set_ifconfig_arg, [IFCFG, IFACE], netmask ],
+ [ "nettqmask", \&gst_network_suse70_set_ifconfig_arg, [IFCFG, IFACE], nettqmask ],
[ "broadcast", \&gst_network_suse70_set_ifconfig_arg, [IFCFG, IFACE], broadcast ],
# [ "network", \&gst_parse_trivial, 0 ], # not supported.
# [ "gateway", \&gst_parse_sh, IFCFG, GATEWAY ], # not supported
@@ -6458,7 +6458,7 @@ sub gst_network_get_interface_replace_table
[ "auto", \&gst_network_suse90_set_auto, IFCFG, STARTMODE ],
[ "bootproto", \&gst_network_suse90_replace_bootproto, IFCFG, BOOTPROTO ],
[ "address", \&gst_replace_sh, IFCFG, IPADDR ],
- [ "netmask", \&gst_replace_sh, IFCFG, NETMASK ],
+ [ "nettqmask", \&gst_replace_sh, IFCFG, NETMASK ],
[ "remote_address", \&gst_replace_sh, IFCFG, REMOTE_IPADDR ],
[ "essid", \&gst_replace_sh, IFCFG, WIRELESS_ESSID ],
[ "key", \&gst_replace_sh, IFCFG, WIRELESS_KEY ],
@@ -6506,7 +6506,7 @@ sub gst_network_get_interface_replace_table
# [ "name", \&gst_replace_sh, IFCFG, NAME ],
[ "dev", \&gst_replace_sh, IFCFG, DEVICE ],
[ "address", \&gst_network_pld10_set_ipaddr, IFCFG, IPADDR, "address" ],
- [ "netmask", \&gst_network_pld10_set_ipaddr, IFCFG, IPADDR, "netmask" ],
+ [ "nettqmask", \&gst_network_pld10_set_ipaddr, IFCFG, IPADDR, "nettqmask" ],
# [ "broadcast", \&gst_replace_sh, IFCFG, BROADCAST ],
# [ "network", \&gst_replace_sh, IFCFG, NETWORK ],
[ "gateway", \&gst_replace_sh, IFCFG, GATEWAY ],
@@ -6551,7 +6551,7 @@ sub gst_network_get_interface_replace_table
table =>
[
[ "address", \&gst_replace_rcinet1conf, [ RC_INET_CONF, IFACE ], IPADDR ],
- [ "netmask", \&gst_replace_rcinet1conf, [ RC_INET_CONF, IFACE ], NETMASK ],
+ [ "nettqmask", \&gst_replace_rcinet1conf, [ RC_INET_CONF, IFACE ], NETMASK ],
[ "gateway", \&gst_replace_rcinet1conf_global, RC_INET_CONF, GATEWAY ],
[ "bootproto", \&gst_network_slackware91_replace_bootproto, [ RC_INET_CONF, IFACE ] ],
[ "auto", \&gst_network_slackware91_set_auto, [ RC_INET, RC_LOCAL, IFACE ] ],
@@ -6603,7 +6603,7 @@ sub gst_network_get_interface_replace_table
[ "bootproto", \&gst_network_gentoo_replace_bootproto, [ NET, IFACE ]],
[ "address", \&gst_replace_confd_net_re, NET, "config_%dev%", "^[ \t]*([0-9\.]+)" ],
[ "address", \&gst_replace_confd_net_re, NET, "config_%dev%", "^[ \t]*([0-9\.]+)" ],
- [ "netmask", \&gst_replace_confd_net_re, NET, "config_%dev%", "[ \t]+netmask[ \t]+[0-9\.]*", " netmask %netmask%"],
+ [ "nettqmask", \&gst_replace_confd_net_re, NET, "config_%dev%", "[ \t]+nettqmask[ \t]+[0-9\.]*", " nettqmask %nettqmask%"],
[ "broadcast", \&gst_replace_confd_net_re, NET, "config_%dev%", "[ \t]+broadcast[ \t]+[0-9\.]*", " broadcast %broadcast%" ],
[ "remote_address", \&gst_replace_confd_net_re, NET, "config_%dev%", "[ \t]+dest_address[ \t]+[0-9\.]*", " dest_address %remote_address%" ],
[ "gateway", \&gst_replace_confd_net_re, NET, "routes_%dev%", "[ \t]*default[ \t]+(via|gw)[ \t]+[0-9\.\:]*", "default via %gateway%" ],
@@ -6648,7 +6648,7 @@ sub gst_network_get_interface_replace_table
[ "auto", \&gst_network_freebsd5_set_auto, [ RC_CONF, IFACE ]],
[ "bootproto", \&gst_network_freebsd5_replace_bootproto, [ RC_CONF, IFACE ]],
[ "address", \&gst_replace_sh_re, RC_CONF, "ifconfig_%dev%", "inet[ \t]+([0-9\.]+)", "inet %address%" ],
- [ "netmask", \&gst_replace_sh_re, RC_CONF, "ifconfig_%dev%", "netmask[ \t]+([0-9\.]+)", " netmask %netmask%" ],
+ [ "nettqmask", \&gst_replace_sh_re, RC_CONF, "ifconfig_%dev%", "nettqmask[ \t]+([0-9\.]+)", " nettqmask %nettqmask%" ],
[ "remote_address", \&gst_replace_sh_re, RC_CONF, "ifconfig_%dev%", "dest_address[ \t]+([0-9\.]+)", " dest_address %remote_address%" ],
[ "essid", \&gst_network_freebsd5_replace_essid, [ RC_CONF, STARTIF, IFACE ]],
# Modem stuff