Agent Users should not have privileged directory roles or membership in role-assignable groups (Preview)
-IncludePreview: Invoke-Maester -TestId MT.1210 -IncludePreviewPart of Maester · Entra ID · Agent identities · All checks
Invoke-Maester -TestId MT.1210 -IncludePreviewOverview
Section titled “Overview”Agent Users should not have privileged directory roles or membership in role-assignable groups.
An Agent User is an Entra user account created specifically for an AI agent to access services that require user-context authentication (e.g. Teams, Exchange mailboxes, SharePoint sites). Because Agent Users represent non-human workloads, they should never be assigned Entra directory roles or added to role-assignable security groups.
This check inspects all Agent Users in the tenant and verifies that they do not hold privileged directory roles, either active or PIM-eligible, or memberships in role-assignable groups. A PIM-eligible role counts because the Agent User can activate it at any time. Reading eligible assignments needs Microsoft Entra ID P2 or Governance; without it, only active assignments are checked and the result says so.
Remediation action:
Section titled “Remediation action:”- Open the Microsoft Entra admin center and navigate to Entra ID > Users.
- Locate the reported Agent User using its Object ID or user principal name.
- Check Assigned roles and remove any directory administrative roles. Check both the Active assignments and Eligible assignments tabs.
- Check Groups and remove the user from any role-assignable security groups.
- If the agent only requires access to specific mailboxes or SharePoint sites, configure direct resource-level permissions (e.g. Mailbox delegation or SharePoint site sharing) rather than tenant-wide administrator roles.
Related links
Section titled “Related links”Details
Section titled “Details”Every attribute of this check
| Field | Value |
|---|---|
| Test ID | MT.1210 |
| Severity | High |
| Suite | Maester |
| Product | Entra ID |
| Feature | Agent identities |
| Area | Privileged access |
| Resource type | Agent |
| User impact | Low |
| Implementation cost | Medium |
| MITRE ATT&CK | T1078.004 Cloud Accounts, T1098.003 Additional Cloud Roles |
| Supports controls | nist-800-53-r5:AC-6(5) |
| PowerShell test | Test-MtEntraAgentUserExcessiveAccess |
| Services | Graph |
| Lifecycle | Preview |
| Long running | Yes |
Source
Section titled “Source”- Test:
tests/maester/entra/Test.MT.1210.ps1 - Documentation:
tests/maester/entra/Test.MT.1210.md
About this check
- Severity
- High
- Effort to fix
- Medium
- Impact on users
- Low
- Product
- Entra ID
- Feature
- Agent identities
- Area
- Privileged access
- Suite
- Maester