Poisoned Pipeline

Poisoned Pipeline / Incidents / AS74

AS74 · 2025-08

Nx s1ngularity (stolen npm token via Actions injection)

npmGitHub ActionsAI coding agentsCI/CD SaaSGit / GitHubDeveloper workstation

On 26 August 2025 attackers published malicious versions of nx and
several @nx/* packages for about four hours. Nx’s post-mortem: a
pull_request_target workflow echoed unsanitized PR titles, repository
Actions permissions were still read/write, and publish.yml allowed
workflow_dispatch. That let an external PR steal a GitHub token, plant
a branch, trigger publish, and exfiltrate NPM_TOKEN. Stolen token
bypassed CI; packages lacked npm provenance. postinstall scanned the
host, tried local AI CLIs, and uploaded loot to public GitHub repos via
gh. ~6M weekly installs. Primary: nx.dev post-mortem and GHSA-cxm3-wv7p-598c.

Mapped techniques

supply-chain actions injection to stolen npm token

T0118 · Execution · Command injection

Unsanitized PR title in a pull_request_target workflow.

T0202 · Persistence · Inadequate CI/CD workflow permissions

Repo still on GitHub’s old read/write Actions default.

T0166 · Execution · Trigger pipeline execution

workflow_dispatch used via API to run publish.yml on a planted branch.

T0140 · Credential Access · Harvest tokens from environment variables

NPM_TOKEN stolen from the publish job.

T0121 · Resource Development · Compromised legitimate artifact

nx 20.9–21.8 and matching @nx/* versions, no provenance.

T0206 · Defense Evasion · Forge or omit build provenance

Detection clue — malicious publishes were unsigned.

T0151 · Execution · Installation scripts

postinstall scanned the host and invoked local AI tools.

T0168 · Exfiltration · Exfiltration to code repositories

Loot uploaded to public GitHub repos via GitHub CLI.

Sources