summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2001-05-14 03:51:39 +0000
committerTim Potter <tpot@samba.org>2001-05-14 03:51:39 +0000
commitc24bf6d8ab293ec449659ea6b128a246f0dcb281 (patch)
tree8f2c62d01419104042e827954e199ae62b19accc
parent495aa4c28a76bcdecd02e3d9527b29f62b3ec33f (diff)
downloadsamba-c24bf6d8ab293ec449659ea6b128a246f0dcb281.tar.gz
samba-c24bf6d8ab293ec449659ea6b128a246f0dcb281.tar.bz2
samba-c24bf6d8ab293ec449659ea6b128a246f0dcb281.zip
Added arg to querygroupinfo.
(This used to be commit ab58fdf77a12d101f5ac6b6702cd8ed9dc2c7d55)
-rw-r--r--source3/rpcclient/cmd_samr.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/source3/rpcclient/cmd_samr.c b/source3/rpcclient/cmd_samr.c
index d399f911a9..8ab1bf9462 100644
--- a/source3/rpcclient/cmd_samr.c
+++ b/source3/rpcclient/cmd_samr.c
@@ -282,14 +282,16 @@ static uint32 cmd_samr_query_group(struct cli_state *cli, int argc, char **argv)
GROUP_INFO_CTR group_ctr;
fstring server;
TALLOC_CTX *mem_ctx;
+ uint32 group_rid;
- if (argc != 1) {
- printf("Usage: %s\n", argv[0]);
+ if (argc != 2) {
+ printf("Usage: %s rid\n", argv[0]);
return 0;
}
- if (!(mem_ctx=talloc_init()))
- {
+ group_rid = atoi(argv[1]);
+
+ if (!(mem_ctx=talloc_init())) {
DEBUG(0,("cmd_samr_query_group: talloc_init returned NULL!\n"));
return NT_STATUS_UNSUCCESSFUL;
}
@@ -324,7 +326,7 @@ static uint32 cmd_samr_query_group(struct cli_state *cli, int argc, char **argv)
if ((result = cli_samr_open_group(cli, mem_ctx, &domain_pol,
MAXIMUM_ALLOWED_ACCESS,
- 0x202, &group_pol))
+ group_rid, &group_pol))
!= NT_STATUS_NOPROBLEMO) {
goto done;
}
@@ -333,8 +335,8 @@ static uint32 cmd_samr_query_group(struct cli_state *cli, int argc, char **argv)
ZERO_STRUCT(group_ctr);
- if ((result = cli_samr_query_groupinfo(cli, mem_ctx, &group_pol, info_level,
- &group_ctr))
+ if ((result = cli_samr_query_groupinfo(cli, mem_ctx, &group_pol,
+ info_level, &group_ctr))
!= NT_STATUS_NOPROBLEMO) {
goto done;
}
@@ -902,4 +904,3 @@ struct cmd_set samr_commands[] = {
{ NULL, NULL, NULL }
};
-