don't count DomainAdmins as shared admins

This commit is contained in:
Oran Nadler 2018-04-30 17:58:15 +03:00
parent 0025d242d7
commit 8ab880340f
1 changed files with 2 additions and 1 deletions

View File

@ -465,7 +465,7 @@ class Machine(object):
domain_admins = set()
for dc in DCs:
domain_admins |= dc.GetLocalAdminSids()
domain_admins |= dc.GetUsersByGroupSid(self.GetGroupSidByGroupName("Domain Admins"))
return domain_admins
@ -851,6 +851,7 @@ class PassTheHashMap(object):
shared_admins |= (m.GetLocalAdminSids() & other.GetLocalAdminSids())
shared_admins -= m.GetDomainAdminsOfMachine()
return shared_admins
def main():