Return to Threats

Packagist Supply Chain Attack Infects 8 Packages Using GitHub-Hosted Linux Malware

thehackernews.com 2026-05-23 AI supply chain High

What Happened

A new "coordinated" supply chain attack campaign has impacted eight packages on Packagist including malicious code designed to run a Linux binary retrieved from a GitHub Releases URL. "Although the affected packages were all Composer packages, the malicious code was not added to composer.json," Socket said. "Instead, it was inserted into package.json, targeting projects that ship JavaScript

Why It Matters

The report describes a coordinated supply chain attack on eight Packagist (Composer) packages, where attackers modified upstream repositories to add a postinstall script that downloads and executes a Linux binary from a GitHub Releases URL, storing it as /tmp/.sshd and running it in the background.[1] The malicious code was inserted into package.json rather than composer.json, targeting projects that bundle JavaScript build tooling alongside PHP code, and similar payloads were found across hundreds of GitHub files and even GitHub Actions workflows.[1] From a CyberSE.AI perspective, this highlights that AI-enabled or AI-adjacent applications built on common web stacks (PHP/JS) are exposed to the same software supply chain risks, and any AI agents or services built on these ecosystems require rigorous dependency vetting, SBOM generation, and CI/CD controls. Organizations should integrate supply chain scanning, lockfile and integrity enforcement, and GitHub/GitLab workflow hardening into their AI development lifecycle, treating build-time scripts and installer hooks as high-risk execution paths.

Healthcare Fintech SaaS SMB AI startups

CyberSE Analysis

This signal maps to AI supply chain. Organizations using AI agents, LLM APIs, SaaS integrations, or sensitive data workflows should review whether this class of issue could create unauthorized tool execution, data leakage, weak approval gates, or unmanaged supply-chain exposure.

Recommended Actions

  • Restrict AI agent tool permissions and production write paths.
  • Review sensitive data access across prompts, logs, embeddings, memory, and SaaS integrations.
  • Add human approval workflows for high-impact or state-changing actions.
  • Run prompt injection and indirect prompt injection tests against affected workflows.
  • Document the owner, control gap, and remediation deadline for this risk class.

Source

https://thehackernews.com/2026/05/packagist-supply-chain-attack-infects-8.html

Talk to AI CISO