Developer tools#Security scan#Code review
Codex Security CLI: find, validate and patch vulnerabilities in one pipeline
Codex Security is an OpenAI open-source CLI and SDK that chains vulnerability discovery, validation and patching, with SARIF export and a GitHub Action for CI.
Project facts
GitHub Ecosystem- License
- Apache-2.0
- Language
- TypeScript
- Stars
- 13,539
- Data checked
- 2026-11-15
Snapshot figures reflect the check date and may change over time.
Most SAST tools hand you a queue of alerts and leave the triage to you. Codex Security, which OpenAI open-sourced in late July 2026 under Apache-2.0, is a TypeScript CLI and SDK that runs discovery, validation and fixing as one pipeline: a single cs scan . command ends in a Markdown report, and from there the model can pressure-test candidate findings, draft patches, and re-check fixes that already landed. As of November 15, 2026 the repo sits at about 13.5k stars, and v0.10.0 shipped on November 12.

Core features
- Three scan scopes:
cs scan .covers the whole repo,--path src --path testsnarrows it to selected directories, and--diff origin/mainreviews only the commits between a base revision and HEAD.--mode deeprepeats the standard scan and deduplicates the findings.--max-time 15sets an advisory 15-minute investigation allowance on a standard scan. The open-sourced implementation runs a scan in phases — threat modeling, discovery, validation, impact analysis, reporting, hardening — and writes structured artifacts such asscan-manifest.json,findings.jsonandcoverage.json. - Resumable scans: since v0.10.0,
codex-security scans resume SCAN_IDcontinues an interrupted standard scan from its checkpoint with usage and budget intact, and bulk or component scans take--max-total-costso a group of repositories shares one estimated budget (in-flight work can exceed the estimate). - Validation and patches: after a scan, the model can validate whether a candidate finding is actually exploitable, generate a patch, and verify an existing fix. Per the project’s own docs, hosted patch verification runs in a controlled environment, and since v0.10.0 a patch that ends on a different commit reports
revision_changedand keeps its execution receipt. We have not independently tested this mechanism; treat the details as the vendor’s description. - Getting results where work happens: findings export to SARIF, JSON and CSV, or sync to Linear, Jira and GitHub. Third-party scanner reports — Semgrep, Snyk, ArmorCode — can be imported into the local workbench for triage.
- Policy and threat models:
cs policydrafts aSECURITY.mdplus a threat model outside the repo for human review, and scans read root and componentSECURITY.mdfiles as context. - Model backends beyond OpenAI: Amazon Bedrock, OpenRouter, Fireworks AI and others are supported; Bedrock uses plain AWS credentials and needs no OpenAI login.
- SDK and CI: the
@openai/codex-securityTypeScript SDK embeds scans in your own tooling, and the official GitHub Action example runs a scheduled weekly scan with a $5 estimated limit per scan, reporting findings without failing the build.
Typical use cases
- Security engineers triaging a backlog: run accumulated scanner alerts through a validation round, rate them against your own rubric, and only then decide what deserves a human’s afternoon.
- Incremental checks in CI: use
--diff origin/mainon pull requests and a scheduled job for full scans; bulk scans can share one budget across repositories with--max-total-cost. - Open-source maintainers: OpenAI confirmed on Hacker News that maintainers can apply for conditional access through the Codex for OSS form to offset the model cost.
Quick start
The install comes from the project README; you need Node.js 22.13.0+ within 22.x, or 24.x / 26.x, plus Python 3.10+:
npm install --global @openai/codex-security
cs login
cs scan .
When the scan finishes, the terminal prints a REPORT path to a Markdown file with source evidence and coverage limits; cs scans show finds the latest completed scan again. If npm reports an EEXIST conflict, run npx @openai/codex-security in place of cs. In CI, set OPENAI_API_KEY or CODEX_API_KEY and the scan runs headless.
Summary
Codex Security fits teams that want AI-driven vulnerability review inside CI and daily development and can accept sending code to a cloud model. The honest catches are cost and access: on the Hacker News launch thread, users reported single scans consuming up to half a Pro plan’s weekly usage, one interrupted scan billed about $13, model guardrails occasionally refusing to explain a vulnerability the tool itself found, and the sharper capabilities gated behind Trusted Access for Cyber or Daybreak. Local models are not supported, so code always leaves the machine. There is deliberately no rule-level SAST report — OpenAI explained why in a separate post. Apache-2.0, written in TypeScript, v0.10.0 released November 12, 2026, actively maintained (last push November 14). If you’d rather bolt security skills onto an agent yourself, see our reverse-skill entry; for a plain toolbox of scanners, hackingtool remains the kitchen sink.