sudo and Pam-LDAP

KAeL kael at withinthebox.net
Fri Jan 21 21:38:36 UTC 2005


Nathan Blackham a écrit :
> This is a Question that I hope some one can answer.
> 
> I work for a university department and am putting a Linux image on the
> Lab machines in our department.  I would like to use Ubuntu, but I have
> a little problem.  We use an LDAP server for our login, so each user has
> a seperate login.  I know that I can use the PAM-LDAP module to use the
> logins, but how do I get that to work with Sudo?
> 
> 
> Thanks
> 
> Nathan
> 

apt-get install libpam-ldap
apt-get install libnss-ldap

then modify /etc/nsswitch :
# /etc/nsswitch.conf
passwd:         files ldap
group:          files ldap
shadow:         files ldap


then modify the files in /etc/pam.d :
# /etc/pam.d/common-account
account sufficient      pam_ldap.so
account required        pam_unix.so

# /etc/pam.d/common-auth
auth    sufficient      pam_ldap.so
auth    required        pam_unix.so nullok_secure try_first_pass

# /etc/pam.d/common-password
password   sufficient   pam_ldap.so
password   required   pam_unix.so nullok obscure min=4 max=8 md5

Mickael.




More information about the ubuntu-users mailing list