Microsoft 365, AD and Windows · #32
Online AD Group Membership Diff
Compares a group's member list at two points in time by identity (SID/GUID); separates renames from membership changes.
- Data is processed in your browser and not sent to a server
- Export: CSV
Tool
What does this tool do?
Membership of privileged groups such as Domain Admins should be reviewed regularly. Comparing lists by name shows a person whose surname changed as 'removed + added' and hides the real change. The tool compares by SID (or objectGUID, or sAMAccountName).
How to use it
- Export before and after lists:
Get-ADGroupMember 'Domain Admins' | select name,SamAccountName,SID | ConvertTo-Csv -NoTypeInformation. - Paste both lists and press Calculate.
Fields
- Earlier list (A)
- CSV with header: name,SamAccountName,SID
- Later list (B)
- Same columns
Worked example
| Input | Value |
|---|---|
| Earlier list (A) | |
| Later list (B) | |
Expected result: 1 added (Mehmet Can), 1 removed (svc_backup), 1 renamed (Ayşe Kaya → Ayşe Demir, same SID), 1 unchanged.
Ayşe's SID did not change, so there is no permission change, only a name update. Check the change request for the newly added Mehmet Can, and whether the removed service account is used in a scheduled task or backup job.
Method and assumptions
The key column is chosen as SID → objectGUID → SamAccountName; both lists must use the same kind. Comparison is case-insensitive.
Keys only in A are removed, only in B added, present in both with a different name/sAMAccountName renamed.
Using the result and troubleshooting
Treat unexpected additions as security events; search the time in the Windows security log for event IDs 4728/4732/4756 (Windows Event XML Viewer).
Limits and common mistakes
- Nested groups are not expanded; use a list exported with
-Recursiveto include indirect members. - Names of foreign security principals (FSP) are not resolved.
Frequently asked questions
Why SID?
The SID stays the same when a person's name, OU or sAMAccountName changes. A deleted and recreated account gets a new SID even with the same name and shows as 'removed + added', which is correct.
Related tools and service
- SID Parser and Inventory CheckSplits a SID list into components, shows domain and RID, recognises well-known accounts and flags duplicates.
- AD Distinguished Name ParserSplits one or more DNs into CN, OU path, domain and canonical name.
Related service: Active Directory Security Audit