SSOGEN / Learn / Non-Human Identity: Service Accounts, Keys, Workloads and Agents

Learn

Non-Human Identity: Service Accounts, Keys, Workloads and Agents

A non-human identity is any credential software signs in with, like a service account, API key or agent, and each needs an owner and an end date.

Updated

Non-human identity types: service account, API key, workload identity and AI agent, each with an owner and an end date
Many outlive the person who created them.

A non-human identity (NHI) belongs to software, not to a person. A nightly job reads a database, a build pipeline deploys code, an AI agent files an expense claim.

In each case the caller must prove who it is, and the credential it uses is a non-human identity: a service account, an API key, a certificate, an OAuth client or a workload identity.

These identities matter because they never answer MFA prompts and are rarely reviewed. Many were created once by someone who has since left the organization, and they still work.

The five kinds of non-human identity

Names vary by vendor, but five patterns cover most of what an inventory finds.

Kind What it is How it proves itself Typical lifetime Typical weakness
Service account A directory or database account used by a program Password or key stored with the program Years Shared across systems, password never rotated, owner gone
API key A string that identifies the calling application The string itself, sent with each request Until deleted Copied into code, logs and chat; works for anyone who has it
OAuth client A registered application that obtains tokens Client secret, or a signed assertion Long, with short-lived tokens Secret leaked; scopes granted too widely
Workload identity An identity issued to a running workload by the system that hosts it Short-lived credential from the host system Minutes to hours Mis-scoped roles; applies only where the host system supports it
AI agent Software that chooses its own actions, often for a person Depends on setup: a key, or a person’s session Varies Borrows a person’s access, acts on text it read, no clear owner

The table is a working map, not a standard. The OWASP Non-Human Identities Top 10 doesn’t define the term formally; it describes NHIs by example: service accounts and access keys, API keys, tokens, encryption keys and certificates.

Why agents are a special case

A service account does one fixed thing. An agent decides at run time what to call, often for a particular person, which raises two issues the older kinds never did:

  • Authority. The call may use a person’s authority rather than the agent’s own.
  • Injected instructions. Text the agent read may have prompted the call.

Give each agent its own identity, owned by a person, and record both the agent and the person when it acts for someone. The agentic AI security explainer goes deeper.

The lifecycle problems, stage by stage

Most non-human identity incidents are lifecycle failures rather than sophisticated attacks. OWASP’s list follows the lifecycle: NHI1 Improper Offboarding, NHI2 Secret Leakage, NHI5 Overprivileged NHI, NHI7 Long-Lived Secrets, NHI9 NHI Reuse and NHI10 Human Use of NHI.

Stage What usually goes wrong What to require
Create No record of who asked for it or why Register it with a named owner and a stated purpose
Grant Broad access “to make it work” Smallest set of permissions, per application
Store Secret in source code, config or chat No standing secret where possible; otherwise a secrets store
Use One identity shared by many jobs; people sign in with it One identity per workload; interactive use blocked
Rotate Never, because nobody dares break the job Short-lived credentials, or rotation without downtime
Review Nobody looks A review date, with suspension if it lapses
Retire The project ended, the identity did not Disable when the owner leaves or the service ends; keep the record

A worked example: finding the orphan

Acme Corp lists every non-human identity that can reach its finance database.

  • svc-reports is a service account with a password last changed three years ago. Its creator left in 2023. Verdict: no owner, so suspend it, find what depends on it, replace it.
  • invoice-export-key is an API key found in a pipeline script. It works from any address. Verdict: leaked in principle, so replace it with a credential that expires.
  • ap-assistant is an AI agent that signs in with the AP manager’s own session. Logs show the manager. Verdict: give it its own identity that records the manager as the person it acts for.

Each identity needs a different fix, and every review starts from the same two facts: who owns the identity, and when it ends.

Controls that work across all five kinds

  1. Inventory first. You can’t govern identities you haven’t found, so count keys in repositories and accounts in directories.
  2. One owner per identity, plus a backup. Owners are always people.
  3. Use short-lived credentials tied to the caller’s own key, not static secrets.
  4. Scope to the task. Review permissions when the task changes.
  5. Set an end date or review date on every identity.
  6. Log each use under the identity’s own name, never a person’s.

How SSOGEN handles AI agents as non-human identities

SSOGEN registers AI agents, MCP clients, automations and services as non-human identities. Each has a name, a permanent identifier, a type, one primary owner and up to five owners, all people.

  • Credential. There is no password. The agent proves itself with a key pair, and you register only the public key; SSOGEN refuses a registration that contains a private key.
  • Access. Access is granted per application and scope.
  • End date. An Expires on or Review by date is required, no more than 365 days ahead. When the last owner leaves, the agent is suspended.
  • Consent. When an agent works for a person, it needs that person’s consent, which the person can revoke in My Account.

Every action is audited. See AI agent identity and the registration guide.

Questions people ask

What is a non-human identity?

An identity used by software instead of a person: a service account, API key, certificate, OAuth client, workload identity or AI agent.

What is the difference between a service account and an API key?

A service account is an account in a directory or system, with its own permissions. An API key is a string that identifies the caller. Both stay static unless you rotate them.

Is an AI agent a non-human identity?

Yes. It is the newest kind, and it differs from the others because it chooses its own actions and often acts for a person.

Why are non-human identities risky?

They are numerous, long-lived, rarely reviewed and often overprivileged. OWASP puts improper offboarding and secret leakage at the top of its list.

Where to go next

Sources, all read 2026-10-09: OWASP Non-Human Identities Top 10.