An agent service account has broader access than the user
Detect: Effective permissions exceed the delegated role.
Recover: Intersect service capability with user authority before execution.
Assign stable permissions to organizational roles and enforce those permissions at every agent tool and data boundary.
Role-based access control maps users or service identities to roles and roles to permitted operations. In an agent architecture, it controls which tools can be invoked and which classes of resources can be accessed. The model can explain a requested action, but it cannot grant itself a role or establish the caller's identity.
Roles work best when they correspond to stable job responsibilities. Keep role assignment separate from role activation and apply separation of duties where one actor must not initiate and approve the same operation. Resource ownership, geography, and changing context may require additional attribute-based controls beyond a role alone.
A prototype often uses one developer credential. Replace it with explicit reader and operator roles before exposing shared enterprise systems.
Production centralizes role definitions, validates identity tokens, and checks permissions at tool services rather than only hiding interface buttons. Record the acting user and service identity separately.
At scale, role lifecycle and review matter as much as request-time enforcement. Prevent role explosion, revoke departed users promptly, and test nested-role behavior and privileged service-account scope.
Authenticates principals and issues trusted identity and group assertions.
Maps approved organizational membership to stable role definitions.
Defines which actions and resource classes each role may access.
Checks the actual tool or data request before execution.
Tracks role grants, removals, exceptions, and separation-of-duties decisions.
flowchart LR
I["Identity provider"] --> R["Role directory"]
R --> P["Permission policy"]
A["Agent tool request"] --> E["Enforcement point"]
P --> E
E --> V["Read invoice"]
E --> C["Create payment proposal"]
E --> H["Independent approval"]
E --> L["Access decision log"]Validate the session or delegated token and establish both user and workload identity.
Load current approved roles without accepting role names from prompt content.
Determine whether the requested operation belongs to the active role's allowed capability set.
Apply separation of duties and any additional resource-specific conditions.
Reject unauthorized operations even if the agent or interface attempted to invoke them.
Record the action, principal, active role, policy version, and allow or deny result.
Accounts payable · Illustrative enterprise scenario, not a reported customer outcome.
A shared-services center uses an assistant to retrieve invoices, explain exceptions, and prepare payment proposals.
A broadly privileged integration account lets clerks accidentally request operations reserved for treasury approvers.
The assistant must support each employee's work while preserving existing responsibility boundaries.
Reader, preparer, and approver roles govern tool permissions, with an independent check preventing self-approval.
If directory synchronization fails, privileged actions deny access rather than reusing an indefinitely stale grant.
Track denied privileged requests, stale memberships, self-approval attempts, and time to revoke access. Role checks support the process but do not replace financial controls.
| Decision | Benefit | Cost |
|---|---|---|
| Stable roles | Permissions align with understandable job responsibilities. | Fine-grained exceptions can create too many roles. |
| Central definitions | Policy changes remain consistent across tools. | Directory availability and cache freshness become dependencies. |
| Role inheritance | Shared permissions can be reused. | Complex hierarchies can grant unexpected effective authority. |
Detect: Effective permissions exceed the delegated role.
Recover: Intersect service capability with user authority before execution.
Detect: Revocation tests or directory versions reveal stale membership.
Recover: Expire cached grants and invalidate active privileged sessions.
Enforce permissions in every backing tool service.
Use authenticated directory assertions only.
Add scoped attributes or redesign responsibilities.