Security

Attackers inject shardcode into thousands of GitHub repositories

Unknown actors are abusing stolen tokens to inject malicious scripts into GitHub repositories, targeting AI service credentials. The campaign does not exploit a platform vulnerability but leverages compromised write permissions to harvest secrets.

· 1 source · Credential theft

Since Tuesday, unknown attackers have injected shardcode into thousands of GitHub repositories. The operation does not exploit a vulnerability in GitHub-Actions; instead, it abuses write permissions derived from stolen tokens. The origin of these tokens remains unclear, but the injected scripts specifically target credentials for AI services such as OpenAI, Anthropic, and Cursor. The malware also harvests secrets from GitHub-Actions and steals credentials for cloud services and container environments.

This method allows attackers to access repositories that do not belong to the compromised accounts, potentially affecting organizations whose own credentials were not directly stolen. Heise Developer compiled detailed information on the incident. Security experts advise developers to check if their accounts have been compromised. The attackers appear to be leveraging the widespread integration of AI tools into development workflows to expand their reach beyond the initial compromised accounts.