Files
codex/codex-rs/app-server/tests
felixxia-oai 223b61a9a8 Refresh Guardian v3 evidence before retrying an approval review (#63363)
## Why

A user's authorization can change while Guardian is reviewing a tool call.
A retry could reuse the original evidence cutoff and miss a revocation
that arrived during the first attempt.

## What changed

Capture the root thread's history position when the action is bound and
defer evidence routing until Guardian prepares the review. Capture a fresh
position on retries or if authorization changed before the first attempt.
Use bounded history reads to catch up through the selected position and
wait for routing to reach it before submitting the assessment.

## Testing

Extend the app-server test to revoke authorization through a paused user
goal while an MCP tool call's approval is pending. Verify that Guardian
discards the stale allow, sees the revocation on retry, and denies the
tool call. Cover bounded history reads and shared routing progress in
unit tests.

GitOrigin-RevId: d7cf6f03412c4aa5399700427f40710da3123e52
2026-11-23 15:57:15 +00:00
..