libpam-ldap for Debian
----------------------

- Be very careful when you use "sufficient pam_ldap.so" in Debian's
/etc/pam.d/common-* files: Some services can place other "required"
PAM-modules after the includes, which will be ignored if pam_ldap.so
succeeds. As a workaround, use something like the following construct:
        # Check local authentication first, so root can still login
        # while LDAP is down.
        auth [success=1 default=ignore] pam_unix.so
        auth required pam_ldap.so use_first_pass
        auth required pam_permit.so
The third line is needed, so "success=1" can skip over one module and
still has a module to jump to. Without that, PAM segfaults!

- If you want to use the "pam_check_host_attr" feature, make sure
"pam_unix.so" doesn't provide a valid "account" via the Name Service
Switch (NSS), which overrides your LDAP configuration. Don't use "ldap"
for "shadow" in /etc/nsswitch.conf, just use "shadow: files". For PAM,
use something like the following:
        # Try local /etc/shadow first and skip LDAP on success
        account [success=1 default=ignore] pam_unix.so
        account required pam_ldap.so
        account required pam_permit.so

- Ubuntu uses /etc/ldap.conf as libpam-ldap's configuration file and
/etc/ldap.secret as the file to store the password of the rootbinddn.
This file is shared with libnss-ldap, which should work for most
configurations. If separate configuration files for libnss-ldap and 
libpam-ldap are required, you can specify an alternate configuration file
in /etc/pam.d/common-* by adding a config=</path> argument to the
pam_ldap.so entry, such as:

    auth sufficient pam_ldap.so config=/etc/pam_ldap.conf

This would let you have two separate configurations: /etc/ldap.conf for
NSS, and /etc/pam_ldap.conf for PAM. Thanks to Etienne Goyer for pointing 
this out.

- See LDAP-Permissions.txt for details about the required LDAP permissions.

