Skip to content
Back to skills

Configuring Codex

ASecurity

Use when setting up or debugging Codex hooks, plugins, skills, config layers, or managed requirements. Triggers on `hooks.json`, `config.toml`, `requirements.toml`, SessionStart, PreToolUse, PermissionRequest, SubagentStart, Stop, plugin-bundled hooks, hook trust hashes, or Codex guardrails, even when the user doesn't say 'Codex hook'.

  • 6 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added November 30, 2026
ai-agentsrustgoshellbashrailsdebugging

Works with

  • mcp

Security analysis

A100/100

Pro scans all 8 files and shows the line behind each finding

Scanned November 30, 2026

npx -y skills add xonovex/platform --skill configuring-codex --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Configuring Codex?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Configuring Codex
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/xonovex-configuring-codex/badge)](https://www.skillsdirectory.com/skills/xonovex-configuring-codex)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: configuring-codex
description: "Use when setting up or debugging Codex hooks, plugins, skills, config layers, or managed requirements. Triggers on `hooks.json`, `config.toml`, `requirements.toml`, SessionStart, PreToolUse, PermissionRequest, SubagentStart, Stop, plugin-bundled hooks, hook trust hashes, or Codex guardrails, even when the user doesn't say 'Codex hook'."
---

# Codex Hooks and Guardrails

Configure Codex's native hooks and guardrails without inventing unsupported guarantees or a universal hook file.

## Essentials

- **Probe the release** - Record `codex --version` or an explicit not-installed result with the matrix snapshot.
- **Use command handlers** - Only documented executing handler types can satisfy a capability.
- **Reject parsed-only support** - Prompt, agent, and asynchronous command handlers are not executing release behavior in this snapshot.
- **Scope the guardrail** - `PreToolUse` covers shell and unified exec, patch/edit/write, MCP, and most local function tools; hosted and specialized opt-out paths remain outside the guarantee.
- **Preserve trust layers** - Non-managed definitions are hash-reviewed; managed hooks require separately distributed scripts.
- **Transact native config** - Preview hooks.json, config.toml, plugin, or requirements changes; lifecycle owned by **configuring-harness-integrations**.

## Gotchas

- Only `type: command` executes in the documented snapshot; prompt and agent handlers are parsed but skipped.
- The async option is parsed but asynchronous command hooks are skipped.
- `PreToolUse` is a partial guardrail because hosted tools and specialized paths that opt out of the local function-tool hook path are not intercepted.
- Matching command hooks start concurrently, so a denial cannot prevent another matching hook from starting.
- `SubagentStart` can add context, but `continue: false` does not stop the subagent from starting.

## Example

Codex `PreToolUse` alone cannot block every privileged operation. Match covered shell/unified-exec calls as `Bash`, patch calls as `apply_patch`, `Edit`, or `Write`, MCP calls by their tool name, and other covered local function tools by function name. State that hosted tools and specialized opt-out paths remain uncovered.

## Progressive Disclosure

- Read [references/capabilities.md](references/capabilities.md) - Load when mapping semantic intents to native events, handlers, guarantees, versions, ordering, context, or limitations
- Read [references/onboarding.md](references/onboarding.md) - Load when discovering, previewing, applying, verifying, disabling, rolling back, updating, or detecting drift
- Read [references/patterns.md](references/patterns.md) - Load when translating deterministic hooks, model evaluators, specialist agents, or managed adoption recipes

Files in this skill

  • SKILL.md2.7 KB
  • eval-output.json1.9 KB
  • eval-trigger.json5.5 KB
  • moon.yml86 B
  • references/capabilities.md3.1 KB
  • references/onboarding.md1.7 KB
  • references/patterns.md1.1 KB
  • sources.json3.2 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.