From 958f1e54f71191d94498da45fc505d96b1528c78 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Fri, 28 Nov 2003 15:10:30 +0000 Subject: Implement 'net rpc group list [global|local|builtin]*' for a select listing of the respective user databases. Volker (This used to be commit 53b592f4a64742767f37f9c7f8ee0fdf42e686c6) --- source3/utils/net_help.c | 2 ++ source3/utils/net_rpc.c | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) (limited to 'source3/utils') diff --git a/source3/utils/net_help.c b/source3/utils/net_help.c index 059da4740b..514cf1af1b 100644 --- a/source3/utils/net_help.c +++ b/source3/utils/net_help.c @@ -88,6 +88,8 @@ int net_help_group(int argc, const char **argv) { d_printf("net [] group [misc. options] [targets]"\ "\n\tList user groups\n\n"); + d_printf("net rpc group LIST [global|local|builtin]* [misc. options]"\ + "\n\tList specific user groups\n\n"); d_printf("net [] group DELETE "\ "[misc. options] [targets]"\ "\n\tDelete specified group\n"); diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c index 2453355ee3..75b3726b44 100644 --- a/source3/utils/net_rpc.c +++ b/source3/utils/net_rpc.c @@ -916,6 +916,26 @@ rpc_group_list_internals(const DOM_SID *domain_sid, struct cli_state *cli, uint32 start_idx=0, max_entries=250, num_entries, i, loop_count = 0; struct acct_info *groups; DOM_SID global_sid_Builtin; + BOOL global = False; + BOOL local = False; + BOOL builtin = False; + + if (argc == 0) { + global = True; + local = True; + builtin = True; + } + + for (i=0; i