From 235bece8ff56b5174ee898b1bf4ad2bf4bd87ef5 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Mon, 18 Jul 2005 13:16:52 +0000 Subject: r8542: - (re-)add better search-semantics: look for Interdomain trust accounts below the machine-suffix (this is where we create them)) to avoid digging through thousands of user-accounts just to find a handful of trust-accounts in the enumdomusers-samr-call. - don't access freed data in DEBUG-statement Guenther (This used to be commit 793c82c0172c4f834e43d04bf3f9d39858761e88) --- source3/passdb/pdb_ldap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c index 002ec70464..3953128c74 100644 --- a/source3/passdb/pdb_ldap.c +++ b/source3/passdb/pdb_ldap.c @@ -3609,7 +3609,7 @@ static BOOL ldapuser2displayentry(struct ldap_search_state *state, ldap_value_free(vals); if (!sid_peek_check_rid(get_global_sam_sid(), &sid, &result->rid)) { - DEBUG(0, ("%s is not our domain\n", vals[0])); + DEBUG(0, ("sid %s does not belong to our domain\n", sid_string_static(&sid))); return False; } @@ -3635,7 +3635,7 @@ static BOOL ldapsam_search_users(struct pdb_methods *methods, if ((acct_flags != 0) && ((acct_flags & ACB_NORMAL) != 0)) state->base = lp_ldap_user_suffix(); else if ((acct_flags != 0) && - ((acct_flags & (ACB_WSTRUST|ACB_SVRTRUST)) != 0)) + ((acct_flags & (ACB_WSTRUST|ACB_SVRTRUST|ACB_DOMTRUST)) != 0)) state->base = lp_ldap_machine_suffix(); else state->base = lp_ldap_suffix(); -- cgit