THE PERMISSION [LAYER]

AI agent incident

A malicious RubyGem stole coding agent credentials, planted an MCP server, and deletes the home directory if its stolen token is revoked

Reported · 1 source

What happened

Socket reported that version 1.0.1 of the strutil-core RubyGem, pushed on November 1 less than two hours after a clean 1.0.0, runs a credential-stealing worm when installed. In a sandbox run it read 51 credential stores, including the Claude Code and Codex credential files. It adds an MCP server named workspace-tools to AI tool configurations, adds session start hooks, and uses stolen Git credentials to commit agent instruction and settings files to repositories. On hosts where the GitHub token path worked, a monitor then checks the stolen GitHub token every 45 seconds for 48 hours and deletes the home directory if the token stops working. Socket says it does not know how many systems installed the release.

Why it matters

The worm turns the standard first response, revoking the token, into the trigger for data loss, and it persists by editing the files that tell coding agents what to do. Isolate an infected machine before revoking anything, then revoke agent and MCP tokens and review agent configuration and instruction files in every repository the developer could push to.

New incidents by email

Get incidents like this one in your inbox

New AI agent incidents are covered in the briefing, with what to check on the agents you already run. At least once a week, free.

You confirm by email. Unsubscribe in one click.

Sources

  1. socket.dev Shai-Hulud Descendant Surfaces in Malicious Ruby Gem That Steals Credentials and Poisons AI Tools

Background reading

Agent plugins and skills are a supply chain An explainer on the problem behind this incident.

Covered in the briefing

Issue #4: A wave of AI platform breaches is after model keys November 10, 2026

Cite or correct this record

“A malicious RubyGem stole coding agent credentials, planted an MCP server, and deletes the home directory if its stolen token is revoked.” The Permission Layer AI Agent Incident Database, https://thepermissionlayer.com/incidents/strutil-core-gem-poisons-agent-configs/. Database updated November 10, 2026.

Every record traces to the dated sources above. If something here is wrong or missing, email editor@thepermissionlayer.com and it gets fixed. See this record in the full list.

The Permission Layer

Get the next incident like this explained

When an AI agent breaks out, leaks data or runs up a bill, the briefing covers what happened and what to check on the agents you already run. At least once a week, five-minute read, free.

You confirm by email. Unsubscribe in one click.