
What happened
A developer found that Codex 0.164.0's read-only setting for automated PR reviews did not restrict where it could read, so they switched to permission profiles that deny the root and allow only git, python3, rg and the workspace.
Why it matters
With read-only, a reviewer could read files unrelated to the task, so limiting the allowed locations keeps the review scoped to the working folder and the tools it needs.
Summaries like this, every morning.
The developer's earlier automated review used -s read-only, which only forbids writing and leaves reading unrestricted. The trigger for change came on the morning of November 8, when a review of another PR pointed out that read-only does not narrow where Codex reads. Testing with mock files placed outside the working folder—data not meant to be seen, a list of forbidden words, ssh keys, and .env—confirmed that read-only Codex could read all of them.
The replacement is a permission profile, a beta feature in Codex 0.164.0 on this Mac that sets read, write, or deny per location, with deny blocking both reading and writing. The profile closes the root entirely and opens only the minimum Codex needs, the command-line tools for git and python3, the location for rg, and the workspace, where .env is denied. The developer passes this table on each call via -c rather than editing the config file, and does not pass -s. They also add --disable view_image because the documentation did not state whether profile rules apply to built-in tools.
Three subtle points emerged. Passing -s causes the old sandbox setting to take precedence and the profile to be ignored without error, so the caller checks for that key before starting Codex. The log header still shows sandbox: read-only even when the profile is active, so a test with mock folders runs nightly and after Codex upgrades. And a workspace's .codex/config.toml is loaded for trusted repositories, so the developer refuses to run if .codex exists in the workspace. The nightly test verifies that mock files not meant to be seen and .env are unreadable, while workspace files and git remain readable.
Pick your industry and the AI tools you use, and get news related to your work every day.
Free · 30 seconds with Google · unsubscribe anytimeWhat is AIToday? →
Ask AI anything about this article. The AI reads this article, earlier AIToday articles, and Wikipedia, and cites its sources. Q&As are published on this page for other readers too.
Concentrate AI launched a healthcare AI gateway giving companies access to OpenAI’s GPT, Anthropic’s Claude, a…

For a Forbes report, AI agents booked four Uber rides within one week, with the bookings running through platf…

Schwab surprised analysts by rapidly launching its own MCP servers, moving from read-only AI to agentic AI tha…

Rain launched Agent Vaults on November 10, letting AI agents spend from pre-funded vaults via single-use virtu…

JPMorgan Chase is blocking AI agents from shopping with its customers' credit cards when customers give an age…

Computer Weekly reports that the broadband industry is approaching its "next Netflix moment" as AI agents resh…
