Skip to content

Studio: skip a Terminal PATH entry MXC cannot grant instead of failing every launch - #14129

Merged
danielhanchen merged 1 commit into
mainfrom
studio-mxc-skip-reparse-path-dirs
Oct 18, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
studio-mxc-skip-reparse-path-dirs

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Fixes #13656

Problem

On Windows, Settings > Sandbox could not enable High for a user with Java 8 installed. The live check failed with:

the live MXC probe failed: MxcPolicyError: MXC policy paths may not traverse a reparse point: C:\Program Files (x86)\Common Files\Oracle\Java\java8path

The Terminal profile grants read access to every PATH entry under Program Files (so Git's usr\bin tools work inside the sandbox). Each grant must not go through a symlink or junction, which is correct, but one such entry made the whole policy build raise. The Java 8 installer puts a directory symlink (java8path) on the system PATH, so every Terminal launch and the Terminal capability probe failed, and the sandbox reported itself unavailable.

Change

  • _trusted_terminal_path_dirs checks each Program Files PATH entry with the same _safe_canonical_path rule as before and skips (logs) an entry it cannot grant, as _model_read_roots already does for model folders. The other entries are still granted.
  • Nothing is granted that was not granted before: a link entry gets no read grant (it is not followed), so a tool reached only through it is not available inside the sandbox. The reparse rule for workdirs, executables and other grants is unchanged.

Tests

  • test_reparse_point_on_terminal_path_is_skipped_not_fatal: a junction (Windows) or symlink (elsewhere) under a trusted Program Files dir on the Terminal PATH. On main it raises the same MxcPolicyError as in the issue; with the change the launch request builds, the plain Git dir is granted and neither the link nor its target is.
  • The existing MXC policy, grant and wiring tests pass unchanged.

@danielhanchen danielhanchen self-assigned this Oct 18, 2026
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 18, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-18T12:35:29.001621Z d09515a Manual request
🔒 Security Review ⚠️ Failed 2026-10-18T12:16:44.096297Z d09515a PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

1 similar comment
@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Swish!

Reviewed commit: d09515aec0

ℹ️ 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".

@danielhanchen
danielhanchen merged commit c980574 into main Oct 18, 2026
@danielhanchen
danielhanchen deleted the studio-mxc-skip-reparse-path-dirs branch October 18, 2026 13:51
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.

[Bug] Failure to enable Windows MXC Sandbox, unclear instructions

1 participant