PowerShell Find all AD groups user is a member of.
1. Open Powershell ISE (in elevated mode);
NOTE: You must open the Powershell ISE with a user account that has rights to query the AD you are connected to.
2. Paste in the next code:
dsquery user domainroot -samid USER | dsget user -memberof | sort
NOTE: If you have an updated Powershell with AD Powershell Tools installed you can also run the following instead
Get-ADUser USER -Properties memberof | select -expand memberof | sort
3. Change USER to users logon ID and run;
NOTE: Just make sure the USER is replaced with users login account ID, ie if their login is like domain\username …. replace the USER in the script with the username and then run.