A seemingly benign Ruby package, dubbed strutil-core, turned out to be a dangerous credential-stealing agent. This malicious software activates a worm as soon as it is installed by developers, posing significant risks to credentials and security.
Immediate Threat to Developers
The strutil-core gem was designed to appear as a text manipulation tool but was, in fact, a vehicle for credential theft and the installation of backdoors in AI coding tools. If users attempted to revoke a stolen GitHub token, the gem could potentially erase the user’s home folder. Although it was available on RubyGems for just five hours, its existence highlights how attackers are increasingly targeting developers’ work environments.
Rapid Deployment and Payload Details
Version 1.0.0 of the gem was released on November 1, 2026, by an account identified as jamnajiea, initially appearing harmless. However, a subsequent update, version 1.0.1, introduced a substantial payload of 5.48 MB that accessed 51 different credential stores, including AWS and Docker.
Security researchers at Socket.dev noted that their AI scanner flagged the malicious file within 70 seconds of its publication. Despite the swift identification, there were no known projects reliant on the gem, and RubyGems promptly removed the affected versions.
Advanced Techniques and Wider Implications
The malicious gem employed a native extension script, extconf.rb, which activated during installation, thereby bypassing the need for the gem to be loaded into applications. Once active, the script downloaded additional harmful components and executed them quietly.
The worm sought sensitive information like cloud keys, SSH keys, and password manager data. It used AWS keys to access Secrets Manager across multiple regions, with stolen data being encrypted and sent to a remote server. The payload also tampered with security agents, although these attempts were unsuccessful.
Impact on AI Coding Tools and Future Outlook
The attack extended beyond credential theft, targeting settings files used by AI coding tools. The worm modified files to establish a fake server that allowed it to run malicious scripts. It also altered repository settings to propagate the attack further.
For continued persistence, the worm installed a Python backdoor that monitored GitHub commits for specific markers. If it encountered authentication errors, it would delete the user’s home folder, emphasizing the need for immediate and cautious responses.
Protective Measures and Recommendations
Developers who installed strutil-core 1.0.1 should consider their systems compromised. Immediate actions include isolating affected machines, removing malicious scripts, and rotating credentials from secure devices. Additionally, it is crucial to review and clean up any potentially affected project files and settings.
Indicators of compromise (IoCs) should be disseminated among security teams to prevent similar incidents. Collaboration with threat intelligence platforms can further enhance the defensive posture against such supply chain attacks.
