Skip to content

exec-server: own portable sandbox permission wire types#28126

Closed
anp-oai wants to merge 1 commit into
codex/cross-platform-path-renderingfrom
codex/exec-server-permission-path-uri-wire
Closed

exec-server: own portable sandbox permission wire types#28126
anp-oai wants to merge 1 commit into
codex/cross-platform-path-renderingfrom
codex/exec-server-permission-path-uri-wire

Conversation

@anp-oai

@anp-oai anp-oai commented Jun 13, 2026

Copy link
Copy Markdown
Collaborator

Why

The exec-server filesystem API should carry paths portably and evolve independently from core sandbox permission types. Reusing the core types exposed host-native AbsolutePathBuf values and coupled the public JSON contract to codex_protocol.

Stacked on #27819, which provides the cross-platform path rendering used by this change.

What changed

  • Add an exec-server-owned sandbox permission type family whose concrete permission paths use PathUri.
  • Convert core contexts to the wire types before remote RPCs and validate wire paths back into core types once in the server handler.
  • Preserve legacy native-path, pre-tagged profile, alias, default, and read/write JSON compatibility while serializing canonical tagged profiles with file: URIs.

Validation

Added round-trip and JSON compatibility coverage for every permission variant, foreign URI rejection, and URI-bearing permission paths crossing the websocket RPC boundary.

@anp-oai anp-oai force-pushed the codex/exec-server-permission-path-uri-wire branch from 5c7995f to 1fe7001 Compare June 13, 2026 23:04
@anp-oai anp-oai changed the base branch from main to codex/cross-platform-path-rendering June 13, 2026 23:04
rejected as an invalid request.

Sandboxed operations run in a hidden helper process launched from the
top-level `codex` executable and prepared through the shared sandbox transform

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

remove this second paragraph from this diff

@@ -0,0 +1,168 @@
use std::num::NonZeroUsize;

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

what if we extracted the sandbox types to a protocol_shared crate and make the stack of types generic over the path representation? we could define a trait for a sandbox path if we need generic code to do things with the paths

@anp-oai anp-oai closed this Jun 13, 2026
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