Skip to content

feat(skills): add permission profiles from openai.yaml metadata - #11658

Merged
celia-oai merged 6 commits into
mainfrom
dev/cc/skill-permission
Feb 14, 2026
Merged

celia-oai merged 6 commits into
mainfrom
dev/cc/skill-permission

Conversation

@celia-oai

@celia-oai celia-oai commented Feb 12, 2026 •

Copy link
Copy Markdown
Contributor

Summary

This PR adds support for skill-level permissions in .codex/openai.yaml and wires that through the skill loading pipeline.

What’s included

  1. Added a new permissions section for skills (network, filesystem, and macOS-related access).
  2. Implemented permission parsing/normalization and translation into runtime permission profiles.
  3. Threaded the new permission profile through SkillMetadata and loader flow.

Follow-up

A follow-up PR will connect these permission profiles to actual sandbox enforcement and add user approval prompts for executing binaries/scripts from skill directories.

Example

openai.yaml snippet:

  permissions:
    network: true
    fs_read:
      - "./data"
      - "./data"
    fs_write:
      - "./output"
    macos_preferences: "readwrite"
    macos_automation:
      - "com.apple.Notes"
    macos_accessibility: true
    macos_calendar: true

compiled skill permission profile metadata (macOS):

SkillPermissionProfile {
      sandbox_policy: SandboxPolicy::WorkspaceWrite {
          writable_roots: vec![
              AbsolutePathBuf::try_from("/ABS/PATH/TO/SKILL/output").unwrap(),
          ],
          read_only_access: ReadOnlyAccess::Restricted {
              include_platform_defaults: true,
              readable_roots: vec![
                  AbsolutePathBuf::try_from("/ABS/PATH/TO/SKILL/data").unwrap(),
              ],
          },
          network_access: true,
          exclude_tmpdir_env_var: false,
          exclude_slash_tmp: false,
      },
      // Truncated for readability; actual generated profile is longer.
      macos_seatbelt_permission_file: r#"
  (allow user-preference-write)
  (allow appleevent-send
      (appleevent-destination "com.apple.Notes"))
  (allow mach-lookup (global-name "com.apple.axserver"))
  (allow mach-lookup (global-name "com.apple.CalendarAgent"))
  ...
  "#.to_string(),

Comment thread codex-rs/core/src/skills/permissions.rs Resolved
@celia-oai celia-oai changed the title changes feat(skills): add permission profiles from openai.yaml metadata Feb 13, 2026
@celia-oai
celia-oai marked this pull request as ready for review February 13, 2026 00:52
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch from d820f6d to e32ed32 Compare February 13, 2026 01:02
@celia-oai
celia-oai requested review from viyatb-oai and removed request for bolinfest February 13, 2026 01:47
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch 7 times, most recently from a828b6e to 8a19a7b Compare February 13, 2026 03:02
Comment thread codex-rs/core/src/skills/permissions.rs Resolved
Comment thread codex-rs/core/src/skills/permissions.rs Resolved
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch 5 times, most recently from d7d3432 to 7ba60dc Compare February 13, 2026 22:50
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch from 7ba60dc to e94cead Compare February 13, 2026 22:51
Comment thread codex-rs/core/src/skills/model.rs Resolved
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch from b44d650 to 417c38e Compare February 13, 2026 23:18
Comment thread codex-rs/core/src/skills/model.rs Resolved
@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch from f7504bb to 5d0fe77 Compare February 14, 2026 00:20

@viyatb-oai viyatb-oai left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lets add a test to cover network-only and network + read-only behavior for regression

@celia-oai
celia-oai force-pushed the dev/cc/skill-permission branch from 5d0fe77 to a48a3cd Compare February 14, 2026 00:27
@celia-oai
celia-oai enabled auto-merge (squash) February 14, 2026 00:37
@celia-oai
celia-oai merged commit 5b6911c into main Feb 14, 2026
74 of 78 checks passed
@celia-oai
celia-oai deleted the dev/cc/skill-permission branch February 14, 2026 01:43
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 14, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants