authnz: some minor adjustment
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
# * LOCAL_USERS: List of local users to create
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
export VER_authnz=0.1.0
|
||||
export VER_authnz=0.1.1
|
||||
|
||||
# Users (from Ldap)
|
||||
add_remote_user()
|
||||
@@ -33,7 +33,7 @@ create_user()
|
||||
# Authentication
|
||||
authnz()
|
||||
{
|
||||
if [[ $WITH_LDAP_KERB==yes ]]; then
|
||||
if [[ $WITH_LDAP_KERB == yes ]]; then
|
||||
pkginst krb5-user libpam-krb5 libnss-ldap libpam-ldap nscd
|
||||
|
||||
backupdist /etc/krb5.conf /etc/libnss-ldap.conf /etc/pam_ldap.conf \
|
||||
@@ -51,6 +51,10 @@ authnz()
|
||||
done
|
||||
fi
|
||||
|
||||
if [[ -z $LOCAL_USERS ]]; then
|
||||
return 0
|
||||
fi
|
||||
|
||||
for usr in $LOCAL_USERS; do
|
||||
prnt I "Création de l'utilisateur $usr..."
|
||||
create_user $usr
|
||||
@@ -62,7 +66,7 @@ precheck_authnz()
|
||||
if [[ $WITH_LDAP_KERB == "yes" ]]; then
|
||||
if [[ -n $REMOTE_USERS ]]; then
|
||||
prnt I "Les utilisateurs distants suivants seront accessible :"
|
||||
prnt m "\t$REMOTE_USERS"
|
||||
prnt m "\t* $REMOTE_USERS"
|
||||
else
|
||||
prnt W "Pas d'utilisateur distant bien que LDAP/Kerberos soit activé !"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user