Analysis
August 14, 2026
8 min read
Maxime Dalessandro

Your agent's approval was valid. By commit time, it wasn't.

Agent guardrails check permissions when an action is requested. Two new papers show the check can be false by the time the effect commits. Databases have owned this race for decades.

#AI agents#Agent governance#Approval gates#Access control#Transactions#PostgreSQL#Agent security

TL;DR. A paper posted August 3 names the bug that every AI agent guardrail on the market currently ships: stale authorization, a permission check that was true at request time and false by execution. Budgets, grants, inventory, and approval status all change while an agent plans, waits for a human, or retries. The paper proposes a correctness bar, policy-state serializability, that says a committed effect must be authorized against the policy state immediately before it commits, and its prototype is built on PostgreSQL for a reason: databases have owned the check-then-act race for decades, and the machinery that closes it (predicates evaluated at write time, row locks, serializable isolation) lives inside the transaction boundary. Every gateway, spend cap, and approval screen sits outside that boundary. That is the architectural problem, and no amount of model quality fixes it.

The permission check that stands between an AI agent and your production database is a snapshot with a timestamp. On August 3, a paper on stateful governance for concurrent agentic systems gave the resulting failure mode a name: stale authorization. A request-time check reads budgets, inventory, approval status, or risk signals, decides the action is allowed, and then the effect executes later, against a world the check never saw. The paper's examples are the exact actions the industry spent this summer wiring agents into: refunds, inventory holds, transfers, resource provisioning. Its diagnosis is that existing safeguards decide from the information available when an action is requested, and for stateful policies that view is already expiring as the decision is made.

This is not a hypothetical gap between two lines of code. It is the defining gap of agent architectures, because everything agents do stretches it.

Agents stretch the distance between check and effect

Classic time-of-check to time-of-use bugs live in microseconds: two threads race through a file-permission check inside one process. Agent workflows rebuild the same shape at human scale. A multi-step plan authorizes an action now and executes it three steps later. A retry re-runs an action whose authorization was evaluated before the failure. A fleet of agents shares one budget, one inventory table, one set of grants, and one database role, so any member can invalidate the state another member's check just read. And the write path this race sits on is no longer theoretical: managed Postgres is becoming agent-writable by default, with mutation load arriving on whatever cadence an orchestrator decides.

The sharpest version involves the guardrail everyone agrees on. The most recommended control of 2026 is the human approval gate: Google's Database Observability Agent executes fixes "with your approval", and nearly every agent-governance product shipping this year gates risky actions on a human click. An approval gate inserts a human into the loop, and humans take minutes to hours to click. The gate adds latency between decision and effect, which widens exactly the window in which the decision goes stale. The control and the failure mode feed each other. An approval granted at 14:09 against a budget with headroom says nothing about the budget at 14:31, after two sibling agents spent it.

Notice what this failure survives: a perfectly aligned model, a perfectly scoped credential, and a perfectly informed approver. Read-only modes do not reach it, because it is a property of the write path. The model proposed a correct action. The human approved a correct action. The state moved.

Two papers, four weeks apart, one failure mode

The August paper proposes a correctness bar borrowed, explicitly, from the database world. It defines policy-state serializability: every committed effect should be explainable as authorized against the policy state immediately before it occurs. Not the state at request time, not the state at approval time. Its prototype runtime, Provenact, keeps policies as reviewable programs and coordinates the state its decisions depend on, and it is built on PostgreSQL. In the paper's scripted procurement workflows, baselines that passed policy state to the agent as ordinary request context produced stale authorizations over shared budgets and inventory; the runtime that re-established decisions against current state did not, while letting delayed approvals proceed without blocking unrelated work.

An independent paper from July, Temporary Authority, Permanent Effects, reaches the same boundary from the security side. It studies the moment a durable effect commits on the strength of evidence gathered earlier: an approval, a version witness, a snapshot of some interface state. Its proposed rule is commit-time authorization: the effect is allowed only if the evidence that licensed it is still fresh, causally prior, bound to that specific effect, and still eligible at commit. Its most uncomfortable measurement is that agents kept completing tasks successfully after the authority behind them had lapsed. Success metrics stayed high. Nothing in an agent's completion signal tells you its permission slip expired mid-run.

Both papers are weeks old, and their evaluation numbers could not be independently mirrored here, so treat the quantitative claims as the authors'. The conceptual convergence is the point: two groups, working from governance and from security, both concluded that request-time authorization is the wrong contract, and both relocated the check to the commit.

Two timelines comparing authorization models. In the request-time model, a policy check passes at 14:02, a human approves at 14:09, another agent exhausts the shared budget at 14:17, and the effect still commits at 14:31 against state the check never saw, with a bracket marking the 29-minute window nothing re-checks. In the commit-time model, the same events occur, but re-validation inside the transaction fails at 14:31, the transaction aborts, and nothing commits.

An approval is evidence about the past. A commit is an event in the present.

Databases solved check-then-act. The solution has a boundary.

Database engineers will recognize stale authorization instantly, because it is the race the transaction system exists to manage. It even has a canonical beginner form in Postgres. At the default READ COMMITTED isolation level, each statement sees its own snapshot, so this familiar gate is broken even when both statements share a transaction:

-- 14:02  the gate reads policy state
SELECT spent, cap FROM agent_budgets WHERE team = 'ops';
-- application code: 4,200 of 5,000, allow the 700 spend

-- 14:31  the effect commits
UPDATE agent_budgets SET spent = spent + 700 WHERE team = 'ops';

Any number of commits can land between the read and the write, and the write will happily push spent past cap. Postgres offers three escalating fixes, and each one is a lesson in where authorization has to live.

The first is to put the policy predicate inside the effect, so check and act become one atomic statement that re-evaluates against current rows:

UPDATE agent_budgets
   SET spent = spent + 700
 WHERE team = 'ops' AND spent + 700 <= cap;
-- zero rows updated: the authorization no longer holds

The second is SELECT FOR UPDATE, which locks the policy rows a transaction depends on and re-reads their current committed state, so a budget or approval row checked this way cannot change under the transaction before the effect commits. The third is SERIALIZABLE isolation, which makes the engine verify at commit that everything the transaction read still holds in some consistent order, and aborts it with a serialization failure if the world moved. That last mechanism is policy-state serializability, enforced by an engine that has been shipping it for years. The paper's contribution is the observation that agent governance needs the same property; the property itself is bought, not invented.

But every one of these mechanisms shares a boundary: they defend only decisions made inside the transaction. And the entire agent guardrail stack sits outside it. The MCP gateway evaluates policy before the query is sent. The spend cap is checked in the orchestrator. The approval screen renders in a browser. By the time the effect reaches the database, the authorization is a foregone conclusion smuggled in as context, which is precisely the baseline configuration that produced stale authorizations in the August paper's experiments. The database cannot re-validate a decision it never saw.

Authorize the effect, not the request

The architectural conclusion is uncomfortable for the gateway-shaped products this market is funding, but it follows directly: the only component positioned to authorize an effect at commit time is the one doing the committing. For a team wiring agents into a database today, that converts into four concrete moves.

  • Keep policy state where the effects happen. A budget enforced in the orchestrator's memory is unenforceable at commit. A budget in a table, spent by the same transaction that performs the effect, is enforced by the engine.
  • Make approvals leases, not events. Store an approval as a row with a scope bound to a specific action, an epoch, an expiry, and a revocation path. The effect transaction re-reads it with FOR UPDATE and verifies it is still live before committing. An approval that cannot be revoked between click and commit is not a control.
  • Prefer predicates over pre-checks. Any policy that can be expressed in the effect's own WHERE clause is immune to staleness by construction.
  • Give retries an idempotency key. A retried action must not re-spend an approval or a budget that its first attempt consumed. The papers' framing of evidence "bound to the same effect" is this rule in formal dress.

None of this is a silver bullet, and two limits deserve naming. First, effects that leave the database have no commit boundary to defend: the email sent, the external API called, the VM provisioned. Those need compensation logic, not isolation levels, and re-validating right up to the last database write only narrows the window rather than closing it. Second, commit-time re-validation guards the state a policy reads, not the judgment behind it. A gate whose approval screen omits the context the decision needs fails at a different layer, whatever its timing. Freshness and quality of authorization are separate axes, and this year's products are being graded on both.

The market shipped request-time gates first because they are where a vendor can bolt on: in front of the model, in front of the API, in front of the connection. Both of this summer's papers, one from governance, one from security, arrived at the layer the bolt-on cannot reach. Authorization is a property of the commit. The systems that already know how to enforce properties at commit are databases, which suggests the guardrail conversation is about to become a database conversation, whether the gateway vendors like it or not.

Where Datapace fits

Datapace is building the context layer between your databases and your AI: resolved meaning validated by the people who own the data, the workload evidence beside it (cost, performance, usage and freshness, lineage), and a policy gate over what an agent may do and access, served over MCP. The argument above is one of the design constraints that work has to respect: a policy decision made far from the data expires on its way to the effect, so governing agent writes means engaging the transaction boundary rather than standing in front of it. If you are mapping out what safe agent access to a production database requires, start with safe AI agent access to production databases, or book a call.

Sources

  1. Stateful Governance for Concurrent Agentic Systems, arXiv, posted August 3, 2026.
  2. Temporary Authority, Permanent Effects: Commit-Time Authorization for LLM Agents, arXiv, posted July 11, 2026.
  3. Google Cloud, "Deep dive on new AI-powered database agents", August 4, 2026.
  4. PostgreSQL documentation: Transaction Isolation.
  5. PostgreSQL documentation: Explicit Locking.

Frequently asked questions

What is stale authorization in AI agent systems?
Stale authorization is a permission decision that was correct when it was made but no longer holds when the action takes effect. An agent's plan is checked against budgets, grants, inventory, or approval status at request time, then the effect executes seconds to hours later, after that state has changed. The term was formalized in an August 2026 paper on stateful governance for concurrent agentic systems, which identifies it as the core failure mode once agents execute stateful effects like refunds, transfers, and provisioning.
Why do request-time permission checks fail for AI agents?
Because agent workflows stretch the gap between check and effect. Multi-step plans queue actions for later, human approval gates add minutes or hours of latency, retries re-execute yesterday's decision, and fleets of agents share budgets and grants that any of them can change concurrently. A check made at request time describes the world at request time. Nothing in the standard guardrail stack re-establishes that the decision still holds at the moment the effect commits.
What is policy-state serializability?
Policy-state serializability is a correctness condition proposed in an August 2026 paper: every committed effect should be explainable as authorized against the policy state immediately before it occurs, not against a snapshot from earlier in the workflow. It deliberately borrows from database serializability, which makes concurrent transactions behave as if they ran one at a time. The paper's prototype, Provenact, was built on PostgreSQL, where the engine's own concurrency machinery can enforce that reads still hold at commit.
How can PostgreSQL prevent stale authorization?
By putting the policy check inside the same transaction as the effect. A single UPDATE that carries the policy predicate in its WHERE clause makes check and effect atomic, since it recomputes against current rows. SELECT FOR UPDATE lets a transaction lock and re-read policy rows like budgets or approvals before acting on them. SERIALIZABLE isolation goes furthest: it aborts the transaction at commit if the state it read no longer holds. All three only defend decisions made inside the transaction boundary.
Do human approval gates prevent stale authorization?
No, and they can make it worse. An approval gate verifies that a human agreed with the action based on the state visible at approval time. The approval then sits in a queue while the human context-switches, which widens the interval between decision and effect, and the state the human evaluated keeps moving. An approval is only reliable if it is treated as a lease that is re-validated when the effect commits: bound to a specific action, carrying an expiry, and revocable in between.

Keep reading

Ready to let agents touch production, safely?

Bring a use case. We will show you what agents can do on your live data, inside your guardrails.