@redhat-cloud-services npm scope backdoored with valid signed SLSA provenance; recovered the GitHub commit-search dead-drop C2 markers
Source Reddit BlueTeam
Discussion
On June 1, 2026, multiple npm packages within the @redhat-cloud-services scope were republished with a malicious install-time payload that re-armed repeatedly despite registry purges. The attacker exploited GitHub Actions workflows to produce valid signed SLSA provenance and npm audit signatures, bypassing typical trust mechanisms. The malware uses a GitHub commit-search based command-and-control (C2) dead-drop, avoiding hardcoded hosts. It activates only in CI environments and quickly attempts to steal credentials such as AWS, SSH, Git, and Docker config files. Detection is possible by monitoring package integrity and behavioral checks at publish time. No official patch or remediation guidance is provided in the source data.
r/blueteamsec (opens in a new tab)u/quantumsicarius0 points0 comments
On 1 Jun 2026, 31 packages across the redhat-cloud-services npm scope were republished with an install-time malware payload, and it kept re-arming: at least 4 bursts in one afternoon as the registry purged each batch, version numbers climbing each time. What makes it notable for defenders:
Valid, signed provenance
Every malicious version carries valid SLSA provenance and passes npm audit signatures. npm trusted publishing authorizes on (repository + workflow file path), so the attacker pushed a throwaway branch carrying a workflow named release.yml set to run on any push with id-token: write. GitHub Actions ran it in the repo's context, npm minted a real publish token AND a real attestation, then the branch was deleted. main was never touched. The scope publishes from more than one RedHatInsights repo (clients from javascript-clients, the MCP servers from platform-frontend-ai-toolkit), so more than one CI pipeline was abused. Provenance proves where a build came from, not what it does.
IOCs (from a sandbox detonation)
C2 is a GitHub commit-search dead-drop, no hardcoded host. The implant queries api.github.com/search/commits for marker strings to locate its drop point: - thebeautifulmarchoftime - IfYouInvalidateThisTokenItWillNukeTheComputerOfTheOwner - User-Agent: python-requests/2.31.0
Searchable in GitHub commit search / audit logs, and the drop-point commits can be purged. (Not in the public writeups yet; contributed to the issue below.)
Behavior: - Env-gated: only fires when CI / GITHUB_ACTIONS are set (dormant in a bare sandbox), which is why a lot of dynamic analysis misses it. - Credential reads within ms of install: ~/.aws/credentials, ~/.ssh/id_rsa, ~/.git-credentials, ~/.docker/config.json. - All egress DNS-resolved, no hardcoded-IP C2, no cloud metadata probe in our run.
Detection
- Pin to integrity (lockfile) and expect re-arming:
latestwas malicious far more often than not across the afternoon. - A kernel agent that returns
-EPERMon credential-file reads kills the job before the C2 fires. - Behavioral checks at publish time catch this regardless of how clean the provenance looks.
Sources
- StepSecurity, original report + writeup: https://github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57 and https://www.stepsecurity.io/blog/multiple-redhat-cloud-services-npm-packages-compromised
- SafeDep, the OIDC/SLSA provenance-abuse technique (AntV wave): https://safedep.io/mini-shai-hulud-strikes-again-314-npm-packages-compromised/
- Recovered C2 markers contributed to the RedHatInsights issue: https://github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57#issuecomment-4594221102
- Full first-hand method (detonation, provenance anatomy, checksums): https://leitwacht.eu/blog/valid-provenance-malicious-package
Disclosure: I founded Leitwacht; the agent referenced is our open-source CE binary.
Links cited in the discussion
- https://github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57
- https://www.stepsecurity.io/blog/multiple-redhat-cloud-services-npm-packages-compromised
- https://safedep.io/mini-shai-hulud-strikes-again-314-npm-packages-compromised/
- https://github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57#issuecomment-4594221102
- https://leitwacht.eu/blog/valid-provenance-malicious-package
References
- github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57 (opens in a new tab)
- reddit.com/r/blueteamsec/comments/1ttx39v/redhatcloudservices_npm_scope_backdoored_with/ (opens in a new tab)
- stepsecurity.io/blog/multiple-redhat-cloud-services-npm-packages-compromised (opens in a new tab)
- safedep.io/mini-shai-hulud-strikes-again-314-npm-packages-compromised/ (opens in a new tab)
- github.com/RedHatInsights/platform-frontend-ai-toolkit/issues/57 (opens in a new tab)
- leitwacht.eu/blog/valid-provenance-malicious-package (opens in a new tab)