diff options
author | Andrew Bartlett <abartlet@samba.org> | 2002-09-26 10:25:34 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2002-09-26 10:25:34 +0000 |
commit | ad514000db54b887c5c0f8734415e2b10698b365 (patch) | |
tree | 5bd885d043786d2e8bef317c10adb54c13c835cb /source3/rpc_server/srv_samr_nt.c | |
parent | 9e70b39ab29b877906ca3e20bc25700c2e05ae1b (diff) | |
download | samba-ad514000db54b887c5c0f8734415e2b10698b365.tar.gz samba-ad514000db54b887c5c0f8734415e2b10698b365.tar.bz2 samba-ad514000db54b887c5c0f8734415e2b10698b365.zip |
Patch from "Stefan (metze) Metzmacher" <metze@metzemix.de> to do a *much*
better job of working with usrmgr. Previously we were blanking out entires,
and all sort of mischif.
The new patch (which I've now had a chance to test/modify) also takes care not
to expand % values (ie we go \\%L\%U -> \\server\user, we don't want to store
\\server\user back) and to correctly notice 'not set' compared to 'null string'
etc.
Andrew Bartlett
(This used to be commit ab878b6cc4132594fc33f78aeebf0d8b7266c150)
Diffstat (limited to 'source3/rpc_server/srv_samr_nt.c')
-rw-r--r-- | source3/rpc_server/srv_samr_nt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/rpc_server/srv_samr_nt.c b/source3/rpc_server/srv_samr_nt.c index ea631838da..6e9ba2f026 100644 --- a/source3/rpc_server/srv_samr_nt.c +++ b/source3/rpc_server/srv_samr_nt.c @@ -2802,8 +2802,6 @@ static BOOL set_user_info_23(SAM_USER_INFO_23 *id23, DOM_SID *sid) acct_ctrl = pdb_get_acct_ctrl(pwd); - copy_id23_to_sam_passwd(pwd, id23); - if (!decode_pw_buffer((char*)id23->pass, plaintext_buf, 256, &len)) { pdb_free_sam(&pwd); return False; @@ -2814,6 +2812,8 @@ static BOOL set_user_info_23(SAM_USER_INFO_23 *id23, DOM_SID *sid) return False; } + copy_id23_to_sam_passwd(pwd, id23); + /* if it's a trust account, don't update /etc/passwd */ if ( (!IS_SAM_UNIX_USER(pwd)) || ( (acct_ctrl & ACB_DOMTRUST) == ACB_DOMTRUST ) || |