|
|
@ -506,6 +506,11 @@ sub gst_network_get_broadcast_ping_cmd
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-2.2",
|
|
|
|
"mandrake-7.1" => "debian-2.2",
|
|
|
|
"mandrake-7.1" => "debian-2.2",
|
|
|
|
"mandrake-7.2" => "debian-2.2",
|
|
|
|
"mandrake-7.2" => "debian-2.2",
|
|
|
|
"mandrake-9.0" => "debian-2.2",
|
|
|
|
"mandrake-9.0" => "debian-2.2",
|
|
|
@ -1835,6 +1840,11 @@ sub gst_network_get_file
|
|
|
|
"ubuntu-7.04" => \&gst_network_deb22_get_file,
|
|
|
|
"ubuntu-7.04" => \&gst_network_deb22_get_file,
|
|
|
|
"ubuntu-7.10" => \&gst_network_deb22_get_file,
|
|
|
|
"ubuntu-7.10" => \&gst_network_deb22_get_file,
|
|
|
|
"ubuntu-8.04" => \&gst_network_deb22_get_file,
|
|
|
|
"ubuntu-8.04" => \&gst_network_deb22_get_file,
|
|
|
|
|
|
|
|
"ubuntu-8.10" => \&gst_network_deb22_get_file,
|
|
|
|
|
|
|
|
"ubuntu-9.04" => \&gst_network_deb22_get_file,
|
|
|
|
|
|
|
|
"ubuntu-9.10" => \&gst_network_deb22_get_file,
|
|
|
|
|
|
|
|
"ubuntu-10.04" => \&gst_network_deb22_get_file,
|
|
|
|
|
|
|
|
"ubuntu-10.10" => \&gst_network_deb22_get_file,
|
|
|
|
"suse-7.0" => \&gst_network_suse70_get_file,
|
|
|
|
"suse-7.0" => \&gst_network_suse70_get_file,
|
|
|
|
"suse-9.0" => \&gst_network_deb22_get_file,
|
|
|
|
"suse-9.0" => \&gst_network_deb22_get_file,
|
|
|
|
"suse-9.1" => \&gst_network_deb22_get_file,
|
|
|
|
"suse-9.1" => \&gst_network_deb22_get_file,
|
|
|
@ -2587,9 +2597,13 @@ sub gst_network_interfaces_set
|
|
|
|
|
|
|
|
|
|
|
|
foreach $i (keys %$values_hash)
|
|
|
|
foreach $i (keys %$values_hash)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
# delete it if it's no longer configured
|
|
|
|
# delete it if it's no longer configured or boot protocol is dhcp,
|
|
|
|
if (exists $$old_hash{$i}{"configuration"} &&
|
|
|
|
# so that network-manager see the card again
|
|
|
|
not exists $$values_hash{$i}{"configuration"})
|
|
|
|
if ((exists $$old_hash{$i}{"configuration"} &&
|
|
|
|
|
|
|
|
not exists $$values_hash{$i}{"configuration"}) ||
|
|
|
|
|
|
|
|
(exists $$values_hash{$i}{"configuration"} &&
|
|
|
|
|
|
|
|
$$values_hash{$i}{"configuration"}{"bootproto"} eq "dhcp")
|
|
|
|
|
|
|
|
)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
&$set_proc ($$values_hash{$i}, $$old_hash{$i}, 0, 1);
|
|
|
|
&$set_proc ($$values_hash{$i}, $$old_hash{$i}, 0, 1);
|
|
|
|
&$delete_proc ($$old_hash{$i});
|
|
|
|
&$delete_proc ($$old_hash{$i});
|
|
|
@ -3965,6 +3979,11 @@ sub gst_network_ensure_loopback_interface
|
|
|
|
"ubuntu-7.04" => "lo",
|
|
|
|
"ubuntu-7.04" => "lo",
|
|
|
|
"ubuntu-7.10" => "lo",
|
|
|
|
"ubuntu-7.10" => "lo",
|
|
|
|
"ubuntu-8.04" => "lo",
|
|
|
|
"ubuntu-8.04" => "lo",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "lo",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "lo",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "lo",
|
|
|
|
|
|
|
|
"ubuntu-10.04" => "lo",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "lo",
|
|
|
|
"suse-7.0" => "",
|
|
|
|
"suse-7.0" => "",
|
|
|
|
"suse-9.0" => "",
|
|
|
|
"suse-9.0" => "",
|
|
|
|
"suse-9.1" => "",
|
|
|
|
"suse-9.1" => "",
|
|
|
@ -4056,11 +4075,11 @@ sub gst_network_ensure_loopback_statichost
|
|
|
|
{
|
|
|
|
{
|
|
|
|
my $localhost = $$statichost{$lo_ip};
|
|
|
|
my $localhost = $$statichost{$lo_ip};
|
|
|
|
&gst_network_statichost_remove_alias ($localhost, $old_hostname) if ($old_hostname);
|
|
|
|
&gst_network_statichost_remove_alias ($localhost, $old_hostname) if ($old_hostname);
|
|
|
|
&gst_network_statichost_add_alias ($localhost, $hostname);
|
|
|
|
&gst_network_statichost_remove_alias ($localhost, $hostname);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
else
|
|
|
|
{
|
|
|
|
{
|
|
|
|
$$statichost{$lo_ip} = [ ("localhost", "localhost.localdomain", $hostname) ];
|
|
|
|
$$statichost{$lo_ip} = [ ("localhost") ];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -4068,10 +4087,13 @@ sub get_network_get_lo_ip
|
|
|
|
{
|
|
|
|
{
|
|
|
|
my ($statichost) = @_;
|
|
|
|
my ($statichost) = @_;
|
|
|
|
|
|
|
|
|
|
|
|
foreach $i (keys %$statichost)
|
|
|
|
# Ugly workarround, it is considered you have one lo only, which is wrong, so let's
|
|
|
|
{
|
|
|
|
# force the first to be 127.0.0.1 and let the script work for other ones as if they were
|
|
|
|
return $i if ($i =~ /^127\./);
|
|
|
|
# classic hosts entries... At least sudo won't break...
|
|
|
|
}
|
|
|
|
# foreach $i (keys %$statichost)
|
|
|
|
|
|
|
|
# {
|
|
|
|
|
|
|
|
# return $i if ($i =~ /^127\./);
|
|
|
|
|
|
|
|
# }
|
|
|
|
|
|
|
|
|
|
|
|
return "127.0.0.1";
|
|
|
|
return "127.0.0.1";
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -4140,6 +4162,11 @@ sub gst_network_get_parse_table
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-2.2",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
@ -4286,7 +4313,6 @@ sub gst_network_get_parse_table
|
|
|
|
HOST_CONF => "/etc/host.conf",
|
|
|
|
HOST_CONF => "/etc/host.conf",
|
|
|
|
HOSTS => "/etc/hosts",
|
|
|
|
HOSTS => "/etc/hosts",
|
|
|
|
HOSTNAME => "/etc/hostname",
|
|
|
|
HOSTNAME => "/etc/hostname",
|
|
|
|
SMB_CONF => "/etc/samba/smb.conf",
|
|
|
|
|
|
|
|
WVDIAL => "/etc/wvdial.conf"
|
|
|
|
WVDIAL => "/etc/wvdial.conf"
|
|
|
|
},
|
|
|
|
},
|
|
|
|
table =>
|
|
|
|
table =>
|
|
|
@ -4302,12 +4328,6 @@ sub gst_network_get_parse_table
|
|
|
|
[ "order", \&gst_parse_split_first_array, HOST_CONF, "order", "[ \t]+", ",[ \t]*" ],
|
|
|
|
[ "order", \&gst_parse_split_first_array, HOST_CONF, "order", "[ \t]+", ",[ \t]*" ],
|
|
|
|
[ "hostmatch", \&gst_parse_split_first_bool, HOST_CONF, "multi", "[ \t]+" ],
|
|
|
|
[ "hostmatch", \&gst_parse_split_first_bool, HOST_CONF, "multi", "[ \t]+" ],
|
|
|
|
[ "statichost", \&gst_parse_split_hash, HOSTS, "[ \t]+", "[ \t]+" ],
|
|
|
|
[ "statichost", \&gst_parse_split_hash, HOSTS, "[ \t]+", "[ \t]+" ],
|
|
|
|
[ "workgroup", \&gst_parse_ini, SMB_CONF, "global", "workgroup" ],
|
|
|
|
|
|
|
|
[ "smbdesc", \&gst_parse_ini, SMB_CONF, "global", "server string" ],
|
|
|
|
|
|
|
|
[ "winsserver", \&gst_parse_ini, SMB_CONF, "global", "wins server" ],
|
|
|
|
|
|
|
|
[ "winsuse", \&gst_parse_ini_bool, SMB_CONF, "global", "wins support" ],
|
|
|
|
|
|
|
|
[ "smbuse", \&gst_service_sysv_get_status_any, "smbd", "nmbd" ],
|
|
|
|
|
|
|
|
[ "smbinstalled", \&gst_service_sysv_installed, "samba" ],
|
|
|
|
|
|
|
|
[ "smartdhcpcd", \&gst_file_tool_installed, "pump" ],
|
|
|
|
[ "smartdhcpcd", \&gst_file_tool_installed, "pump" ],
|
|
|
|
[ "dialinstalled", \&gst_file_tool_installed, "wvdial" ],
|
|
|
|
[ "dialinstalled", \&gst_file_tool_installed, "wvdial" ],
|
|
|
|
[ "interface", \&gst_network_interfaces_get ]
|
|
|
|
[ "interface", \&gst_network_interfaces_get ]
|
|
|
@ -4571,6 +4591,11 @@ sub gst_network_get_interface_parse_table
|
|
|
|
"ubuntu-7.04" => "debian-3.0",
|
|
|
|
"ubuntu-7.04" => "debian-3.0",
|
|
|
|
"ubuntu-7.10" => "debian-3.0",
|
|
|
|
"ubuntu-7.10" => "debian-3.0",
|
|
|
|
"ubuntu-8.04" => "debian-3.0",
|
|
|
|
"ubuntu-8.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-10.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-3.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
@ -5419,6 +5444,11 @@ sub gst_network_get_replace_table
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.04" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-7.10" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
"ubuntu-8.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.04" => "debian-2.2",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-2.2",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
@ -5835,6 +5865,11 @@ sub gst_network_get_interface_replace_table
|
|
|
|
"ubuntu-7.04" => "debian-3.0",
|
|
|
|
"ubuntu-7.04" => "debian-3.0",
|
|
|
|
"ubuntu-7.10" => "debian-3.0",
|
|
|
|
"ubuntu-7.10" => "debian-3.0",
|
|
|
|
"ubuntu-8.04" => "debian-3.0",
|
|
|
|
"ubuntu-8.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-8.10" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-9.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-9.10" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-10.04" => "debian-3.0",
|
|
|
|
|
|
|
|
"ubuntu-10.10" => "debian-3.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-7.0" => "suse-7.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.0" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
|
"suse-9.1" => "suse-9.0",
|
|
|
|