Get local groups on remote devices

Many of my customers have moved to, or are moving to, an environment where they use the groups already in the Windows operating system to provide permissions on those systems.
So, they make a domain group member of a local group.

A customer asked me to write a script to get all the names of the local groups, including if they are local groups or domain groups.

You can call the function, and filter the output down to what you want, like so:

Leave a Reply

Your email address will not be published. Required fields are marked *