Do AI coding agents make your access reviews harder or easier?
Enterprises are increasingly letting large language model (LLM)‑driven assistants write queries, spin up tables, and even modify schemas in data warehouses such as BigQuery. The agents act on behalf of developers, but they are not people – they are processes that consume secrets, run under service accounts, and execute code automatically. From an auditor’s perspective that shift creates two tensions.
First, the traditional access‑review workflow expects a static list of human identities, each tied to a role or group. When a bot runs a query, the reviewer sees a service account name, not the intent of the developer who prompted the agent. Second, the rapid, iterative nature of AI‑generated code means permissions are exercised far more frequently, often with a broader set of SQL functions than a human would normally invoke. The result is a noisy audit trail that makes it difficult to answer the core question of any access review: *who did what, and why?*
Why access reviews matter for AI coding agents
Access reviews are meant to verify that every principal has only the privileges required for its job. When an AI coding agent is introduced, the “principal” becomes a non‑human identity that can be spun up on demand, reused across projects, and granted wide‑area scopes to simplify development. Without additional controls, a reviewer will see a service account with broad BigQuery permissions and no evidence of the business justification for each query it runs.
The risk is two‑fold. Over‑privileged service accounts become a vector for lateral movement if the underlying secret is compromised. At the same time, auditors lose confidence in the review process because the logs do not capture the human intent that triggered the agent’s actions. Both outcomes undermine the purpose of the review.
What a proper control model looks like
To keep access reviews meaningful, organizations need a three‑part model.
- Setup: Define non‑human identities in the identity provider, assign them the minimal set of roles, and require that every AI‑driven request be tied to a human‑initiated approval token. This step decides *who* can request access, but it does not enforce any guardrails on its own.
- The data path: Insert a gateway that sits between the AI agent and BigQuery. All traffic must flow through this point so that policies can be evaluated before the query reaches the warehouse.
- Enforcement outcomes: The gateway records each session, masks sensitive result fields, and can require just‑in‑time approval for risky commands. Because the gateway is the only place enforcement happens, the audit log it produces becomes the authoritative evidence for the access review.
This architecture ensures that a reviewer sees not just a service account name, but a concrete record of who asked the AI to run the query, what the query contained, and whether any inline masking was applied.
