Workload identity federation removes secrets from CI, but every federated identity credential is a standing trust: whoever can run a workflow matching this subject can act as this identity in Azure. Nobody reviews these credentials after creation, so they accumulate.
pip install wiaudit
az login
wiaudit collect azure -o azure-snapshot.json --all-subscriptions
wiaudit scan --azure azure-snapshot.json --allowed-owners my-org,my-other-org --format html -o report.html
Read-only: Reader on the subscriptions and default read access to app registrations are enough. On large tenants only apps that trust GitHub are inspected, so collection takes minutes.
| Risk | Why it matters | wiaudit rule |
|---|---|---|
| Trust to repos on personal or external GitHub accounts | Outside your SSO, policies and offboarding | WIA010, WIA011 |
Wildcard (flexible) credential without repository_id |
Any repo with a matching name can get a token | WIA002 |
pull_request trust on a privileged identity |
Anyone who can open a PR can act as it | WIA003 |
| Trust to a deleted or renamed repo | The name can be re-registered by someone else | WIA006, WIA007 |
| Owner / Contributor / User Access Administrator on a whole subscription | Blast radius of a compromised workflow | WIA004 |
| Name-based subject | Follows renames and recycled names | WIA001 |
| 20/20 credentials on one identity | Nobody can add more; teams start sharing identities | WIA008 |
pull_request_target with id-token: write |
Untrusted code can request a token | WIA101 |
In a first run on a large production tenant, about 15% of all GitHub trust pointed to personal accounts — something no one had noticed.
and claims['repository_id'] eq '<id>' to flexible credentials (WIA002).Made by the authors of wiaudit (open source, Apache-2.0).