From 320d765081da804e3cb99dade1ea6d18b463fa43 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Wed, 19 Jan 2005 17:42:33 +0000 Subject: r4851: Preleminary fix for ldapsam_enum_group_memberships when ldapsam:trusted=True. Don't bail out when ldap-search returns pure posixgroups (w.o. samba group-mapping). This way those unix-memberships do not appear in user and nt user token. Volker, could you please look over that one? Guenther (This used to be commit 853a8b7f1c0b00b2e4433d1281f3c9bfcaf980a6) --- source3/passdb/pdb_ldap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source3/passdb/pdb_ldap.c') diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c index 2cc1798d3f..0c6e59b2fc 100644 --- a/source3/passdb/pdb_ldap.c +++ b/source3/passdb/pdb_ldap.c @@ -2225,7 +2225,7 @@ static NTSTATUS ldapsam_enum_group_memberships(struct pdb_methods *methods, if (!smbldap_get_single_attribute(conn->ldap_struct, entry, "sambaSID", str, sizeof(str)-1)) - goto done; + continue; if (!string_to_sid(&sid, str)) goto done; @@ -2233,7 +2233,7 @@ static NTSTATUS ldapsam_enum_group_memberships(struct pdb_methods *methods, if (!smbldap_get_single_attribute(conn->ldap_struct, entry, "gidNumber", str, sizeof(str)-1)) - goto done; + continue; gid = strtoul(str, &end, 10); @@ -2249,7 +2249,7 @@ static NTSTATUS ldapsam_enum_group_memberships(struct pdb_methods *methods, } if (sid_compare(&global_sid_NULL, &(*sids)[0]) == 0) { - DEBUG(3, ("primary group not found\n")); + DEBUG(3, ("primary group of [%s] not found\n", username)); goto done; } -- cgit