summaryrefslogtreecommitdiff
path: root/source4/dsdb
diff options
context:
space:
mode:
authorMatthieu Patou <matthieu.patou@matws.net>2011-07-31 00:54:01 +0400
committerMatthieu Patou <mat@matws.net>2011-08-10 01:44:43 +0400
commit87e7802722e62b5df1d8f63d49f4a54eaf3f61cd (patch)
treee4d8b1720250b88227cd77b4cb9befeb8dc6a31c /source4/dsdb
parent1b97b2f8ffce2bd7c93155bab337dd90665f7013 (diff)
downloadsamba-87e7802722e62b5df1d8f63d49f4a54eaf3f61cd.tar.gz
samba-87e7802722e62b5df1d8f63d49f4a54eaf3f61cd.tar.bz2
samba-87e7802722e62b5df1d8f63d49f4a54eaf3f61cd.zip
s4-drsuapi: crackname search also for deleted objects
Diffstat (limited to 'source4/dsdb')
-rw-r--r--source4/dsdb/samdb/cracknames.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/dsdb/samdb/cracknames.c b/source4/dsdb/samdb/cracknames.c
index d9224828ca..21a473da5c 100644
--- a/source4/dsdb/samdb/cracknames.c
+++ b/source4/dsdb/samdb/cracknames.c
@@ -839,13 +839,16 @@ static WERROR DsCrackNameOneFilter(struct ldb_context *sam_ctx, TALLOC_CTX *mem_
dsdb_flags = DSDB_SEARCH_SEARCH_ALL_PARTITIONS;
search_dn = ldb_get_root_basedn(sam_ctx);
}
+ if (format_desired == DRSUAPI_DS_NAME_FORMAT_GUID){
+ dsdb_flags = dsdb_flags| DSDB_SEARCH_SHOW_DELETED;
+ }
/* search with the 'phantom root' flag */
ret = dsdb_search(sam_ctx, mem_ctx, &res,
search_dn,
LDB_SCOPE_SUBTREE,
result_attrs,
- DSDB_SEARCH_SEARCH_ALL_PARTITIONS,
+ dsdb_flags,
"%s", result_filter);
if (ret != LDB_SUCCESS) {
DEBUG(2, ("DsCrackNameOneFilter phantom root search failed: %s",