Inventory rule to see who is a member of the Local Administrator group
Is there a way for us to see who is part of the local administrators group on devices?
I've got Custom Inventory Rules, for Windows, Linux and Mac. These were setup by the trainer when we purchased KACE.
Local Administrators Listing - Windows (CIF)
ShellCommandTextReturn(cmd /c net localgroup Administrators)
Local Administrators Listing - Linux (CIF)
ShellCommandTextReturn(grep wheel /etc/group | sed 's/^.*:root,//')
Local Administrators Listing - Mac (CIF)
ShellCommandTextReturn(dscl . -read /Groups/admin GroupMembership | sed 's/GroupMembership: root //' | sed 's/ / | /g')