How to Keep a Machine Identity Inventory Current: A 2026 Guide for Cloud Teams
Why machine identity inventories go stale, what to record for each identity, and a simple routine for keeping the list accurate across AWS, Azure and Google Cloud.
Key takeaways
- An inventory starts going stale the day after it is built.
- Pull identities from each cloud's own records instead of asking teams what they have.
- Record a small, consistent set of facts for every identity, starting with an owner.
- Compare each discovery run with the last and review what is new, changed or unused.
- Count AI agents and every identity they can act through.
Building a list of your machine identities is the easy part. Keeping it true is where most teams slip, because every deployment, new integration or new AI agent can quietly add another service account, key or token. The fix is a routine: discover from the clouds themselves, record the same few facts every time, and look closely at what changed since last time.
This is the first of the seven practices in our guide to IAM for AI agents and machine identities, and the one the others depend on.
What to count
Start broad. On AWS that means IAM roles, IAM users with access keys, instance profiles, service-linked roles and identity providers 1. In Microsoft Entra and Azure it means service principals, app registrations and managed identities, along with their credentials 2 3. On Google Cloud it means service accounts, their keys and workload identity federation 4. Across all of them, include API tokens, OAuth consent grants and AI agents.
Agents deserve a second look. Record the agent and every identity it can act through: the service account it runs as, the keys in its configuration, and any personal tokens it borrows. An agent without an identity of its own is almost always using someone else's.
Why the spreadsheet falls behind
Spreadsheets and CMDBs work when people report changes. Machine identities rarely come with a ticket. A pipeline creates a role, a vendor integration adds an app registration, an engineer generates a key to test something on a Friday. A few weeks later the list describes what used to exist.
What to record for each identity
Keep it short enough that people will actually fill it in:
| Field | Why it matters |
|---|---|
| Owner | Someone has to answer whether it is still needed |
| Purpose | Lets a reviewer judge whether the access fits |
| Credential type and age | Old static keys leak most easily and are hardest to trace |
| Permissions | What it is allowed to do |
| Reach | Which data, systems, accounts and tenants those permissions touch |
| Last used | Separates live identities from forgotten ones |
| Created by | Ties it back to a team, pipeline or vendor |
Go to the source
Each cloud already keeps the facts you need. AWS offers credential reports and last accessed data 5 6. Google Cloud offers service account usage monitoring 7. Microsoft Entra records sign-in activity for workload identities 2. Reading these with read-only access gives you what actually exists, not what people remember.
A simple review routine
Save each discovery run and compare the next one with it. That gives you three short lists to work through. New identities need an owner and purpose confirmed while the creator still remembers. Changed identities, especially those with new permissions, new credentials or new trust relationships, deserve attention because that is how attackers hold on to access. Unused identities are cleanup candidates once their owner agrees.
What auditors usually want
Whether the framework is SOC 2 or NIST SP 800-53 8, the requests tend to be the same: a complete account list, owners, proof of periodic review and what you did about the findings. A current inventory with its review history covers all four.
Where Avistar fits, and where it doesn't
Keeping this list current is what Avistar does today. It discovers machine identities across AWS, Azure and Google Cloud with read-only, agentless access, keeps a living inventory with ownership and permission context, ranks risk by privilege, exposure, staleness, ownership and blast radius, and keeps findings as access review evidence. It does not change access for you, rotate secrets or detect an intrusion in progress. Your teams decide and make the fixes.
Read next: AWS machine identity discovery, a walkthrough of finding every role, key and trust relationship in an AWS organization.
Frequently asked questions
- What belongs in a machine identity inventory?
- Service accounts, service principals, managed identities, IAM roles, access keys, tokens, OAuth apps and app registrations, and AI agents, across every cloud tenant.
- Why do spreadsheets and CMDBs fall behind?
- They depend on people reporting changes. Machine identities are created by pipelines, infrastructure code and cloud services, usually without a ticket, so the record drifts within days.
- How often should the inventory be refreshed?
- Often enough that new identities are reviewed while the person who created them still remembers why. Many teams match discovery to their release rhythm, review changes weekly, and run a full access review at least quarterly.
Sources
- https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html
- https://learn.microsoft.com/en-us/entra/workload-id/workload-identities-overview
- https://learn.microsoft.com/en-us/entra/identity/managed-identities-azure-resources/overview
- https://cloud.google.com/iam/docs/best-practices-service-accounts
- https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_getting-report.html
- https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_last-accessed.html
- https://cloud.google.com/iam/docs/service-account-monitoring
- https://csrc.nist.gov/pubs/sp/800/53/r5/upd1/final