From fdffa90ef99e10b963ecec73a65e18ecb6cec932 Mon Sep 17 00:00:00 2001 From: Kamen Mazdrashki Date: Fri, 3 Sep 2010 06:20:49 +0300 Subject: s4-drs: A quick fix for DRSUAPI_EXOP_FSMO_RID_ALLOC extended_op handling When DRSUAPI_EXOP_FSMO_RID_ALLOC extended op is handled in DsGetNCChanges() stub, we need to returned a well know set of object - see: [ms-adts], 3.1.1.5.1.7 With this hack we are going to return just objects modified during RID allocation procedure - i.e. "RID Manager$", "RID Set" for computer object and computer object itself. Which is a close approximation of what we are expected to return. --- source4/rpc_server/drsuapi/getncchanges.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/source4/rpc_server/drsuapi/getncchanges.c b/source4/rpc_server/drsuapi/getncchanges.c index 262559592d..2659cf3181 100644 --- a/source4/rpc_server/drsuapi/getncchanges.c +++ b/source4/rpc_server/drsuapi/getncchanges.c @@ -652,6 +652,15 @@ static WERROR getncchanges_rid_alloc(struct drsuapi_bind_state *b_state, return WERR_DS_DRA_INTERNAL_ERROR; } + /* + * FIXME (kim): this is a temp hack to return just few object, + * but not the whole domain NC. + * We should remove this hack and implement a 'scope' + * building function to return just the set of object + * documented for DRSUAPI_EXOP_FSMO_RID_ALLOC extended_op + */ + ldb_sequence_number(ldb, LDB_SEQ_HIGHEST_SEQ, &req8->highwatermark.highest_usn); + ret = ldb_extended(ldb, DSDB_EXTENDED_ALLOCATE_RID_POOL, exop, &ext_res); if (ret != LDB_SUCCESS) { DEBUG(0,(__location__ ": Failed extended allocation RID pool operation - %s\n", -- cgit