Skip to content

fix(linux-sandbox): recreate symlink aliases for writable roots#17295

Open
viyatb-oai wants to merge 3 commits intomainfrom
codex/viyatb/recreate-bwrap-symlink-aliases
Open

fix(linux-sandbox): recreate symlink aliases for writable roots#17295
viyatb-oai wants to merge 3 commits intomainfrom
codex/viyatb/recreate-bwrap-symlink-aliases

Conversation

@viyatb-oai
Copy link
Copy Markdown
Collaborator

@viyatb-oai viyatb-oai commented Apr 10, 2026

Follow-up to #15981 for the remaining logical-symlink compatibility gap.

Absolute logical symlink paths are still not universally recreated inside restricted bwrap; the fix makes relative execution and writable-root binding work safely. If #15157 requires every logical absolute path to remain addressable inside the sandbox, that is a larger alias-recreation problem.

This PR starts that larger alias-recreation work for the Linux bwrap path by recreating the first logical symlink component for symlinked writable roots when the alias is not already visible through a logical read mount. That lets absolute logical paths such as a symlinked workspace root resolve inside restricted bwrap while still binding writes to the real target from #15981.

Validation:

  • cargo check -p codex-linux-sandbox --tests
  • cargo clippy -p codex-linux-sandbox --tests
  • just fmt
  • git diff --check

Related: #15157

Copy link
Copy Markdown
Contributor

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cc29af481e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/linux-sandbox/src/bwrap.rs Outdated
Comment thread codex-rs/linux-sandbox/src/bwrap.rs Outdated
Base automatically changed from codex/viyatb/investigate-issue-15781 to main April 11, 2026 00:01
@viyatb-oai viyatb-oai force-pushed the codex/viyatb/recreate-bwrap-symlink-aliases branch from cc29af4 to e8aefa2 Compare April 11, 2026 00:08
Co-authored-by: Codex noreply@openai.com
@viyatb-oai viyatb-oai force-pushed the codex/viyatb/recreate-bwrap-symlink-aliases branch from e8aefa2 to d50d061 Compare April 11, 2026 03:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant