summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-03-25 15:14:30 +0000
committerLuke Leighton <lkcl@samba.org>1999-03-25 15:14:30 +0000
commitfa01e8764c9da8d0e37f07dbe1a3b116a0640acc (patch)
tree763c4c098e70e9b2ea1214bf7987d28885a16ee0 /source3/rpc_server
parent43a460075a39148060d4193fcb9c62bfa4acc737 (diff)
downloadsamba-fa01e8764c9da8d0e37f07dbe1a3b116a0640acc.tar.gz
samba-fa01e8764c9da8d0e37f07dbe1a3b116a0640acc.tar.bz2
samba-fa01e8764c9da8d0e37f07dbe1a3b116a0640acc.zip
added SAMR_USER_INFO_24 info level to samr_set_userinfo. this is used
by "Welcome to SAMBA Domain". (This used to be commit 4aed18b5e1e2309c0f6931fbfdd604b01cb9498a)
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_samr.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/source3/rpc_server/srv_samr.c b/source3/rpc_server/srv_samr.c
index 2437163f2b..b0fc64a2e7 100644
--- a/source3/rpc_server/srv_samr.c
+++ b/source3/rpc_server/srv_samr.c
@@ -1944,6 +1944,27 @@ static void samr_reply_query_userinfo(SAMR_Q_QUERY_USERINFO *q_u,
}
/*******************************************************************
+ set_user_info_24
+ ********************************************************************/
+static BOOL set_user_info_24(SAM_USER_INFO_24 *id24, uint32 rid)
+{
+ static struct sam_passwd *pwd;
+ fstring new_pw;
+ if (!decode_pw_buffer(id24->pass, new_pw, sizeof(new_pw), True))
+ {
+ return False;
+ }
+#ifdef DEBUG_PASSWORD
+ DEBUG(0,("New Password: %s\n", new_pw));
+#endif
+#if 0
+ return mod_sam21pwd_entry(&pwd, True);
+#else
+ return True;
+#endif
+}
+
+/*******************************************************************
set_user_info_23
********************************************************************/
static BOOL set_user_info_23(SAM_USER_INFO_23 *id23, uint32 rid)
@@ -2007,6 +2028,15 @@ static void samr_reply_set_userinfo(SAMR_Q_SET_USERINFO *q_u,
{
switch (q_u->switch_value)
{
+ case 24:
+ {
+ SAM_USER_INFO_24 *id24 = q_u->info.id24;
+ nt_lm_owf_gen("test", nt_pwd, lm_pwd);
+ SamOEMhash(id24->pass, user_sess_key, True);
+ status = set_user_info_24(id24, rid) ? 0 : (0xC0000000 | NT_STATUS_ACCESS_DENIED);
+ break;
+ }
+
case 23:
{
SAM_USER_INFO_23 *id23 = q_u->info.id23;