Cyber Security News

OpenAI Open-Sources Codex Security CLI to Find, Validate, and Fix Code Vulnerabilities

OpenAI has open-sourced Codex Security, a command-line interface and TypeScript SDK designed to help engineering and security teams identify, validate, and remediate vulnerabilities across code repositories.

The project is published under the Apache-2.0 license. It supports various features, including repository-wide assessments, targeted path reviews, pull-request diff scanning, scan history, CI integration, and structured output for security automation.

OpenAI Open-Sources Codex Security CLI

Codex Security positions AI-assisted code review as a repeatable application security workflow rather than a one-time prompt. Developers can install the package via npm, authenticate with a ChatGPT account for interactive use, and initiate a scan against a local repository.

For automated environments, organizations can provide an OPENAI_API_KEY, allowing them to integrate the scanner into CI/CD pipelines without the need for interactive sign-in.

The CLI currently requires Node.js version 22 or newer, while scanning and export capabilities also require Python version 3.10 or later.

To get started, you can use the following commands:

npm install @openai/codex-security
npx codex-security login
npx codex-security scan

The scanner is designed for assessing repositories that users own or are authorized to test. Before assessing with Codex, users can run a dry check to validate the repository path and intended result directory without loading credentials or initiating a model-backed scan.

This feature is helpful for secure pipeline testing and preventing accidental writes into a source tree.

Here’s how you can run a dry check and a full scan:

REPOSITORY=/path/to/repository
SCAN_DIR=/path/outside/repository/codex-security-results
npx codex-security scan "$REPOSITORY" \
  --output-dir "$SCAN_DIR" \
  --dry-run
npx codex-security scan "$REPOSITORY" \
  --output-dir "$SCAN_DIR"

Completed scans generate a human-readable `report.md`, along with machine-consumable artifacts such as `findings.json`, `coverage.json`, and a scan manifest. Findings include severity, confidence levels, affected locations, supporting evidence, and remediation guidance.

Coverage data records reviewed areas, exclusions, deferred work, and open questions. OpenAI advises that coverage should be examined carefully before interpreting a scan as complete assurance, as it may be marked as complete, partial, or unknown.

Codex Security also supports change-focused reviews, allowing teams to inspect code differences between a base revision and HEAD, or assess staged and unstaged working-tree modifications before committing them.

A deep scanning mode is available for more extensive analysis, and architecture documentation, threat models, and security policies can be attached as context to enhance the relevance of findings.

Here are some additional commands for different analyses:

# Review a pull request or branch diff
npx codex-security scan "$REPOSITORY" \
  --diff origin/main \
  --head HEAD
# Scan current working-tree changes
npx codex-security scan "$REPOSITORY" \
  --working-tree \
  --base HEAD
# Add security context and apply a cost ceiling
npx codex-security scan "$REPOSITORY" \
  --mode deep \
  --knowledge-base /path/to/threat-model.md \
  --knowledge-base /path/to/security-policy \
  --max-cost 5

For developer workflows, the project can install a pre-commit security hook that scans local changes and blocks commits when high-severity findings or scan errors are present.

It can also scan multiple repositories through GitHub discovery or by using a CSV inventory pinned to specific Git revisions, enabling security teams to conduct repeatable campaigns across their organization’s codebase.

The accompanying TypeScript SDK allows for programmatic integrations with internal tools, security portals, and custom automation. Both the CLI and SDK are currently in beta and require access.

However, the public repository’s release indicates that OpenAI is preparing for stable npm publishing and enhanced release safeguards.

ALERT: 20+ government sites delivered malware to businesses and citizens. See full attack research to check your own exposure.

Divya

Divya is a Senior Journalist at GBhackers covering Cyber Attacks, Threats, Breaches, Vulnerabilities and other happenings in the cyber world.

Recent Posts

New GhostMap Android Vulnerability Can Crash Phones Permanently Without Opening an App or Granting Permissions

Bitdefender researchers have revealed a vulnerability called GhostMap that affects Android devices. This vulnerability can…

6 minutes ago

Microsoft Paint Vulnerability Allows Hackers to Execute Malicious Code Remotely Without User Interaction

Microsoft has announced a vulnerability in Windows Paint that could let unauthenticated attackers execute malicious…

29 minutes ago

ARTEX AI Framework Linked to Bank Breaches and Cloud Attacks Found Exposed Across Hundreds of Servers

An autonomous penetration-testing framework linked to South Korean banking breaches and cloud supply-chain attacks is…

59 minutes ago

Shopify Makes IP Allowlisting Mandatory for All Public Apps to Prevent Stolen API Token Abuse

Shopify is making IP allowlisting mandatory for all public apps to limit abuse of stolen…

1 hour ago

OpenAI’s New GPT-6 Cyber Finds 81 High-Severity Firefox Vulnerabilities and 948 Linux Kernel Exploits

OpenAI has introduced GPT-6 Cyber, a security-focused model built to find and validate exploitable vulnerabilities…

1 hour ago

OpenMatter Network Positions Decentralized Computing as an Alternative to Data Centers for AI

Melbourne, Florida, November 5th, 2026, CyberNewswire OpenMatter Network, a pioneer in decentralized infrastructure for agentic…

13 hours ago