kosa8 / Cybersecurity / Zero trust for AI agents

Topic · Zero trust and non-human identity

Zero trust for AI agents: non-human identity, secrets and access

Updated

Zero trust says no user, device or workload is trusted because of where it sits; every access is verified, granted with the least privilege, and watched. AI agents are the workload that most needs it: non-human identities that act with real permissions on input written by strangers. This page applies the zero trust model to AI agents, covers non-human identity and secrets for agents, and shows how kosa8 enforces each part outside the agent's reach, and where it stops.

01Why AI agents break implicit trust

Most systems still trust a process because of where it runs: on a developer's laptop, inside the VPC, under a service account. An AI agent inherits that trust and adds two things a normal workload does not have. It decides its own next action, and it can be told what to do by anything it reads: a README, an issue, an email, a web page, a tool description. Prompt injection turns "assume breach" from a planning principle into a daily event.

An agent is also a non-human identity: it holds API keys, tokens and service credentials, often more of them than the person who started it, and it uses them at machine speed. Secrets in environment variables and dotfiles are readable by any code the agent runs, including code it was tricked into writing. Zero trust for AI agents means treating the agent as untrusted by default, every time, and putting every decision about it somewhere it cannot reach.

02The zero trust model, applied to AI agents

NIST SP 800-207, Zero Trust Architecture, sets out the model: no implicit trust based on network location, access granted per request with least privilege, decisions made by a policy point the subject does not control, and continuous monitoring. For an agent, each tenet becomes a concrete control.

Zero trust tenetFor an AI agentIn kosa8
No implicit trust from locationThe agent's machine is not trusted because it is yoursEach agent runs in its own microVM with its own kernel and sees one folder; nothing on the host trusts what runs inside
Least privilege, per requestOnly the hosts and tools the task needsNetwork denied by default and allow-listed per sandbox; a signed MCP policy sets which tools each scope may use
Policy decided outside the subjectThe agent cannot change its own rulesNetwork rules, the egress broker and the signed organisation policy live on the host; root in the guest cannot lift them, and a tampered policy refuses everything
Strong verification of sensitive actionsRisky actions need a personTool rules answer allow, deny or ask; held calls wait for named approvers, with signed approvals spent once and two-person approval where policy requires it
Protect credentialsThe agent never holds a real secretAPI keys stay with the egress broker on the host; the agent holds a placeholder that is worthless anywhere else
Continuous monitoringEvery action is visible and attributableA hash-chained, signed audit log written by the host, with each agent's name in the entries it causes, forwarded to your SIEM

03Non-human identity for AI agents

Every agent should be a named identity with a person accountable for it, not an anonymous process running as whoever launched it. In kosa8, an agent identity has an accountable human owner, and per-agent tokens put each agent's name in the audit entries it causes, so "who did this" has an answer that names both the agent and its owner.

Identity also means scope. The privileges a key carries inside the system it reaches are set by that system, not by kosa8, so scope each key at the provider: a read-only token for an agent that only reads, a project-limited key for an agent that works on one project. On kosa8 Cloud, people sign in to the web app with OIDC single sign-on on the Team and Scale plans.

04Secrets: keep the keys out of the agent

The most reliable way to stop an agent leaking a key is for the agent never to have it. kosa8's egress broker holds real API keys on the host and adds them to requests on the way out, only to the provider's own hosts. Inside the sandbox the variable holds a placeholder, so an injected instruction that prints the environment prints nothing useful, and a copied placeholder is worthless anywhere else.

One limit matters: while the sandbox runs, the placeholder can still be spent along its allowed route, because that is how the agent does its work. Scope the key at the provider, give each agent its own key, and rotate it if an agent misbehaves. In depth: give an AI agent API keys without exposing them and why the key should never enter the sandbox.

05Network access: default deny, decided on the host

Zero trust networking for an agent starts closed. Every frame from a kosa8 sandbox crosses a network guard on the host, so root inside the guest cannot lift the rules. The rules exist before the machine boots, DNS answers only listed names, and each refusal is counted and written to the audit log. A sandbox can be fully closed, allow-listed, or given a simulated internet for malware work.

Allow-lists bound where data can go, not what is sent there: HTTPS bodies to allowed hosts are not inspected, so an allowed host that accepts uploads is still a way out. In depth: restrict an AI agent's network to an allow-list.

06Where zero trust for agents stops

  • kosa8 is not an identity provider or a secrets vault. It keeps the keys an agent uses out of the agent's machine and ties actions to an owner; your identity provider and secrets manager stay where they are.
  • Prompt injection itself. kosa8 bounds what a hijacked agent can do; it does not detect the injection.
  • Anything running as you. A process under your account can call the kosa8 service and approve a held call. Forward the audit log off the machine.
  • Hosted Cloud. Each hosted sandbox is its own microVM, but the audit log, evidence export and signed policy are features of the software on your own machines and hosts; hosted Cloud sandboxes do not expose them yet.

kosa8 has no SOC 2 report yet (SOC 2 Type II is in progress, with the report expected in January 2027) and has not had an external penetration test. The full threat model is on the security page; the wider control framework is on AI security for the enterprise.

07Questions

What is zero trust for AI agents?

Applying the zero trust model to AI agents: no agent is trusted because of where it runs, each gets only the hosts, tools and credentials its task needs, decisions about it are made somewhere it cannot change, risky actions are verified by a person, and every action is recorded.

What is non-human identity for AI agents?

Treating each AI agent as an identity in its own right, with its own credentials, scope and an accountable human owner, rather than as an anonymous process running with its user's permissions. It makes each action attributable and each key revocable on its own.

Can an AI agent in kosa8 read its API key?

Not a brokered key. The key stays with the egress broker on the host and the sandbox holds a placeholder that is worthless anywhere else. While the sandbox runs, the placeholder can still be spent along its allowed route, so scope the key at the provider too.

Does kosa8 replace our identity provider or secrets manager?

No. kosa8 keeps the keys an agent uses out of the agent's machine, decides its network on the host and ties its actions to an owner. Your identity provider and secrets manager keep doing their jobs alongside it.

08Guides and deep dives

09Get started

kosa8 installs with one line on macOS, Linux and Windows (WSL2), or runs hosted on kosa8 Cloud. Book thirty minutes to walk through how your agents get identities, keys and network access today.

Get started Book a security review See pricing

Sign up → Add a card → Pick a plan (charged now) → Use kosa8. Plans start at $29 a month; there is no free tier or trial.