From: Gerald Carter Date: Fri, 27 Aug 2004 16:15:23 +0000 (+0000) Subject: r2091: only use sAMAccountName and not userPrincipalName since the breaks winbindd... X-Git-Tag: samba-misc-tags/initial-v3-0-unstable~5858 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2bf08aaa37f41681b3154514792bf29a3abfdbfd;p=thirdparty%2Fsamba.git 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 --- diff --git a/source/libads/ldap.c b/source/libads/ldap.c index 78ea9f1497d..d1539b83da7 100644 --- a/source/libads/ldap.c +++ b/source/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"); }