diff options
author | Günther Deschner <gd@samba.org> | 2008-02-12 11:09:23 +0100 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2008-02-12 11:10:59 +0100 |
commit | cf20a28dd6c443cac03c5ab0f640e6dc7aa10971 (patch) | |
tree | 2b2174415fb339ed4f0847fabc7c543a475686d1 /source3/rpcclient | |
parent | 885b16cd77affa151578cde4923a2581d96fab93 (diff) | |
download | samba-cf20a28dd6c443cac03c5ab0f640e6dc7aa10971.tar.gz samba-cf20a28dd6c443cac03c5ab0f640e6dc7aa10971.tar.xz samba-cf20a28dd6c443cac03c5ab0f640e6dc7aa10971.zip |
Use rpccli_samr_EnumDomainAliases() in net and rpcclient.
Guenther
(This used to be commit d034d34faaced1d349ff9d36fcddf9533e402582)
Diffstat (limited to 'source3/rpcclient')
-rw-r--r-- | source3/rpcclient/cmd_samr.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/source3/rpcclient/cmd_samr.c b/source3/rpcclient/cmd_samr.c index 4f0e45ec749..5ee28c63361 100644 --- a/source3/rpcclient/cmd_samr.c +++ b/source3/rpcclient/cmd_samr.c @@ -973,7 +973,7 @@ static NTSTATUS cmd_samr_enum_als_groups(struct rpc_pipe_client *cli, NTSTATUS result = NT_STATUS_UNSUCCESSFUL; uint32 start_idx, size, num_als_groups, i; uint32 access_mask = MAXIMUM_ALLOWED_ACCESS; - struct acct_info *als_groups; + struct samr_SamArray *als_groups = NULL; bool got_connect_pol = False, got_domain_pol = False; if ((argc < 2) || (argc > 3)) { @@ -1022,17 +1022,20 @@ static NTSTATUS cmd_samr_enum_als_groups(struct rpc_pipe_client *cli, size = 0xffff; /* Number of groups to retrieve */ do { - result = rpccli_samr_enum_als_groups( - cli, mem_ctx, &domain_pol, &start_idx, size, - &als_groups, &num_als_groups); + result = rpccli_samr_EnumDomainAliases(cli, mem_ctx, + &domain_pol, + &start_idx, + &als_groups, + size, + &num_als_groups); if (NT_STATUS_IS_OK(result) || NT_STATUS_V(result) == NT_STATUS_V(STATUS_MORE_ENTRIES)) { for (i = 0; i < num_als_groups; i++) printf("group:[%s] rid:[0x%x]\n", - als_groups[i].acct_name, - als_groups[i].rid); + als_groups->entries[i].name.string, + als_groups->entries[i].idx); } } while (NT_STATUS_V(result) == NT_STATUS_V(STATUS_MORE_ENTRIES)); |