From fca7dce1a908570e463ddcbd663955fcafd1d843 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Mon, 25 May 2009 14:05:18 +0200 Subject: 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 --- source3/rpc_server/srv_samr_nt.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'source3/rpc_server') diff --git a/source3/rpc_server/srv_samr_nt.c b/source3/rpc_server/srv_samr_nt.c index d528c802e5..26bc44c6ff 100644 --- a/source3/rpc_server/srv_samr_nt.c +++ b/source3/rpc_server/srv_samr_nt.c @@ -1109,6 +1109,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; @@ -1174,6 +1180,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; -- cgit