Package: libpam-ldap Version: 184-8.5 Severity: normal Tags: patch the appended small fix makes pam_template_login_attribute and pam_template_login working for my case as described in the manpage. Please review and tell me if I missed something.
Thanks, Hermann -- System Information: Debian Release: 6.0.2 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-5-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) Shell: /bin/sh linked to /bin/dash Versions of packages libpam-ldap depends on: ii debconf [debconf-2.0] 1.5.36.1 Debian configuration management sy ii libc6 2.11.2-10 Embedded GNU C Library: Shared lib ii libldap-2.4-2 2.4.23-7.2 OpenLDAP libraries ii libpam-runtime 1.1.1-6.1 Runtime support for the PAM librar ii libpam0g 1.1.1-6.1 Pluggable Authentication Modules l libpam-ldap recommends no packages. Versions of packages libpam-ldap suggests: ii libnss-ldap 264-2.2 NSS module for using LDAP as a nam -- debconf information excluded
# HG changeset patch # Parent 26d0443ed3ec92e7f0fcc48eec53863aec4ef408 diff --git a/pam_ldap.c b/pam_ldap.c --- a/pam_ldap.c +++ b/pam_ldap.c @@ -3324,7 +3324,7 @@ if (rc == PAM_SUCCESS && session->info->tmpluser != NULL && session->conf->tmpluser != NULL && - strcmp (session->info->tmpluser, session->conf->tmpluser) == 0) + strcmp (session->info->tmpluser, session->conf->tmpluser) != 0) { (void) pam_set_data (pamh, PADL_LDAP_AUTH_DATA, (void *) strdup (session->info->username), @@ -3354,7 +3354,7 @@ */ if (rc == PAM_SUCCESS && session->info->tmpluser != NULL && session->conf->tmpluser != NULL && - strcmp (session->info->tmpluser, session->conf->tmpluser) == 0) + strcmp (session->info->tmpluser, session->conf->tmpluser) != 0) { /* keep original username for posterity */