diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-02-20 12:37:51 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-02-20 12:37:51 +0000 |
commit | e22ce2c6238ae5b238a01e7a443a782409d65126 (patch) | |
tree | 5f4b45d90c68ae0e7ece3523c7d3fa2fbee26f91 /perl-install/any.pm | |
parent | 927f0695e36f024f44bed9ab406acc1dcaac1ff4 (diff) | |
download | drakx-backup-do-not-use-e22ce2c6238ae5b238a01e7a443a782409d65126.tar drakx-backup-do-not-use-e22ce2c6238ae5b238a01e7a443a782409d65126.tar.gz drakx-backup-do-not-use-e22ce2c6238ae5b238a01e7a443a782409d65126.tar.bz2 drakx-backup-do-not-use-e22ce2c6238ae5b238a01e7a443a782409d65126.tar.xz drakx-backup-do-not-use-e22ce2c6238ae5b238a01e7a443a782409d65126.zip |
factorize and update the reading of previous security level
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r-- | perl-install/any.pm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm index 4c12bf712..a2a81e502 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -1064,4 +1064,13 @@ sub ask_window_manager_to_logout { 1; } +sub get_secure_level { + my ($prefix) = @_; + + cat_("/etc/profile") =~ /export SECURE_LEVEL=(\d+)/ && $1 || #- 8.0 msec + cat_("/etc/profile.d/msec.sh") =~ /export SECURE_LEVEL=(\d+)/ && $1 || #- 8.1 msec + ${{ getVarsFromSh("$prefix/etc/sysconfig/msec") }}{SECURE_LEVEL} || #- 8.2 msec + $ENV{SECURE_LEVEL}; +} + 1; |