mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
s3-netlogon: Only hand out rid when netlogon credential chain has been setup sucessfully.
Guenther
This commit is contained in:
parent
87d30a1968
commit
4799020e9f
@ -513,6 +513,7 @@ NTSTATUS _netr_ServerAuthenticate3(pipes_struct *p,
|
||||
uint32_t in_neg_flags = *r->in.negotiate_flags;
|
||||
struct netr_Credential srv_chal_out;
|
||||
const char *fn;
|
||||
uint32_t rid;
|
||||
|
||||
/* According to Microsoft (see bugid #6099)
|
||||
* Windows 7 looks at the negotiate_flags
|
||||
@ -578,7 +579,7 @@ NTSTATUS _netr_ServerAuthenticate3(pipes_struct *p,
|
||||
status = get_md4pw((char *)p->dc->mach_pw,
|
||||
r->in.account_name,
|
||||
r->in.secure_channel_type,
|
||||
r->out.rid);
|
||||
&rid);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
DEBUG(0,("%s: failed to get machine password for "
|
||||
"account %s: %s\n",
|
||||
@ -621,6 +622,9 @@ NTSTATUS _netr_ServerAuthenticate3(pipes_struct *p,
|
||||
r->in.computer_name,
|
||||
p->dc);
|
||||
unbecome_root();
|
||||
|
||||
*r->out.rid = rid;
|
||||
|
||||
status = NT_STATUS_OK;
|
||||
|
||||
out:
|
||||
|
Loading…
Reference in New Issue
Block a user