Browse Source

fix PAM entry management

master
parent
commit
059db5ef59
  1. 8
      apache/apache.spec
  2. 10
      sudo/sudo.spec

8
apache/apache.spec

@ -634,12 +634,16 @@ AutoReqProv: no
%post
%if "%{mod_auth_pam}" == "yes"
# add PAM configuration entry
$RPM_INSTALL_PREFIX/sbin/pamtool -a -s -n "apache"
if [ $1 -eq 1 ]; then
$RPM_INSTALL_PREFIX/sbin/pamtool -a -s -n "apache"
fi
%endif
%preun
%if "%{mod_auth_pam}" == "yes"
# remove PAM configuration entry
$RPM_INSTALL_PREFIX/sbin/pamtool -r -s -n "apache"
if [ $1 -eq 0 ]; then
$RPM_INSTALL_PREFIX/sbin/pamtool -r -s -n "apache"
fi
%endif

10
sudo/sudo.spec

@ -38,7 +38,7 @@ Distribution: OpenPKG [REL]
Group: System
License: BSD
Version: 1.6.5p2
Release: 20020312
Release: 20020315
# list of sources
Source0: ftp://ftp.courtesan.com/pub/sudo/sudo-%{version}.tar.gz
@ -122,12 +122,16 @@ AutoReqProv: no
%post
%if "%{with_pam}" == "yes"
# add PAM configuration entry
$RPM_INSTALL_PREFIX/sbin/pamtool -a -s -n "sudo"
if [ $1 -eq 1 ]; then
$RPM_INSTALL_PREFIX/sbin/pamtool -a -s -n "sudo"
fi
%endif
%preun
%if "%{with_pam}" == "yes"
# remove PAM configuration entry
$RPM_INSTALL_PREFIX/sbin/pamtool -r -s -n "sudo"
if [ $1 -eq 0 ]; then
$RPM_INSTALL_PREFIX/sbin/pamtool -r -s -n "sudo"
fi
%endif

Loading…
Cancel
Save