From 9eb6afb00d85c1a7b367d51a19eed41172f7a2e9 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Fri, 4 Jun 2004 11:58:46 +0000 Subject: r1009: Make all users of NT and LM passwords use the samr_Password structure. This includes the netlogon pipe, for the machine account password change system. Andrew Bartlett (This used to be commit 49d545a82057ee8b60d50aa55e908efe59875150) --- source4/rpc_server/netlogon/dcerpc_netlogon.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'source4/rpc_server/netlogon/dcerpc_netlogon.c') diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c index 5f4717a5c6..f662e45246 100644 --- a/source4/rpc_server/netlogon/dcerpc_netlogon.c +++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c @@ -332,7 +332,6 @@ static NTSTATUS netr_ServerPasswordSet(struct dcesrv_call_state *dce_call, TALLO struct ldb_message **msgs; struct ldb_message **msgs_domain; NTSTATUS nt_status; - struct samr_Hash newNtHash; struct ldb_message mod, *msg_set_pw = &mod; const char *domain_dn; const char *domain_sid; @@ -410,15 +409,13 @@ static NTSTATUS netr_ServerPasswordSet(struct dcesrv_call_state *dce_call, TALLO creds_des_decrypt(pipe_state->creds, &r->in.new_password); - memcpy(newNtHash.hash, r->in.new_password.data, sizeof(newNtHash.hash)); - /* set the password - samdb needs to know both the domain and user DNs, so the domain password policy can be used */ nt_status = samdb_set_password(sam_ctx, mem_ctx, msgs[0]->dn, domain_dn, msg_set_pw, NULL, /* Don't have plaintext */ - NULL, &newNtHash, + NULL, &r->in.new_password, False /* This is not considered a password change */, NULL); -- cgit