summaryrefslogtreecommitdiff
path: root/source4/dsdb/samdb
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2006-01-18 11:22:30 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:51:15 -0500
commit1cb9484a42af5467cf96818a8459ca3fb3f81066 (patch)
treecf4f734bc493137e05d6b7f19f4b43624d1a33e7 /source4/dsdb/samdb
parent2a187c94f05ab6e1c1dd8db4d04b422d8bb132b4 (diff)
downloadsamba-1cb9484a42af5467cf96818a8459ca3fb3f81066.tar.gz
samba-1cb9484a42af5467cf96818a8459ca3fb3f81066.tar.bz2
samba-1cb9484a42af5467cf96818a8459ca3fb3f81066.zip
r12996: Restrict this search to domain objects.
Andrew Bartlett (This used to be commit 4d69eae382a789910d24ecadfb08b8d95a3c04b0)
Diffstat (limited to 'source4/dsdb/samdb')
-rw-r--r--source4/dsdb/samdb/cracknames.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/dsdb/samdb/cracknames.c b/source4/dsdb/samdb/cracknames.c
index 9dd44e680b..d86484eb8a 100644
--- a/source4/dsdb/samdb/cracknames.c
+++ b/source4/dsdb/samdb/cracknames.c
@@ -716,7 +716,7 @@ static WERROR DsCrackNameOneFilter(struct ldb_context *sam_ctx, TALLOC_CTX *mem_
}
dom_sid->num_auths--;
ldb_ret = gendb_search(sam_ctx, mem_ctx, NULL, &domain_res, attrs,
- "(objectSid=%s)", ldap_encode_ndr_dom_sid(mem_ctx, dom_sid));
+ "(&(objectSid=%s)(objectClass=domain))", ldap_encode_ndr_dom_sid(mem_ctx, dom_sid));
if (ldb_ret != 1) {
info1->status = DRSUAPI_DS_NAME_STATUS_NOT_FOUND;
return WERR_OK;