Hackerbot-Claw Exploited GitHub Actions in Campaign That Took Over Trivy Repository

· Original article ↗

Summary

Step Security says hackerbot-claw exploited GitHub Actions workflows at seven repositories through untrusted pull-request code and shell, branch-name and AI prompt injection. It reports stolen Trivy credentials enabled a repository takeover and malicious VS CodeS

Key points

  • Step Security says the campaign ran from Feb. 21 to Mar. 2, 2026, targeting at least seven public repositories through pull requests and workflow triggers.
  • Techniques included untrusted fork checkouts in pull_request_target workflows, Go init() payloads, direct script injection, and shell injection through filenames and branch names.
  • The article reports that workflow logs confirmed code execution and GITHUB_TOKEN exfiltration from avelino/awesome-go; the payload contacted hackmoltrepeat[.]com and sent the token to recv[.]hackmoltrepeat[.]com.
  • According to Aqua Security's incident disclosure as summarized in the article, a stolen Trivy PAT was used to privatize and rename the repository, delete releases, and push a suspicious VS Code extension artifact. The repository was restored, while release and download functionality was still being restored.
  • Claude Code detected and refused two poisoned CLAUDE.md prompt-injection attempts. In the RustPython attack, branch-name injection reached command substitution, but base64 decoding failed and the full payload did not execute.
  • DataDog deployed workflow fixes within about nine hours, including author checks, safer expression handling, and read-only permissions. The article also recommends avoiding privileged workflows that execute untrusted fork code and restricting token permissions and runner network access.

Article Details

Attack Vectors
  • A pull_request_target workflow checked out and executed untrusted fork code with repository secrets or elevated permissions, enabling malicious Go init() code and a Trivy workflow payload to run.
  • An attacker injected a curl-to-bash payload directly into project-akri/akri's version.sh, which a comment-triggered workflow ran from fork code.
  • Unsanitized attacker-controlled branch names and filenames were interpolated into shell commands, causing command substitution in GitHub Actions workflows.
  • A poisoned CLAUDE.md file attempted to manipulate an AI code reviewer into making unauthorized changes; the reviewer detected and refused the instructions.
  • A stolen Trivy Personal Access Token was used to push a commit, take over the repository, delete releases, and publish a suspicious VS Code extension artifact.
Defensive Notes
  • Avoid combining pull_request_target with checking out or executing untrusted fork code; use pull_request where appropriate and restrict workflow permissions.
  • Pass GitHub expression values through environment variables and safely handle attacker-controlled branch names, filenames, and other shell inputs.
  • Require authorization checks such as author_association gates for comment-triggered workflows.
  • Apply least-privilege token permissions, using contents: read where write access is unnecessary, and limit access to secrets.
  • Restrict AI-review workflows to necessary tools and permissions; avoid allowing all non-write users to trigger workflows with write access.
  • Require maintainer review of CLAUDE.md through CODEOWNERS and validate the file against an expected schema in CI.
  • Monitor and restrict CI runner outbound network traffic with an egress allowlist to block unauthorized payload downloads and token exfiltration.
  • Remove vulnerable workflows, revoke exposed credentials, remove suspicious extension artifacts, and restore or republish affected releases.

Indicators of compromise

TypeIndicatorContext
DOMAINhackmoltrepeat[.]comAttacker-controlled payload-hosting domain used to deliver shell scripts to compromised CI runners.
DOMAINrecv[.]hackmoltrepeat[.]comAttacker-controlled endpoint used to exfiltrate the GITHUB_TOKEN from a CI runner.
URLhxxps[:]//hackmoltrepeat[.]com/moltMalicious payload URL repeatedly downloaded and piped to bash in the campaign.
URLhxxps[:]//hackmoltrepeat[.]com/moultMalicious payload URL embedded in the RustPython branch-name injection attempt.

MITRE ATT&CK

People

Vendors

Products

Tools

Related Articles