Securing AI agents: five identity controls engineering teams can apply now

AI agents act through API keys, OAuth grants and service accounts. Five identity controls for agent security, and how to apply them in a real stack.

TechLogHub Engineering Team
March 17, 2026
3 min read
0 views

Share Article

Top 5 Things CISOs Need to Do Today to Secure AI Agents

In March 2026, Token Security CEO Itamar Apelblat published a sponsored column on BleepingComputer arguing that AI agents should be secured mainly through identity and access control, not prompt guardrails. It is a vendor opinion piece, not news, but the main point is right and it applies to engineering teams, not just CISOs. An agent can only do what its credentials allow. Below, each of the five recommendations is translated into controls you can actually implement.

What happened

The column, labelled "Sponsored and written by Token Security" and published on 17 March 2026, makes five recommendations: treat every agent as an identity, put access control ahead of guardrails, remove shadow AI by discovering non-human identities, scope permissions to the agent's intended purpose, and govern the agent lifecycle from creation to decommissioning. It cites no data. These are design principles, not findings. The same ideas appear in the OWASP Top 10 for Agentic Applications, published in December 2025, which lists excessive agency, tool misuse and identity and privilege abuse among the main risks.

Who is affected

  • Teams running coding agents (Claude Code, Codex CLI, Cursor agents) with access to repositories, CI or cloud credentials.
  • Teams building internal agents that call production APIs, SaaS tools or databases, including through MCP servers.
  • Platform and security teams that own IAM, secrets management and audit logging, because agents add a new kind of non-human identity to everything they already manage.

What it means for developers and engineering teams

Guardrails aren't a security boundary. Prompt filters and output classifiers are probabilistic. Prompt injection from a web page, an issue comment or a tool result can push an agent off its task. The only hard limit is what its credentials can reach. A coding agent holding a personal access token with org-wide repo scope can push to every repository that user can, however well it was instructed.

Agents tend to inherit human permissions. The easiest setup is to let the agent use the developer's own session, CLI login or .env file. That gives the agent everything the human has, with no separate audit trail. Logs show "alice deleted the bucket", not "the agent acting for alice deleted the bucket".

Purpose-based scoping is just least privilege applied per task. An agent that triages issues needs read access to issues and write access to labels, not admin:org. Writing the agent's purpose down in plain words makes over-permissioning obvious in review.

Lifecycle is where credentials accumulate. Agents are cheap to create and easy to forget. Each one leaves behind OAuth grants, API keys and webhook secrets that keep working until someone revokes them.

What to do now

  1. Give each agent its own identity: a dedicated service account, GitHub App or OAuth client per agent, with a named human owner recorded in its metadata or tags. Don't let agents share a human's tokens.
  2. Use short-lived, scoped credentials: OIDC workload identity in CI, GitHub App installation tokens (valid for one hour) instead of PATs, and cloud roles with session policies. For MCP servers, use the OAuth-based authorization in the MCP spec rather than static keys.
  3. Write the agent's purpose down and derive permissions from it. Keep a short manifest per agent (purpose, systems, actions, data classes) in the repo, and review permission changes in pull requests like any other code.
  4. Require a human for destructive actions: deletes, IAM changes, production deploys and payments should go through an approval step the agent can't approve itself.
  5. Find shadow agents: list OAuth grants in Google Workspace or Entra ID, GitHub App and PAT inventories, and cloud access keys. Flag anything that has no owner or hasn't been used in 30 days.
  6. Log agent actions as the agent: make sure audit logs record the agent identity and the human who started it, and send them to your SIEM.
  7. Decommission properly: when an agent is retired, revoke its tokens, delete its service account and remove its webhooks in the same change.

Related on TechLogHub

Sources

Stay Updated

Get the next deep dive in your inbox

Subscribe for product analysis, engineering explainers, and practical guides published on TechLogHub.

See what launched this week

One email a week: new and trending developer tools, fresh comparisons, and what shipped. Unsubscribe in one click.