Active directory dynamic groups and role based access using PowerShell

Posted by

Creating, updating and maintaining Active Directory group members can be a boring time intensive job. The following script creates new groups for all kind of unique job titles available in Active Directory. After the creation of all groups, it loops through all users and add these to the created groups in the function above. These scripts help you to maintain for example role base access.
* This script is made a long time ago, comment if things are not working on newer AD versions.

This script contains 3 functions:
1. Creating groups for all the unique job title’s available.
2. Adding users with the same Job title
3. Remove users after job title change

Leave a Reply

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