Popular OpenAI Codex tool with 29,000 weekly downloads exposed in npm supply chain attack

4 Sources

Share

A malicious npm package posing as a remote UI for OpenAI Codex quietly exfiltrated developer authentication tokens for a month, attracting 29,000 weekly downloads. The same credential-theft chain ran through two Android apps with over 60,000 combined downloads. The attack highlights how threat actors can hide malicious code in npm builds while keeping GitHub repositories clean, exposing critical vulnerabilities in AI developer tooling.

Malicious npm Package Targets OpenAI Codex Developers

A sophisticated supply chain attack targeting OpenAI Codex users has exposed critical vulnerabilities in AI developer tooling, with a malicious npm package called codexui-android silently stealing authentication tokens from approximately 29,000 weekly downloads for over a month

1

. Unlike typical attacks relying on typosquatting or disposable packages, this campaign used a functional tool under active development, making detection significantly more challenging for developers who rely on these AI developer tools

3

.

Source: InfoWorld

Source: InfoWorld

What makes this supply chain attack particularly dangerous is the divergence between the public GitHub repository, which remained clean throughout the campaign, and the npm build that contained the malicious code

2

. Researchers at Aikido Security discovered that the package extracted contents from Codex's "~/.codex/auth.json" file and sent them to an attacker-controlled server masquerading as Sentry, a legitimate error tracking platform.

Stolen Authentication Tokens Enable Persistent Access to Victims' Accounts

The exfiltrated data included critical credentials: access_token, refresh tokens, id_token, and account ID

2

. According to Aikido Security researcher Charlie Eriksen, the refresh_token poses the most severe threat because it doesn't expire, granting attackers persistent access to victims' accounts indefinitely

4

. This means stolen OpenAI Codex credentials go far beyond simple chat interface access, enabling attackers to spend victims' API credits, view projects or code being developed through Codex, and impersonate developers when interacting with OpenAI services.

The nefarious changes were introduced approximately a month after the package was first published to the registry, likely a deliberate strategy to build user trust and expand reach before deploying the payload

2

. The npm account associated with the package belongs to "friuns," identified as Igor Levochkin, whose X profile links to the same domain used for the credential-theft chain.

Source: Hacker News

Source: Hacker News

Android Apps Expand Attack Surface Beyond npm

The credential-theft chain extended beyond npm to mobile platforms, with two Android apps published by developer "BrutalStrike" running the same malicious code

3

. The first app, OpenClaw Codex Claude AI Agent, accumulated over 50,000 downloads on Google Play, while a second app simply called Codex had more than 10,000 downloads

2

. Both Android apps ran the npm package within a PRoot sandbox, extracting developer authentication tokens and sending them to the same attacker-controlled server at sentry.anyclaw[.]store.

Source: TechRadar

Source: TechRadar

Because neither app pinned a specific package version, they automatically pulled whatever was currently published on npm, meaning the malicious code was delivered to mobile users the moment it went live

3

. The combined attack surface of roughly 29,000 weekly npm downloads plus more than 60,000 mobile installations makes this one of the more significant campaigns targeting AI developer tooling ecosystems.

AI Software Supply Chain Risks Escalate as Attacks Grow More Sophisticated

This incident underscores growing AI software supply chain risks as threat actors increasingly target real artificial intelligence developer workflows to steal credentials and burrow deeper into software infrastructure

2

. WHOIS records reveal that the exfiltration domain was registered on April 12, 2026, just two days after the first version of the npm package was uploaded, suggesting premeditated planning

3

.

When confronted on GitHub, the package author initially claimed to have lost access to their npm account, then edited the response to state they were "currently investigating this issue internally" and removing affected functionality

2

. However, the author failed to explain why exfiltration code was inserted only into the npm build or why access to users' Codex tokens was needed. OpenAI's own documentation warns developers to treat ~/.codex/auth.json like a password, advising against committing it or sharing it in communications, yet the plaintext storage of these credentials creates exploitable vulnerabilities when tools developers trust are designed to exploit that trust

3

.

Developers should watch for similar discrepancies between public repositories and published packages, implement stricter verification processes for dependencies, and monitor for unauthorized access using stolen credentials. The challenge of credential revocation adds another layer of concern, as Aikido separately reported that deleted Google API keys remain live for up to 23 minutes, providing attackers windows to exploit leaked credentials even after revocation attempts

2

.

Today's Top Stories

© 2026 TheOutpost.AI All rights reserved