summaryrefslogtreecommitdiff
path: root/source3/rpc_client
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-02-12 20:01:36 +0100
committerGünther Deschner <gd@samba.org>2008-02-12 20:29:13 +0100
commit68855a99d0206889e5af018d956a2ea5cd33d264 (patch)
tree15ea8733106824636d5f91d70c337af5a209f7e9 /source3/rpc_client
parentb69a590f6bec4219879beb87dc375417153983a2 (diff)
downloadsamba-68855a99d0206889e5af018d956a2ea5cd33d264.tar.gz
samba-68855a99d0206889e5af018d956a2ea5cd33d264.tar.bz2
samba-68855a99d0206889e5af018d956a2ea5cd33d264.zip
Use rpccli_samr_SetUserInfo2() in place of rpccli_samr_set_userinfo().
Guenther (This used to be commit 1b48b9d73d971ef18b8a2ea240e48902b703b74b)
Diffstat (limited to 'source3/rpc_client')
-rw-r--r--source3/rpc_client/init_samr.c83
1 files changed, 83 insertions, 0 deletions
diff --git a/source3/rpc_client/init_samr.c b/source3/rpc_client/init_samr.c
index a61ddb5db1..0e22e77b65 100644
--- a/source3/rpc_client/init_samr.c
+++ b/source3/rpc_client/init_samr.c
@@ -385,3 +385,86 @@ void init_samr_user_info21(struct samr_UserInfo21 *r,
r->lm_password_set = lm_password_set;
r->password_expired = password_expired;
}
+
+/*************************************************************************
+ init_samr_user_info23
+ *************************************************************************/
+
+void init_samr_user_info23(struct samr_UserInfo23 *r,
+ NTTIME last_logon,
+ NTTIME last_logoff,
+ NTTIME last_password_change,
+ NTTIME acct_expiry,
+ NTTIME allow_password_change,
+ NTTIME force_password_change,
+ const char *account_name,
+ const char *full_name,
+ const char *home_directory,
+ const char *home_drive,
+ const char *logon_script,
+ const char *profile_path,
+ const char *description,
+ const char *workstations,
+ const char *comment,
+ const char *parameters,
+ uint32_t rid,
+ uint32_t primary_gid,
+ uint32_t acct_flags,
+ uint32_t fields_present,
+ struct samr_LogonHours logon_hours,
+ uint16_t bad_password_count,
+ uint16_t logon_count,
+ uint16_t country_code,
+ uint16_t code_page,
+ uint8_t nt_password_set,
+ uint8_t lm_password_set,
+ uint8_t password_expired,
+ uint8_t data[516],
+ uint8_t pw_len)
+{
+ init_samr_user_info21(&r->info,
+ last_logon,
+ last_logoff,
+ last_password_change,
+ acct_expiry,
+ allow_password_change,
+ force_password_change,
+ account_name,
+ full_name,
+ home_directory,
+ home_drive,
+ logon_script,
+ profile_path,
+ description,
+ workstations,
+ comment,
+ parameters,
+ rid,
+ primary_gid,
+ acct_flags,
+ fields_present,
+ logon_hours,
+ bad_password_count,
+ logon_count,
+ country_code,
+ code_page,
+ nt_password_set,
+ lm_password_set,
+ password_expired);
+
+ memcpy(r->password.data, data, sizeof(r->password.data));
+}
+
+/*************************************************************************
+ init_samr_user_info24
+ *************************************************************************/
+
+void init_samr_user_info24(struct samr_UserInfo24 *r,
+ uint8_t data[516],
+ uint8_t pw_len)
+{
+ DEBUG(10, ("init_samr_user_info24:\n"));
+
+ memcpy(r->password.data, data, sizeof(r->password.data));
+ r->pw_len = pw_len;
+}