Commit Graph
11116 Commits
Author SHA1 Message Date
Michael Bolin 40849a1576 ci: add Bazel clippy workflow for codex-rs 2026-03-26 23:47:58 -07:00
Michael Bolin e2d3994f3b merge commit for archive created by Sapling 2026-03-26 23:35:38 -07:00
Michael Bolin 343fd48311 chore: move pty and windows sandbox to Rust 2024 2026-03-26 23:35:11 -07:00
Michael Bolin 5d82e09dcf ci: add Bazel clippy workflow for codex-rs 2026-03-26 23:35:11 -07:00
Michael Bolin 7b61b05d5a Merge 33e587edc5 into sapling-pr-archive-bolinfest 2026-03-26 23:27:52 -07:00
Michael Bolin 33e587edc5 ci: add Bazel clippy workflow for codex-rs 2026-03-26 23:27:45 -07:00
Celia Chen dd30c8eedd chore: refactor network permissions to use explicit domain and unix socket rule maps (#15120)
## Summary

This PR replaces the legacy network allow/deny list model with explicit
rule maps for domains and unix sockets across managed requirements,
permissions profiles, the network proxy config, and the app server
protocol.

Concretely, it:

- introduces typed domain (`allow` / `deny`) and unix socket permission
(`allow` / `none`) entries instead of separate `allowed_domains`,
`denied_domains`, and `allow_unix_sockets` lists
- updates config loading, managed requirements merging, and exec-policy
overlays to read and upsert rule entries consistently
- exposes the new shape through protocol/schema outputs, debug surfaces,
and app-server config APIs
- rejects the legacy list-based keys and updates docs/tests to reflect
the new config format

## Why

The previous representation split related network policy across multiple
parallel lists, which made merging and overriding rules harder to reason
about. Moving to explicit keyed permission maps gives us a single source
of truth per host/socket entry, makes allow/deny precedence clearer, and
gives protocol consumers access to the full rule state instead of
derived projections only.

## Backward Compatibility

### Backward compatible

- Managed requirements still accept the legacy
`experimental_network.allowed_domains`,
`experimental_network.denied_domains`, and
`experimental_network.allow_unix_sockets` fields. They are normalized
into the new canonical `domains` and `unix_sockets` maps internally.
- App-server v2 still deserializes legacy `allowedDomains`,
`deniedDomains`, and `allowUnixSockets` payloads, so older clients can
continue reading managed network requirements.
- App-server v2 responses still populate `allowedDomains`,
`deniedDomains`, and `allowUnixSockets` as legacy compatibility views
derived from the canonical maps.
- `managed_allowed_domains_only` keeps the same behavior after
normalization. Legacy managed allowlists still participate in the same
enforcement path as canonical `domains` entries.

### Not backward compatible

- Permissions profiles under `[permissions.<profile>.network]` no longer
accept the legacy list-based keys. Those configs must use the canonical
`[domains]` and `[unix_sockets]` tables instead of `allowed_domains`,
`denied_domains`, or `allow_unix_sockets`.
- Managed `experimental_network` config cannot mix canonical and legacy
forms in the same block. For example, `domains` cannot be combined with
`allowed_domains` or `denied_domains`, and `unix_sockets` cannot be
combined with `allow_unix_sockets`.
- The canonical format can express explicit `"none"` entries for unix
sockets, but those entries do not round-trip through the legacy
compatibility fields because the legacy fields only represent allow/deny
lists.
## Testing
`/target/debug/codex sandbox macos --log-denials /bin/zsh -c 'curl
https://www.example.com' ` gives 200 with config
```
[permissions.workspace.network.domains]
"www.example.com" = "allow"
```
and fails when set to deny: `curl: (56) CONNECT tunnel failed, response
403`.

Also tested backward compatibility path by verifying that adding the
following to `/etc/codex/requirements.toml` works:
```
[experimental_network]
allowed_domains = ["www.example.com"]
```
2026-03-27 06:17:59 +00:00
Michael Bolin 3e302cc922 Merge 66dfd10d45 into sapling-pr-archive-bolinfest 2026-03-26 23:10:55 -07:00
Michael Bolin 66dfd10d45 ci: enable the Windows Bazel workflow path 2026-03-26 23:10:45 -07:00
Michael Bolin d4dce27f9f Merge 835436c50f into sapling-pr-archive-bolinfest 2026-03-26 23:00:51 -07:00
Michael Bolin 835436c50f ci: enable the Windows Bazel workflow path 2026-03-26 23:00:33 -07:00
Michael Bolin 919cca1eea Merge c08ee0863a into sapling-pr-archive-bolinfest 2026-03-26 22:54:23 -07:00
Michael Bolin 1dfa6e0a59 chore: move pty and windows sandbox to Rust 2024 2026-03-26 22:54:06 -07:00
Michael Bolin c08ee0863a ci: add Bazel clippy workflow for codex-rs 2026-03-26 22:54:06 -07:00
Michael Bolin 18c664919c Merge 03a23002e8 into sapling-pr-archive-bolinfest 2026-03-26 22:42:07 -07:00
Michael Bolin 03a23002e8 ci: add Bazel clippy workflow for codex-rs 2026-03-26 22:41:51 -07:00
Michael Bolin 1664d0a7e6 chore: move pty and windows sandbox to Rust 2024 2026-03-26 22:41:51 -07:00
Michael Bolin 083ba4c82c Merge 9ae14c4390 into sapling-pr-archive-bolinfest 2026-03-26 22:33:57 -07:00
Michael Bolin 9ae14c4390 ci: enable the Windows Bazel workflow path 2026-03-26 22:33:46 -07:00
Michael Bolin 99b1837479 Merge a6932eb88a into sapling-pr-archive-bolinfest 2026-03-26 22:25:36 -07:00
Michael Bolin a6932eb88a ci: add Bazel clippy workflow for codex-rs 2026-03-26 22:25:24 -07:00
Michael Bolin 987742a6db chore: move pty and windows sandbox to Rust 2024 2026-03-26 22:25:24 -07:00
Michael Bolin 5157b6daa5 merge commit for archive created by Sapling 2026-03-26 22:20:28 -07:00
Michael Bolin 0add39b43d ci: enable the Windows Bazel workflow path 2026-03-26 22:20:10 -07:00
Michael Bolin 9548b9b7f4 Merge 34542eb511 into sapling-pr-archive-bolinfest 2026-03-26 22:19:38 -07:00
Michael Bolin ff4198f0ad Merge 68af048a5f into sapling-pr-archive-bolinfest 2026-03-26 22:19:24 -07:00
Michael Bolin 34542eb511 ci: add Bazel clippy workflow for codex-rs 2026-03-26 22:16:18 -07:00
Michael Bolin 68af048a5f chore: move pty and windows sandbox to Rust 2024 2026-03-26 22:16:13 -07:00
Michael Bolin b83e814bbe Merge d5db735682 into sapling-pr-archive-bolinfest 2026-03-26 22:07:43 -07:00
Michael Bolin d5db735682 codex-tools: introduce named tool definitions 2026-03-26 21:56:20 -07:00
Michael Bolin 36531fea0e Merge 4d84919f26 into sapling-pr-archive-bolinfest 2026-03-26 21:54:49 -07:00
Michael Bolin 4d84919f26 ci: enable the Windows Bazel workflow path 2026-03-26 21:54:44 -07:00
Michael Bolin a7315772c5 Merge 4086ec990f into sapling-pr-archive-bolinfest 2026-03-26 21:51:37 -07:00
Michael Bolin 4086ec990f ci: enable windows bazel workflow 2026-03-26 21:51:22 -07:00
rhan-oai 21a03f1671 [app-server-protocol] introduce generic ClientResponse for app-server-protocol (#15921)
- introduces `ClientResponse` as the symmetrical typed response union to
`ClientRequest` for app-server-protocol
- enables scalable event stream ingestion for use cases such as
analytics
- no runtime behavior changes, protocol/schema plumbing only
2026-03-26 21:33:25 -07:00
Michael Bolin f6f8ada11b merge commit for archive created by Sapling 2026-03-26 21:20:04 -07:00
Michael Bolin f9451bde24 codex-tools: extract dynamic tool adapters 2026-03-26 21:19:44 -07:00
Michael Bolin 41fe98b185 fix: increase timeout for rust-ci to 45 minutes for now (#15948)
https://github.com/openai/codex/pull/15478 raised the timeout to 35
minutes for `windows-arm64` only, though I just hit 35 minutes on
https://github.com/openai/codex/actions/runs/23628986591/job/68826740108?pr=15944,
so let's just increase it to 45 minutes. As noted, I'm hoping that we
can bring it back down once we no longer have two copies of the `tui`
crate.
2026-03-26 20:54:55 -07:00
Michael Bolin e191d9e898 Merge 99fe9ab8e8 into sapling-pr-archive-bolinfest 2026-03-26 20:50:28 -07:00
Michael Bolin 99fe9ab8e8 fix: increase timeout for rust-ci to 45 minutes for now 2026-03-26 20:50:19 -07:00
Michael Bolin 5f06b045dc Merge 03f6dda330 into sapling-pr-archive-bolinfest 2026-03-26 19:59:07 -07:00
Michael Bolin 03f6dda330 codex-tools: extract dynamic tool adapters 2026-03-26 19:57:41 -07:00
Michael Bolin be5afc65d3 codex-tools: extract MCP schema adapters (#15928)
## Why

`codex-tools` already owns the shared tool input schema model and parser
from the first extraction step, but `core/src/tools/spec.rs` still owned
the MCP-specific adapter that normalizes `rmcp::model::Tool` schemas and
wraps `structuredContent` into the call result output schema.

Keeping that adapter in `codex-core` means the reusable MCP schema path
is still split across crates, and the unit tests for that logic stay
anchored in `codex-core` even though the runtime orchestration does not
need to move yet.

This change takes the next small step by moving the reusable MCP schema
adapter into `codex-tools` while leaving `ResponsesApiTool` assembly in
`codex-core`.

## What changed

- added `tools/src/mcp_tool.rs` and sibling
`tools/src/mcp_tool_tests.rs`
- introduced `ParsedMcpTool`, `parse_mcp_tool()`, and
`mcp_call_tool_result_output_schema()` in `codex-tools`
- updated `core/src/tools/spec.rs` to consume parsed MCP tool parts from
`codex-tools`
- removed the now-redundant MCP schema unit tests from
`core/src/tools/spec_tests.rs`
- expanded `codex-rs/tools/README.md` to describe this second migration
step

## Test plan

- `cargo test -p codex-tools`
- `cargo test -p codex-core --lib tools::spec::`
2026-03-26 19:57:26 -07:00
Michael Bolin 12dac1c06c merge commit for archive created by Sapling 2026-03-26 19:43:54 -07:00
Michael Bolin 00a3cea3bb permissions: start using PermissionProfile as the canonical runtime model 2026-03-26 19:43:49 -07:00
Michael Bolin 384b0527ac merge commit for archive created by Sapling 2026-03-26 19:08:05 -07:00
Michael Bolin 82bebb3212 permissions: start using PermissionProfile as the canonical runtime model 2026-03-26 19:06:03 -07:00
Michael Bolin d838c23867 fix: use matrix.target instead of matrix.os for actions/cache build action (#15933)
This seems like a more precise cache key.
2026-03-27 01:32:13 +00:00
Michael Bolin d76124d656 fix: make MACOS_DEFAULT_PREFERENCES_POLICY part of MACOS_SEATBELT_BASE_POLICY (#15931) 2026-03-26 18:23:14 -07:00
Michael Bolin 758ffbd095 Merge 82f8680619 into sapling-pr-archive-bolinfest 2026-03-26 17:55:59 -07:00