summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2005-01-20 16:55:55 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:55:05 -0500
commit027d976bb32f29dbb7d24272c70d4244d54f68c2 (patch)
treeacfb7cc83ea6d73fb05b51ef5f5f6e85b58ada7c /source3
parent725edd20f1589be310a8d1bab7a0aa907a55416e (diff)
downloadsamba-027d976bb32f29dbb7d24272c70d4244d54f68c2.tar.gz
samba-027d976bb32f29dbb7d24272c70d4244d54f68c2.tar.bz2
samba-027d976bb32f29dbb7d24272c70d4244d54f68c2.zip
r4869: Display sam_user_info_7 in rpcclient.
Guenther (This used to be commit 30e808ca07bec66d5ecd81cc8c86bb4a98874bc4)
Diffstat (limited to 'source3')
-rw-r--r--source3/rpcclient/cmd_samr.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/source3/rpcclient/cmd_samr.c b/source3/rpcclient/cmd_samr.c
index 224d40ea74..a69a0cb73a 100644
--- a/source3/rpcclient/cmd_samr.c
+++ b/source3/rpcclient/cmd_samr.c
@@ -28,6 +28,17 @@
extern DOM_SID domain_sid;
/****************************************************************************
+ display sam_user_info_7 structure
+ ****************************************************************************/
+static void display_sam_user_info_7(SAM_USER_INFO_7 *usr)
+{
+ fstring temp;
+
+ unistr2_to_ascii(temp, &usr->uni_name, sizeof(temp)-1);
+ printf("\tUser Name :\t%s\n", temp);
+}
+
+/****************************************************************************
display sam_user_info_21 structure
****************************************************************************/
static void display_sam_user_info_21(SAM_USER_INFO_21 *usr)
@@ -336,7 +347,17 @@ static NTSTATUS cmd_samr_query_user(struct cli_state *cli,
if (!NT_STATUS_IS_OK(result))
goto done;
- display_sam_user_info_21(user_ctr->info.id21);
+ switch (user_ctr->switch_value) {
+ case 21:
+ display_sam_user_info_21(user_ctr->info.id21);
+ break;
+ case 7:
+ display_sam_user_info_7(user_ctr->info.id7);
+ break;
+ default:
+ printf("Unsupported infolevel: %d\n", info_level);
+ break;
+ }
done:
return result;