summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2004-08-27 16:15:23 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:52:31 -0500
commit725d93954896052e24a6870e9e5f14106063fe78 (patch)
tree86ff15c6ca1998bffb6e052d4e87f9bc52e7d229
parenta5489bb83174f4469582cb2c64124b355b1bc52a (diff)
downloadsamba-725d93954896052e24a6870e9e5f14106063fe78.tar.gz
samba-725d93954896052e24a6870e9e5f14106063fe78.tar.bz2
samba-725d93954896052e24a6870e9e5f14106063fe78.zip
r2091: only use sAMAccountName and not userPrincipalName since the breaks winbindd (lookup_name() only works with the sAMAccountName) -- *please* test this change. My tests all pass but there is probably something I missed
(This used to be commit 2bf08aaa37f41681b3154514792bf29a3abfdbfd)
-rw-r--r--source3/libads/ldap.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c
index 78ea9f1497..d1539b83da 100644
--- a/source3/libads/ldap.c
+++ b/source3/libads/ldap.c
@@ -2184,13 +2184,19 @@ BOOL ads_pull_sd(ADS_STRUCT *ads, TALLOC_CTX *mem_ctx,
*/
char *ads_pull_username(ADS_STRUCT *ads, TALLOC_CTX *mem_ctx, void *msg)
{
+#if 0 /* JERRY */
char *ret, *p;
+ /* lookup_name() only works on the sAMAccountName to
+ returning the username portion of userPrincipalName
+ breaks winbindd_getpwnam() */
+
ret = ads_pull_string(ads, mem_ctx, msg, "userPrincipalName");
if (ret && (p = strchr(ret, '@'))) {
*p = 0;
return ret;
}
+#endif
return ads_pull_string(ads, mem_ctx, msg, "sAMAccountName");
}