mirror of
https://github.com/samba-team/samba.git
synced 2024-12-24 21:34:56 +03:00
s3-wkssvcs: fix check for BUILTIN\Administrators membership in wkssvc_Netr{Join,Unjoin}Domain2.
Guenther
This commit is contained in:
parent
88af0ec6e4
commit
5b50e506d0
@ -306,7 +306,7 @@ WERROR _wkssvc_NetrJoinDomain2(pipes_struct *p,
|
||||
|
||||
if (!user_has_privileges(token, &se_machine_account) &&
|
||||
!nt_token_check_domain_rid(token, DOMAIN_GROUP_RID_ADMINS) &&
|
||||
!nt_token_check_domain_rid(token, BUILTIN_ALIAS_RID_ADMINS)) {
|
||||
!nt_token_check_sid(&global_sid_Builtin_Administrators, token)) {
|
||||
DEBUG(5,("_wkssvc_NetrJoinDomain2: account doesn't have "
|
||||
"sufficient privileges\n"));
|
||||
return WERR_ACCESS_DENIED;
|
||||
@ -377,7 +377,7 @@ WERROR _wkssvc_NetrUnjoinDomain2(pipes_struct *p,
|
||||
|
||||
if (!user_has_privileges(token, &se_machine_account) &&
|
||||
!nt_token_check_domain_rid(token, DOMAIN_GROUP_RID_ADMINS) &&
|
||||
!nt_token_check_domain_rid(token, BUILTIN_ALIAS_RID_ADMINS)) {
|
||||
!nt_token_check_sid(&global_sid_Builtin_Administrators, token)) {
|
||||
DEBUG(5,("_wkssvc_NetrUnjoinDomain2: account doesn't have "
|
||||
"sufficient privileges\n"));
|
||||
return WERR_ACCESS_DENIED;
|
||||
|
Loading…
Reference in New Issue
Block a user