Hello, @Roger Roger,
Welcome to the Microsoft Q&A platform!
To identify which applications in your tenant are using the Application Impersonation RBAC role in Exchange Online, you can use the script provided in the GitHub repository you mentioned. The script is specifically designed to help identify users and applications with the Application Impersonation role assigned.
Here’s a more detailed example of the steps using PowerShell:
# Connect to Exchange Online
Connect-ExchangeOnline -UserPrincipalName your_admin_account@domain.com
# Get all users with the ApplicationImpersonation role assigned
$impersonationRoleAssignments = Get-ManagementRoleAssignment -Role ApplicationImpersonation
# Output or save the relevant information
$impersonationRoleAssignments | Select-Object RoleAssigneeName, RoleAssigneeType | Export-Csv -Path "C:\Path\ImpersonationRoleAssignments.csv" -NoTypeInformation
Test results:
Make sure you have the necessary permissions and prerequisites before running these scripts, and test in a safe environment if possible.
Should you need more help on this, you can feel free to post back.
If the answer is helpful, please click on “Accept answer” as it could help other members of the Microsoft Q&A community who have similar questions and are looking for solutions.
Thank you for your support and understanding.
Best Wishes,
Alex Zhang