summaryrefslogtreecommitdiff
path: root/source4/dsdb
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-01-16 13:40:51 +1100
committerAndrew Tridgell <tridge@samba.org>2010-01-16 14:10:45 +1100
commitee736083c07e953a5fee944d3e048e2a38f98b30 (patch)
tree8b0415553982ef7e99b510d534d374febfd379e8 /source4/dsdb
parent84b47d33349ff12fa5951f3348db20a05879f614 (diff)
downloadsamba-ee736083c07e953a5fee944d3e048e2a38f98b30.tar.gz
samba-ee736083c07e953a5fee944d3e048e2a38f98b30.tar.bz2
samba-ee736083c07e953a5fee944d3e048e2a38f98b30.zip
s4-kcc: added DsReplicaGetInfo pending ops call
Just return 0 pending ops for now
Diffstat (limited to 'source4/dsdb')
-rw-r--r--source4/dsdb/kcc/kcc_drs_replica_info.c31
1 files changed, 30 insertions, 1 deletions
diff --git a/source4/dsdb/kcc/kcc_drs_replica_info.c b/source4/dsdb/kcc/kcc_drs_replica_info.c
index 599cf52f9c..8c1829343e 100644
--- a/source4/dsdb/kcc/kcc_drs_replica_info.c
+++ b/source4/dsdb/kcc/kcc_drs_replica_info.c
@@ -87,6 +87,31 @@ static WERROR kccdrs_replica_get_info_cursors2(TALLOC_CTX *mem_ctx,
return WERR_OK;
}
+/*
+ get pending ops info for a specified DN
+*/
+static WERROR kccdrs_replica_get_info_pending_ops(TALLOC_CTX *mem_ctx,
+ struct ldb_context *samdb,
+ struct drsuapi_DsReplicaGetInfo *r,
+ union drsuapi_DsReplicaInfo *reply,
+ struct ldb_dn *dn)
+{
+ struct timeval now = timeval_current();
+
+ if (!ldb_dn_validate(dn)) {
+ return WERR_INVALID_PARAMETER;
+ }
+ reply->pendingops = talloc(mem_ctx, struct drsuapi_DsReplicaOpCtr);
+ W_ERROR_HAVE_NO_MEMORY(reply->pendingops);
+
+ /* claim no pending ops for now */
+ reply->pendingops->time = timeval_to_nttime(&now);
+ reply->pendingops->count = 0;
+ reply->pendingops->array = NULL;
+
+ return WERR_OK;
+}
+
struct ncList {
struct ldb_dn *dn;
@@ -493,6 +518,11 @@ NTSTATUS kccdrs_replica_get_info(struct irpc_message *msg,
status = kccdrs_replica_get_info_cursors2(mem_ctx, samdb, req, reply,
ldb_dn_new(mem_ctx, samdb, object_dn));
break;
+ case DRSUAPI_DS_REPLICA_INFO_PENDING_OPS: /* On MS-DRSR it is DS_REPL_INFO_PENDING_OPS */
+ status = kccdrs_replica_get_info_pending_ops(mem_ctx, samdb, req, reply,
+ ldb_dn_new(mem_ctx, samdb, object_dn));
+ break;
+
case DRSUAPI_DS_REPLICA_INFO_CURSORS3: /* On MS-DRSR it is DS_REPL_INFO_CURSORS_3_FOR_NC */
case DRSUAPI_DS_REPLICA_INFO_CURSORS05: /* On MS-DRSR it is DS_REPL_INFO_UPTODATE_VECTOR_V1 */
case DRSUAPI_DS_REPLICA_INFO_NEIGHBORS02: /* DS_REPL_INFO_REPSTO */
@@ -502,7 +532,6 @@ NTSTATUS kccdrs_replica_get_info(struct irpc_message *msg,
case DRSUAPI_DS_REPLICA_INFO_ATTRIBUTE_VALUE_METADATA2: /* On MS-DRSR it is DS_REPL_INFO_METADATA_2_FOR_ATTR_VALUE */
case DRSUAPI_DS_REPLICA_INFO_KCC_DSA_CONNECT_FAILURES: /* On MS-DRSR it is DS_REPL_INFO_KCC_DSA_CONNECT_FAILURES */
case DRSUAPI_DS_REPLICA_INFO_KCC_DSA_LINK_FAILURES: /* On MS-DRSR it is DS_REPL_INFO_KCC_LINK_FAILURES */
- case DRSUAPI_DS_REPLICA_INFO_PENDING_OPS: /* On MS-DRSR it is DS_REPL_INFO_PENDING_OPS */
case DRSUAPI_DS_REPLICA_INFO_CONNECTIONS04: /* On MS-DRSR it is DS_REPL_INFO_CLIENT_CONTEXTS */
case DRSUAPI_DS_REPLICA_INFO_06: /* On MS-DRSR it is DS_REPL_INFO_SERVER_OUTGOING_CALLS */
default: