AI coding agents no longer wait for a developer to accept a suggestion. They open pull requests, run tests, edit infrastructure files and, in some pipelines, push changes toward production with little human review. Adoption is climbing fast. In a May 2026 Stack Overflow pulse survey, 59% of respondents said they use AI agents at work, up from 31% in 2025.
That speed creates a governance gap. Most software development lifecycle (SDLC) controls assume a human writes, reviews and approves each change. When an agent handles all three steps, those assumptions break. CISOs need new controls before agents can merge code, modify infrastructure or deploy changes.
From AI assistant to autonomous actor
The first AI coding tools worked like advanced autocomplete. The tool offered code suggestions, the developer decided whether to accept them and responsibility stayed with the human.
Today's agents act on their own. Given a ticket or a goal, an agent can read a repository, write code across many files, execute shell commands, install dependencies and trigger CI/CD jobs. Common tasks include fixing bugs, writing tests, upgrading libraries, refactoring legacy code and drafting infrastructure-as-code changes.
Agents also work in teams. One agent writes code, a second reviews it and a third runs security scans. Humans increasingly act as supervisors who approve outcomes rather than authors who write each line. Gartner predicts that by 2027, more than 65% of engineering teams using agentic coding will treat IDEs as optional, shifting control, governance and validation to automated platforms.
Given these trends, the security question shifts from whether a suggestion is safe to what an autonomous actor can do and who is accountable for its actions.
The new attack surface: Agent access and privileges
To do useful work, agents need access to source code, API keys, cloud credentials, package registries and build pipelines. Some reach production directly. Each permission expands the blast radius if something goes wrong.
Several attack vectors exist today:
- Prompt injection. Attackers can hide instructions in issues, README files, code comments or webpages an agent reads. A manipulated agent might then leak secrets or insert malicious code.
- Credential exposure. Agents often run with long-lived tokens borrowed from developer machines. These rarely expire or follow least privilege.
- Unauthorized changes. An agent might edit files outside its task, weaken a security check to make tests pass or alter infrastructure without review.
- Supply chain risk. Agents can pull in unvetted packages or hallucinated package names that attackers have registered in advance.
- Lost accountability. When an agent acts under a developer's identity, logs can't separate human actions from machine actions.
Developers see the risk too. In the Stack Overflow study, 78% of respondents said they worry about data privacy and security when using AI agents.
Rethinking security for autonomous development
Start with one principle: Treat every AI agent as a privileged nonhuman identity. Apply the rigor used for service accounts and admin users, plus controls for agent unpredictability. The six functions of the NIST Cybersecurity Framework 2.0 offer a structure for those controls.
1. Govern
Stand up an agent governance program shared by security, platform engineering and development leads. It should approve new agents, set policy for what agents can touch and review their access on a set schedule. Assign a named human owner to every agent and every agent-initiated change, so accountability never rests with software.
2. Identify
You can't secure agents you don't know about. Build an AI agent inventory that records each agent, its owner, tools, data access and permissions. Use it to drive a permissions framework that tiers agents by risk, from read-only helpers to agents with merge or deploy rights.
3. Protect
Give each agent its own identity, separate from the developer who launched it. Issue short-lived, task-scoped credentials through a secrets manager instead of static tokens. Grant read access by default and require explicit approval for write, merge and deploy rights.
Then set guardrails on execution:
- Allowlist the commands, tools, network destinations and package sources each agent can use.
- Run agents in sandboxed containers with no default internet access.
- Require human review for agent changes to CI/CD configuration, IAM policies and security tooling.
- Use branch protection rules that block agents from merging their own pull requests.
4. Detect
Log each prompt, tool call, command and file modification, and tie those logs to the agent's identity. Sign agent commits so reviewers can tell machine work from human work. Monitor for anomalies, such as unexpected network calls, privilege escalation attempts or edits outside task scope.
5. Respond
Update incident response playbooks to cover agent compromise, including prompt injection. Teams should be able to pause an agent and revoke its credentials within minutes. Use the audit trail to trace every change the agent made and every system it reached.
6. Recover
Plan rollback before it is needed. Revert agent changes through version control and infrastructure state history and rotate any secrets the agent could access. After each incident, tighten the agent's permissions tier and feed the lessons back into governance.
AI agents will continue to take on more of the SDLC. CISOs who set these controls now can let teams move fast without granting unchecked privileges to software that takes instructions from anything it reads.
Matthew Smith is a vCISO and management consultant specializing in cybersecurity risk management and AI.