# Do not run the agent as a default or pre-granted account

Facts read 10 Nov 2026. Page reviewed 16 Nov 2026.

Check 5 of 30: Do not run the agent as a default or pre-granted account. Default accounts are created for convenience and can carry broad roles that nobody chose for the agent. An agent that inherits one gets access no one reviewed.

## Why it matters

Default accounts are created for convenience and can carry broad roles that nobody chose for the agent. An agent that inherits one gets access no one reviewed.

## How, in each cloud

- **AWS:** Replace the console-created default role with a role you wrote; AWS documents the Lambda console default as an execution role with minimal permissions (basic logging).
- **Google Cloud:** Do not rely on the Compute Engine default service account, which can receive the Editor role; enforce the iam.automaticIamGrantsForDefaultServiceAccounts constraint.
- **Azure:** none found on 2026-11-10

## What the documentation says

- "By default, Lambda creates an execution role with minimal permissions when you create a function in the Lambda" ([source](https://docs.aws.amazon.com/lambda/latest/dg/lambda-intro-execution-role.html))
- "Editor role ( roles/editor ) on the project by default." ([source](https://cloud.google.com/iam/docs/best-practices-service-accounts))
- "automatically be granted the Editor role on your" ([source](https://cloud.google.com/run/docs/securing/service-identity))

- [Previous: Scope the role's trust to the specific agent, service account or workload](/checklist/scope-trust-to-the-agent/)
- [Next: Write the agent's permission policy from what its tools actually call](/checklist/least-privilege-policy/)

## Related pages

- [Write the agent's permission policy from what its tools actually call: the check, and how in AWS, Google Cloud and Azure](/checklist/least-privilege-policy/)
- [Set an organization-level ceiling the agent's role cannot exceed: the check, and how in AWS, Google Cloud and Azure](/checklist/set-permission-ceiling/)
- [Explicitly deny the agent IAM changes and destructive actions: the check, and how in AWS, Google Cloud and Azure](/checklist/deny-iam-changes-and-destructive-actions/)

## Sources

- docs.aws.amazon.com/lambda/latest/dg/lambda-intro-execution-role.html: https://docs.aws.amazon.com/lambda/latest/dg/lambda-intro-execution-role.html (read 10 Nov 2026)
- cloud.google.com/iam/docs/best-practices-service-accounts: https://cloud.google.com/iam/docs/best-practices-service-accounts (read 10 Nov 2026)
- cloud.google.com/run/docs/securing/service-identity: https://cloud.google.com/run/docs/securing/service-identity (read 10 Nov 2026)

Last reviewed 16 Nov 2026. Canonical: https://aiagentaccesscontrol.com/checklist/no-default-accounts/
