mkpamrules: Support openSUSE's usage of /usr/etc/pam.d

to contain the pam configuration files:

https://lists.opensuse.org/opensuse-factory/2019-08/msg00113.html
This commit is contained in:
Yifan J 2019-11-13 11:06:42 +08:00
parent 8e10f0820c
commit 732d663c70
1 changed files with 6 additions and 0 deletions

View File

@ -8,6 +8,7 @@ outfile="$3"
service="xrdp-sesman"
pamdir="/etc/pam.d"
pamdir_suse="/usr/etc/pam.d"
guess_rules ()
{
@ -16,6 +17,11 @@ guess_rules ()
return
fi
if test -s "$pamdir_suse/common-account"; then
rules="suse"
return
fi
if test -s "$pamdir/common-account"; then
if grep "^@include" "$pamdir/passwd" >/dev/null 2>&1; then
rules="debian"