summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2004-01-20 17:29:11 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2004-01-20 17:29:11 +0000
commitde36c05053c47c1ec1167faadeee1d738ef7428f (patch)
tree53e01ded30d19c2d8d1d96c1d9ac7755e2587025 /perl-install
parent5a0f6495d19f328b145df9c9cae7575a86173951 (diff)
downloaddrakx-de36c05053c47c1ec1167faadeee1d738ef7428f.tar
drakx-de36c05053c47c1ec1167faadeee1d738ef7428f.tar.gz
drakx-de36c05053c47c1ec1167faadeee1d738ef7428f.tar.bz2
drakx-de36c05053c47c1ec1167faadeee1d738ef7428f.tar.xz
drakx-de36c05053c47c1ec1167faadeee1d738ef7428f.zip
do not gratuitously reinvent write_secret_backend()
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/network/modem.pm16
1 files changed, 1 insertions, 15 deletions
diff --git a/perl-install/network/modem.pm b/perl-install/network/modem.pm
index d7df7d75d..09c767773 100644
--- a/perl-install/network/modem.pm
+++ b/perl-install/network/modem.pm
@@ -106,21 +106,7 @@ END
my $chat_file = "$::prefix/etc/sysconfig/network-scripts/chat-ppp0";
output_with_perm($chat_file, 0600, @chat);
- if ($modem->{auth} eq 'PAP' || $modem->{auth} eq 'CHAP') {
- #- need to create a secrets file for the connection.
- my $secrets = "$::prefix/etc/ppp/" . lc($modem->{auth}) . "-secrets";
- my @l = cat_($secrets);
- my $replaced = 0;
- do { $replaced ||= 1
- if s/^\s*"?$toreplace{login}"?\s+ppp0\s+(\S+)/"$toreplace{login}" ppp0 "$toreplace{passwd}"/ } foreach @l;
- if ($replaced) {
- output($secrets, @l);
- } else {
- append_to_file($secrets, qq($toreplace{login} ppp0 "$toreplace{passwd}"\n));
- }
- #- restore access right to secrets file, just in case.
- chmod 0600, $secrets;
- }
+ write_secret_backend($toreplace{login}, $toreplace{passwd});
#- install kppprc file according to used configuration.
mkdir_p("$::prefix/usr/share/config");