Skip to main content
Mallory
← Back to News
ai-platform-securityendpoint-software-vulnerabilitywidely-deployed-product-advisoryinitial-access-method

OpenAI Codex CLI Command Injection Vulnerability

Emerging Technology Risk · 3 sources · Updated 5mo ago · First seen Dec 3, 2025

OpenAI Codex CLI Command Injection Vulnerability

OpenAI addressed a critical command-injection vulnerability in its Codex CLI tool that allowed attackers to execute arbitrary commands on developer machines by hiding malicious configuration files within code repositories. The flaw, disclosed by Check Point and patched in Codex CLI version 0.23.0, exploited the way the tool automatically loaded and executed MCP server entries from project-local configuration files. If a repository contained a file that redirected the configuration directory and included a malicious MCP server command, Codex CLI would execute those commands as soon as a developer ran the Codex command, potentially compromising the system.

This vulnerability turned routine developer workflows into attack vectors, as simply running Codex CLI in a tampered repository could result in the execution of hidden commands without the user's knowledge. OpenAI released a fix for the issue after being notified by Check Point, mitigating the risk of attackers hijacking developer machines through this vector. Security teams are advised to ensure all Codex CLI installations are updated to the latest version and to review repository sources before running AI-powered development tools.

Why it matters

Impact assessment

CVE-2025-61260 affects organizations using OpenAI Codex CLI in developer workstations, engineering laptops, CI runners, and build agents. The impact is severe because a malicious repository or accepted pull request could trigger arbitrary command execution during normal developer workflows, exposing source code, SSH keys, cloud credentials, and potentially contaminating downstream build and deployment pipelines.

The exposure is broad across software development environments that use Codex CLI, but exploitation requires repository write access, pull request acceptance, or another path to place malicious project files in a trusted codebase. The story describes researcher-demonstrated exploitation, including reverse shell payloads and persistence mechanisms, but does not provide confirmed in-the-wild exploitation.

Supporting facts

  • Affected product: OpenAI Codex CLI.
  • Fixed version: 0.23.0.
  • Affected users: developers, DevOps teams, CI/CD operators, and organizations using AI-assisted coding workflows.
  • Primary impact: arbitrary command execution on developer machines.
  • Secondary impact: theft of cloud credentials, SSH keys, and source code.
  • Supply chain risk: compromised repositories or templates could propagate malicious behavior to downstream consumers.
  • Operational risk: CI systems or build agents running Codex could embed compromise into build artifacts or production deployments.
  • Exploitation status: proof-of-concept exploitation was demonstrated by Check Point; no confirmed active exploitation is stated in the references.
  • Relevant entities: OpenAI, Check Point Research, Noma Security, Bugcrowd.
  • Similar ecosystem concerns noted: Cursor and Google's Antigravity IDE were cited as having comparable security patterns or issues.
New surface, new adversariesTrack how attackers are adapting to this technology.
Track this risk
Event timeline

How this story unfolded

Events from the most recent confirmed update back to the earliest known activity.

3 events · Dec 3, 2025
  1. Dec 3, 20251y ago

    OpenAI patches Codex CLI in version 0.23.0

    OpenAI fixed the vulnerability in Codex CLI version 0.23.0 after disclosure by Check Point. The patch blocked project-local redirection of CODEX_HOME and addressed unvalidated execution of local MCP server entries.

  2. Dec 3, 20251y ago

    Researchers detail repository-based exploitation path

    Technical analysis showed attackers with repository write access or pull request capability could abuse .env files and project-local MCP server entries to redirect CODEX_HOME, load rogue configuration, and execute hidden commands during normal developer workflows. The issue created supply chain risk for downstream users and CI/CD environments.

  3. Dec 3, 20251y ago

    Check Point discovers RCE flaw in OpenAI Codex CLI

    Check Point researchers identified a critical command-injection/remote code execution vulnerability in OpenAI's Codex CLI, tracked as CVE-2025-61260. The flaw allowed malicious repository files and configuration redirection to trigger arbitrary command execution on developer machines.

Linked entities

Related entities

Vulnerabilities, threat actors, malware, products, organizations, and breaches Mallory has linked to this story.

Open in app →

Organizations

1 linked
Openai
Do you run this?Follow how adversaries are adapting to this technology, and where it touches your stack today.
Track This Risk
Mallory platform

See the full picture, correlated to your attack surface.

This page covers what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which threat actors are using it right now, and what to deploy next.

Exposure mappingMap indicators from this story to your assets and identify affected systems in minutes.
Threat actor evidenceEvery observed campaign, victim, and pivot linked to actors named in this story.
Associated malwareMalware, exploits, and IOCs connected to the activity described here.
Detection signaturesYARA, Sigma, and Snort rules deployed to your SIEM as soon as they’re published.
Scheduled alertsGet matching new stories delivered to your team as they break, not the next morning.
AI threadsAsk questions about this story and take action on the answers.