adaudit icon indicating copy to clipboard operation
adaudit copied to clipboard

Administrators Group

Open ltwarner opened this issue 3 years ago • 0 comments

Useful to list the "Administrators" group for the domain as well These lines have been added throughout the script, although not fully tested yet

$script:Administrators                 = New-Object System.Security.Principal.SecurityIdentifier "S-1-5-32-544"
Write-Both "    [+] Administrators               : $Administrators"

if(($Administrators | measure).count -ne 0){
        Write-Both "    [!] Administrators!!!"
    foreach($member in $Administrators){
        Add-Content -Path "$outputdir\administrators.txt" -Value "$($member.objectClass) $($member.SamAccountName) $($member.Name)"
    }
}

ltwarner avatar Sep 27 '22 14:09 ltwarner