summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone
diff options
context:
space:
mode:
authorFlorin Grad <florin@mandriva.com>2004-02-11 14:31:53 +0000
committerFlorin Grad <florin@mandriva.com>2004-02-11 14:31:53 +0000
commit55076ad3fd29fbe53dcb189031eb7201fa33a6d6 (patch)
tree367553113c4e767d0834b9805219fb1294b870e7 /perl-install/standalone
parentb8c57461b986447000774d441761a62edabcd83c (diff)
downloaddrakx-backup-do-not-use-55076ad3fd29fbe53dcb189031eb7201fa33a6d6.tar
drakx-backup-do-not-use-55076ad3fd29fbe53dcb189031eb7201fa33a6d6.tar.gz
drakx-backup-do-not-use-55076ad3fd29fbe53dcb189031eb7201fa33a6d6.tar.bz2
drakx-backup-do-not-use-55076ad3fd29fbe53dcb189031eb7201fa33a6d6.tar.xz
drakx-backup-do-not-use-55076ad3fd29fbe53dcb189031eb7201fa33a6d6.zip
remote debugging print commands
Diffstat (limited to 'perl-install/standalone')
-rw-r--r--perl-install/standalone/drakvpn92
1 files changed, 56 insertions, 36 deletions
diff --git a/perl-install/standalone/drakvpn b/perl-install/standalone/drakvpn
index f3d4a703f..5ff903fed 100644
--- a/perl-install/standalone/drakvpn
+++ b/perl-install/standalone/drakvpn
@@ -164,13 +164,13 @@ N("VPN connection.
This program is based on the following projects:
- - FreeSwan: http://www.freeswan.org/
- - Super-FreeSwan: http://www.freeswan.ca/
- - ipsec-tools: http://ipsec-tools.sourceforge.net/
- - ipsec-howto: http://www.ipsec-howto.org
+ - FreeSwan: \thttp://www.freeswan.org/
+ - Super-FreeSwan: \thttp://www.freeswan.ca/
+ - ipsec-tools: \thttp://ipsec-tools.sourceforge.net/
+ - ipsec-howto: \thttp://www.ipsec-howto.org
-Please read the at lest the ipsec-howto docs before
-going any further."), 1) or goto begin;
+Please read the at least the ipsec-howto docs
+before going any further."), 1) or goto begin;
if ($kernel_version < 2.5) {
system("/sbin/modprobe ipsec") if -e "/sbin/modprobe";
@@ -285,7 +285,10 @@ my $c;
if ($kernel_version > 2.5) {
$c = $in->ask_from_list_(N("Configuration file"),
N("Welcome to the
-%s and %s
+
+ - %s and
+ - %s
+
files configuration step.
You can now configure the sections of these files.
@@ -317,8 +320,8 @@ my $d = $in->ask_from_list_(N("%s entries", $ipsec_conf),
N("The %s file contents
is divided into sections.\n
You can now :\n
-- display, add, edit, or remove sections, then
-- commit the changes\n
+ - display, add, edit, or remove sections, then
+ - commit the changes
What would you like to do ?\n", $ipsec_conf),
[ N_("display"), N_("add"), N_("edit"), N_("remove"), N_("commit") ]) or goto step_configuration;
@@ -336,9 +339,9 @@ if ($d eq "display $ipsec_conf" || $d eq "display") {
goto step_configure_ipsec_conf;
} else {
$in->ask_okcancel(N("Display configuration"),
-N("The %s file does not exist\n
+N("The %s file does not exist.\n
This must be a new configuration.\n
-You'll have to go back and choose configure.\n", $ipsec_conf));
+You'll have to go back and choose 'add'.\n", $ipsec_conf));
goto step_configure_ipsec_conf;
}
@@ -686,32 +689,34 @@ and then click on next.\n", $ipsec_conf),
step_configure_racoon_conf:
-@section_names = network::ipsec::get_section_names_racoon_conf($racoon_conf,$racoon) if -e $racoon_conf;
-
-#print Dumper($racoon)."\n";
+@section_names = network::ipsec::get_section_names_racoon_conf($racoon) if $racoon;
my $choice = $section_names[0] if $section_names[0];
my $d = $in->ask_from_list_(N("%s entries", $racoon_conf),
N("The %s file contents
is divided into sections.\n
You can now :\n
-- display, add, edit, or remove sections, then
-- commit the changes\n
+ - display, add, edit, or remove sections, then
+ - commit the changes\n
What would you like to do ?\n", $racoon_conf),
[ N_("display"), N_("add"), N_("edit"), N_("remove"), N_("commit") ]) or goto step_configuration;
-#my $existing_section = "";
#- display $racoon_conf -------------------------
step_display_racoon_conf:
if ($d eq "display") {
- if (-e $racoon_conf) {
+
+ my $racoon_exists = 0;
+ foreach my $key (keys %{$racoon}) {
+ $racoon_exists = 1 if $racoon->{$key};
+ };
+
+ if ($racoon_exists) {
$in->ask_okcancel(N("Display configuration"),
network::ipsec::display_racoon_conf($racoon));
-#print Dumper($racoon)."\n";
goto step_configure_racoon_conf;
} else {
$in->ask_okcancel(N("Display configuration"),
@@ -746,8 +751,8 @@ if ($e eq "path") {
$in->ask_from('',
N("This section has to be on top of your
%s file.\n
-Make sure all other section follow these path
-sections.\n
+Make sure all the other sections follow
+these path sections.\n
Choose continue or previous when you are done.\n", $racoon_conf),
[ { label => N("path_type ="), val => \$path_section->{1}[1], list => [ 'certificate', 'pre_shared_key', 'include' ] },
{ label => N("real_file ="), val => \$path_section->{1}[2], type => 'entry' },
@@ -774,7 +779,7 @@ network::ipsec::add_section_racoon_conf($path_section, $racoon);
};
$in->ask_from('',
N("Make sure you already have the path sections
-on the top of your %s file.\n
+on the top of your %s file.
You can now choose the remote settings.
Choose continue or previous when you are done.\n", $racoon_conf),
@@ -835,20 +840,21 @@ goto step_configure_racoon_conf;
} elsif ($d eq "edit") {
$in->ask_from(N("Edit section"),
-N("Your %s file has several sections or connections.\n
-You can choose here below the one you want to edit
-and then click on next.\n", $racoon_conf),
+N("Your %s file has several sections or connections.
+
+You can choose here in the list below the one you want
+to edit and then click on next.\n", $racoon_conf),
[ { val => \$choice, list => \@section_names, label => N("Section names"), sort => 0, not_edit => 0 } ])
or goto step_configure_racoon_conf;
my $number = network::ipsec::matched_section_key_number_racoon_conf($choice,$racoon);
-print Dumper($racoon)."\n";
-
if ($choice =~ /^remote/) {
$in->ask_from('',
N("Your %s file has several sctions.\n
+
You can now edit the remote section entries.
+
Choose continue when you are done to write the data.\n", $racoon_conf),
[ { label => N("remote ="), val => \$racoon->{$number}{1}[1], type => 'entry' },
{ label => N("exchange_mode ="), val => \$racoon->{$number}{2}[1], type => 'entry' },
@@ -861,18 +867,20 @@ Choose continue when you are done to write the data.\n", $racoon_conf),
{ label => N("verify_cert ="), val => \$racoon->{$number}{7}[1], type => 'entry' },
{ label => N("my_identifier ="), val => \$racoon->{$number}{8}[1], type => 'entry' },
{ label => N("peers_identifier ="), val => \$racoon->{$number}{9}[1], type => 'entry' },
- { label => N("proposal ="), val => \$racoon->{$number+1}{1}[0], type => 'entry' },
- { label => N("encryption_algorithm ="), val => \$racoon->{$number+1}{2}[1], type => 'entry' },
- { label => N("hash_algorithm ="), val => \$racoon->{$number+1}{3}[1], type => 'entry' },
- { label => N("authentication_method ="), val => \$racoon->{$number+1}{4}[1], type => 'entry' },
- { label => N("dh_group ="), val => \$racoon->{$number+1}{5}[1], type => 'entry' },
+ { label => N("proposal ="), val => \$racoon->{$number+2}{1}[0], type => 'entry' },
+ { label => N("encryption_algorithm ="), val => \$racoon->{$number+2}{2}[1], type => 'entry' },
+ { label => N("hash_algorithm ="), val => \$racoon->{$number+2}{3}[1], type => 'entry' },
+ { label => N("authentication_method ="), val => \$racoon->{$number+2}{4}[1], type => 'entry' },
+ { label => N("dh_group ="), val => \$racoon->{$number+2}{5}[1], type => 'entry' },
]
) or goto step_configure_racoon_conf;
} elsif ($choice =~ /^sainfo/) {
$in->ask_from('',
-N("Your %s file has several sctions.\n
+N("Your %s file has several sctions.
+
You can now edit the sainfo section entries.
+
Choose continue when you are done to write the data.\n", $racoon_conf),
[ { label => N("sainfo_source_address ="), val => \$racoon->{$number}{1}[2], type => 'entry' },
{ label => N("sainfo_source_proto ="), val => \$racoon->{$number}{1}[3], type => 'entry' },
@@ -887,6 +895,20 @@ Choose continue when you are done to write the data.\n", $racoon_conf),
]
) or goto step_configure_racoon_conf;
+
+} elsif ($choice =~ /^path/) {
+ $in->ask_from('',
+N("This section has to be on top of your
+%s file.\n
+Make sure all other section follow these path
+sections.\n
+You can now edit the path entries.
+
+Choose continue or previous when you are done.\n", $racoon_conf),
+ [ { label => N("path_type ="), val => \$racoon->{$number}{1}[1], list => [ 'certificate', 'pre_shared_key', 'include' ] },
+ { label => N("real_file ="), val => \$racoon->{$number}{1}[2], type => 'entry' },
+ ]
+) or goto step_configure_racoon_conf;
}
goto step_configure_racoon_conf;
@@ -900,11 +922,9 @@ You can choose here below the one you want to remove
and then click on next.\n", $racoon_conf),
[ { val => \$choice, list => \@section_names, label => N("Section names"), sort => 0, not_edit => 0 } ]);
-#print Dumper($racoon)."\n";
my $number = network::ipsec::matched_section_key_number_racoon_conf($choice,$racoon);
network::ipsec::remove_section_racoon_conf($choice,$racoon,$number);
-#print Dumper($racoon)."\n";
- @section_names = network::ipsec::get_section_names_racoon_conf($racoon_conf,$racoon) if -e $racoon_conf;
+ @section_names = network::ipsec::get_section_names_racoon_conf($racoon) if $racoon;
goto step_configure_racoon_conf;