From 4a212ba3913fa6f1b84fee471e3bdc319c124b7c Mon Sep 17 00:00:00 2001 From: =?utf-8?q?G=C3=BCnther=20Deschner?= Date: Mon, 25 May 2009 14:05:18 +0200 Subject: [PATCH] s3-samr: Fix Bug #6372, usermanager only displaying 1024 groups and aliases. This is now also verified with the RPC-SAMR-LARGE-DC test. Guenther (cherry picked from commit fca7dce1a908570e463ddcbd663955fcafd1d843) --- source/rpc_server/srv_samr_nt.c | 12 ++++++++++++ 1 files changed, 12 insertions(+), 0 deletions(-) diff --git a/source/rpc_server/srv_samr_nt.c b/source/rpc_server/srv_samr_nt.c index f14c53b..a394eb3 100644 --- a/source/rpc_server/srv_samr_nt.c +++ b/source/rpc_server/srv_samr_nt.c @@ -1165,6 +1165,12 @@ NTSTATUS _samr_EnumDomainGroups(pipes_struct *p, make_group_sam_entry_list(p->mem_ctx, &samr_entries, num_groups, groups); + if (MAX_SAM_ENTRIES <= num_groups) { + status = STATUS_MORE_ENTRIES; + } else { + status = NT_STATUS_OK; + } + samr_array->count = num_groups; samr_array->entries = samr_entries; @@ -1233,6 +1239,12 @@ NTSTATUS _samr_EnumDomainAliases(pipes_struct *p, DEBUG(5,("_samr_EnumDomainAliases: %d\n", __LINE__)); + if (MAX_SAM_ENTRIES <= num_aliases) { + status = STATUS_MORE_ENTRIES; + } else { + status = NT_STATUS_OK; + } + samr_array->count = num_aliases; samr_array->entries = samr_entries; -- 1.6.0.6