Excessive service-role delegation
A restricted principal can cause an allowed service to execute with a more powerful role than the application contract permits.
Candidate CWE: CWE-266
Test hypothesis#
In an isolated owned account, compare one disposable canary-only job using its intended role with the same job using the excessive role. Check service create/update permission, role trust and resource permissions together. On GCP, assess workload-create/update permission together with service-account attachment (actAs) and the selected account's resource grants; do not equate actAs with Token Creator.
Evidence required#
Starting identity, role selection, accepted service operation, generated job identity and synthetic metadata access that the starting identity cannot perform.
Rule out false positives#
PassRole permission without a usable service operation, incompatible role trust, or intended administrative delegation. PassRole has no standalone API audit event.
Playbook and command references#
- Cloud IAM: trust, delegation and effective permissions — Prove which principal can act on which resource, including cross-account trust, delegated roles and workload federation.
- Azure and GCP: identity, delegation and storage access — Apply provider-specific controls for Azure management/data permissions and SAS, plus GCP service accounts, federation and object ACLs.
Find the associated command snippets
Referenced by these target playbooks#
Report checklist#
- Capture the affected version, configuration, identities, and object ownership.
- Preserve a valid baseline and a negative control.
- Reproduce the forbidden data access, action, or state change on controlled fixtures.
- Explain the intended security rule and why the observed behavior violates it.
- State prerequisites, uncertainty, cleanup, and the smallest demonstrated impact.
Conditional ATT&CK mapping#
No direct ATT&CK mapping selected. Record the weakness and demonstrated impact without forcing an adversary-behavior classification. See the mapping guide.