Four kinds of non-human identity, and what changes when one of them can think
How service accounts, machine identities, workload identities and AI agents differ in trust anchor, credentials, lifecycle and Conditional Access, mapped to Entra ID.
Service accounts, machine identities, workload identities and AI agents look alike on an org chart of credentials. They’re governed very differently. This article is a field map for IAM practitioners: what each type is, how they stack in a single request, how their concepts line up, and where the old playbook stops working.
Why this matters now
Non-human identities already outnumber people in most enterprises. For years we managed them with one playbook: give the thing an account, vault the password, find an owner, review it once a year. That playbook still works for some of them. It falls apart for others, and it barely applies to AI agents, which are the first non-human identities that decide what to do.
The industry often uses “machine identity” as the umbrella term for all of these. This article splits the umbrella into four, because each type has its own trust anchor, credential model and failure mode.
The four identities
A quick way to tell them apart is the question each one answers.
Service account
An account someone created and handed a password.
The oldest model: a directory or app account with no person behind it. Long-lived credentials, static permissions, a human owner.
Typical uses:
- Batch and ETL jobs connecting to databases
- Apps querying AD or LDAP
- Scheduled tasks, IIS app pools
- SaaS integrations using API keys
Main risk: hardcoded, shared, never rotated, orphaned when the owner leaves. PAM’s home ground.
Machine identity
A device proving itself with a certificate or key.
The identity of a server, laptop, appliance or IoT device. Cryptographic, and managed through PKI and certificate lifecycle tooling.
Typical uses:
- TLS on web servers and load balancers
- mTLS between hosts, SSH host and user keys
- Device trust for Zero Trust access
- IoT/OT devices, 802.1X network access
Main risk: expired certs causing outages, stolen SSH keys enabling lateral movement.
Workload identity
Code whose identity the platform vouches for.
The identity of running software (container, function, pipeline), issued by the platform through attestation. No stored secrets, short-lived tokens.
Typical uses:
- Kubernetes pods reading cloud storage or vaults
- Managed identities for Azure services
- CI/CD deploying via OIDC federation
- Microservices in a service mesh (SPIFFE)
Main risk: wildcard roles, loose federation trust, roles that outlive the workload.
AI agent identity
Software that decides what to do, often for a person.
An autonomous actor that picks tools, data and actions at runtime. Non-deterministic, often delegated (on-behalf-of a user), governed through a blueprint and a sponsor.
Typical uses:
- Helpdesk agents resetting passwords or granting access
- Copilots acting in a user’s mail and files
- SOC agents triaging alerts and isolating hosts
- IGA agents recommending revocations
Main risk: prompt injection steering a legitimately authenticated identity, over-scoped delegation, shadow agents.
They stack, not just sit side by side
Take one request: an employee asks an HR copilot to update their home address. All four identity types take part in that single action.
- Agent identity: the copilot gets an on-behalf-of token for the user and decides to call the HR API tool.
- Workload identity: the agent’s container uses its workload identity to fetch secrets from Key Vault.
- Machine identity: the node it runs on presents an mTLS certificate that the service mesh trusts.
- Service account: the HR backend writes to a legacy payroll database with a service account vaulted in a PAM tool.
A tightly scoped agent can still be compromised through an over-privileged pod role or a stale payroll service account underneath it. NHI governance has to cover every layer.
The terminology map
Most agent-identity concepts have an equivalent in what IAM teams already run. The terms in the AI agent column come from Microsoft Entra Agent ID, which is a useful reference vocabulary.
Core constructs
| Concept | Service account | Machine identity | Workload identity | AI agent |
|---|---|---|---|---|
| Template | App registration | Cert template, golden image, MDM profile | IAM role definition, K8s deployment spec, SPIFFE registration entry | Agent identity blueprint |
| Runtime identity | AD account, service principal | X.509 cert, SSH host key, TPM-bound key | K8s ServiceAccount, IAM role session, managed identity, SPIFFE SVID | Agent identity (plus optional agent user) |
| Identifier | UPN, sAMAccountName | Hostname, serial, cert subject or SAN | ARN, spiffe://domain/ns/x/sa/y |
Agent object ID |
| Trust anchor | AD or IdP | PKI CA, TPM | Cluster or cloud OIDC issuer, trust domain | IdP plus blueprint |
| Accountable human | App owner | IT ops or asset owner | Platform or DevOps team | Owner plus sponsor |
| Inventory | CMDB, service account register | CMDB, MDM, CLM tool | Cloud IAM, CIEM, CSPM | Agent registry |
Credentials and authorization
| Concept | Service account | Machine identity | Workload identity | AI agent |
|---|---|---|---|---|
| Credential | Password, secret, API key | Cert plus private key, SSH key | Short-lived token (projected SA token, SVID, federated OIDC) | Federated creds held by the blueprint, short-lived tokens |
| Proof of identity | Knows a secret | Holds a private key | Platform attestation | Blueprint-issued token, often on-behalf-of |
| Credential lifetime | Months to years | ~1 year and shrinking (public TLS heads to 47 days by 2029) | Minutes to hours | Minutes to hours, per task |
| Rotation | PAM vault rotation | CLM automation (ACME) | Automatic, platform-managed | Automatic, secretless |
| Entitlements | Roles, groups, DB grants | Network trust, authorized_keys, sudoers |
IAM policies, K8s RBAC, mesh policies | Scopes, tool (MCP) permissions, data access |
| Separation of duties | Toxic entitlement combos | Keys trusted on too many hosts | Wildcard policies | Toxic tool combos (“read PII” + “send external email”) |
| Acts for a human? | Rarely | No | Rarely (token exchange) | Often. Effective access = agent ∩ user permissions |
Lifecycle, review and audit
| Stage | Service account | Machine identity | Workload identity | AI agent |
|---|---|---|---|---|
| Joiner | App onboarding ticket | Device enrollment, cert issuance | Created by the CI/CD pipeline | Deployed from a blueprint |
| Mover | Ownership change | Host repurposed or rebuilt | Role or config change | Model, prompt or tool change. Treat it like a role change |
| Leaver | Decommission | Retire device, revoke cert | Workload dies, but the role often lingers | Retire the agent, or disable the blueprint for all its agents |
| Orphans | Owner left | Unrevoked certs, stale SSH keys | Unused roles, stale federation trusts | Sponsor left, or shadow agents |
| Certification | Owner attestation | Rarely done | Unused-permission reports | Sponsor attests purpose, tools and data |
| Audit trail | Account did Y | Cert or host in mTLS and SSH logs | Cloud logs, mesh logs by SPIFFE ID | User → agent → tool → resource chain |
Where Conditional Access fits
Conditional Access sits between authentication and authorization. Authentication asks “who are you?”, authorization asks “what can you do?”, and Conditional Access asks “should we allow this, right now, in this context?” Its strength drops sharply as identities get less human.
| Concept | Service account | Machine identity | Workload identity | AI agent |
|---|---|---|---|---|
| Does Entra CA apply? | Cloud user-type accounts only, not on-prem Kerberos or NTLM | Not as the subject. The device is a signal in user policies | Yes, via CA for workload identities (single-tenant service principals; not managed identities) | Agent identities can be targeted, and the user’s CA applies to on-behalf-of tokens |
| Typical controls | Block outside trusted IPs. MFA isn’t feasible | Require a compliant or managed device | Block only, by location or risk | Block or allow, step-up through the human for delegated actions |
| Non-Entra equivalents | Okta network zones, PAM session policies | NAC posture, Okta device assurance | AWS IAM conditions, GCP IAM Conditions, VPC Service Controls, OPA | Agent and MCP gateways, runtime guardrails |
| Classic gap | Excluded from MFA policies and covered by nothing else | Unmanaged devices outside policy | Federated CI/CD and K8s workloads skip CA entirely | Autonomous agents with no human to step up |
The Entra ID toolkit, by identity type
Here’s how Microsoft Entra’s features line up across the four types. Cloud user accounts stand in for service accounts. On-prem AD service accounts and gMSAs live in AD.
| Capability | Service account | Machine identity | Workload identity | AI agent |
|---|---|---|---|---|
| Identity object | User account | Device object (joined, hybrid, registered) | App registration and service principal, managed identity | Blueprint, agent identity, agent user |
| Credential hygiene | Password policies, cert-based auth | TPM keys, Windows Hello, Primary Refresh Token | Federated identity credentials, app management policies, expiring-credential recommendations | Inherited from the blueprint, no agent-level secrets |
| ID Protection | User and sign-in risk | Defender for Endpoint risk via Intune compliance | Workload identity risk | Agent risk detections |
| Privileged access | PIM: JIT, approvals | Windows LAPS | Time-bound role assignments | Scoped, admin-consented permissions |
| Access reviews | Users, groups, app assignments | Stale-device cleanup instead | Service principal reviews for privileged roles | Sponsor-driven reviews |
| Sign-in logs | Non-interactive user sign-ins | Device details in user sign-ins | Service principal and managed identity sign-ins | Agent sign-ins and on-behalf-of chain |
| Kill switch | Block sign-in, revoke sessions | Disable device, Intune wipe | Disable SP, remove creds or federation trust | Disable agent or blueprint |
| Licensing | Entra ID P1/P2, ID Governance | Entra ID P1, Intune | Workload ID Premium | Agent ID licensing |
Gaps: Entra has no native service-account type, doesn’t manage certificates or SSH keys (that’s Intune Cloud PKI or a CLM tool), puts its strongest workload controls behind an add-on, and governs an agent’s access but not its decisions.
Where the old playbook breaks
- Behavior isn’t deterministic. A service account does exactly what its code says. An agent decides at runtime, so permissions alone don’t bound its behavior. It also needs guardrails on intent and action.
- Delegation is the default. Most service accounts act as themselves. Agents usually act for someone, so the human’s entitlements become part of the agent’s effective access, and the audit trail has to show the whole chain.
- Agents come and go too fast for quarterly reviews. When agents spin up per session or task, review the blueprint, not each instance, the same way we govern roles rather than individual people.
- The attack surface moved. For service accounts the threat is credential theft. For agents it’s also prompt injection: an attacker steering an identity that authenticated correctly.
Key takeaways
- Service accounts are governed by owners, machines by PKI, workloads by the platform, and agents by sponsors plus runtime guardrails.
- The more dynamic the identity, the more you govern the template instead of the instance.
- A single request can cross all four types, so a well-scoped agent is only as safe as the workload, machine and service account identities underneath it.
- Agent identity governance isn’t a new discipline invented from scratch. It’s lifecycle, least privilege, ownership and certification applied to a new kind of identity, with intent added as a new control surface. The teams that already govern service accounts and workloads well are the right people to own it.
Microsoft Entra Agent ID is new, and its features and licensing are still changing. Check Microsoft Learn for current preview and GA status before relying on specific capabilities.