From 51bf383c26cb3f867f376305c803dac04ff686a7 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Fri, 15 Jan 2010 19:13:26 +1100 Subject: s4-dsdb: added isGlobalCatalogReady needed for dcdiag.exe --- source4/dsdb/samdb/ldb_modules/rootdse.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'source4/dsdb/samdb/ldb_modules') diff --git a/source4/dsdb/samdb/ldb_modules/rootdse.c b/source4/dsdb/samdb/ldb_modules/rootdse.c index 045b507ffd..4ce379b1bf 100644 --- a/source4/dsdb/samdb/ldb_modules/rootdse.c +++ b/source4/dsdb/samdb/ldb_modules/rootdse.c @@ -364,6 +364,18 @@ static int rootdse_add_dynamic(struct ldb_module *module, struct ldb_message *ms } } + if (do_attribute_explicit(attrs, "isGlobalCatalogReady")) { + /* MS-ADTS 3.1.1.3.2.10 + Note, we should only return true here is we have + completed at least one synchronisation. As both + provision and vampire do a full sync, this means we + can return true is the gc bit is set in the NTDSDSA + options */ + if (ldb_msg_add_fmt(msg, "isGlobalCatalogReady", + "%s", samdb_is_gc(ldb)?"TRUE":"FALSE") != 0) { + goto failed; + } + } /* TODO: lots more dynamic attributes should be added here */ -- cgit