DEV Community

Ramdai Bista
Ramdai Bista

Posted on Originally published at stupidllm.com

GuardFall: shell tricks bypassed the command-safety guardrail in 10 of 11 open-source coding agents

Ten open-source AI coding agents ship a guardrail whose job is to stop the agent from running a destructive shell command. Rewrite the command slightly — not hide its intent, just rewrite it — and nine different implementations of that guardrail let it through.

What the source says

Per Adversa AI's research note, published by the Cloud Security Alliance, security researcher Omer Ben Simon disclosed "GuardFall" on June 30, 2026: a 21-case test suite covering 12 canonical destructive shell-command patterns, run against the command-approval guardrail built into eleven open-source coding agents. Ten failed — OpenCode, Goose, Cline, Roo-Code, Aider, Plandex, Open Interpreter, OpenHands, SWE-agent, and Hermes each proved vulnerable to at least one of five bypass classes: quote removal (bash rewrites r''m to rm), variable/IFS expansion (rm$IFS-rf$IFS/), command substitution ($(echo rm) -rf /), base64-encoded pipelines, and destructive commands that simply aren't on the keyword list (find /x -delete, dd of=/dev/sda, sed -i).

The guardrails inspect a command's literal text. Bash expands and rewrites that text before it runs. None of the ten accounted for the gap between the two. Plandex, Aider, and Open Interpreter had no static guard at all — they relied entirely on a human clicking "approve," or a sandbox, to catch what pattern-matching didn't. Only Continue's evaluator withstood the full suite, because it tokenizes and canonicalizes a command before judging it instead of matching raw text — the fix Adversa recommends the rest of the category adopt.

To rule out the bypasses being academic, the researchers then ran end-to-end exploits against production builds of Plandex and eight of the other affected agents, triggered by attacker content planted in an ordinary repository artifact the agent reads — no model jailbreak required.

What it doesn't establish

This is a responsible-disclosure research finding, not a reported real-world breach. No CVE has been assigned, and no affected project had shipped a structural fix as of the June 30 disclosure. Adversa frames the gap as a design convention that needs replacing project-wide — pattern-matching raw command text against a keyword list — rather than a single patchable bug in any one agent.

Why it matters anyway

Nine different teams independently built the same kind of guardrail, and nine of them made the same category error: checking the command a user can read, not the command bash will actually execute. That's not a coincidence of one codebase; it's what happens when "is this dangerous?" is implemented as regex-against-text instead of parse-then-inspect. If you're running any of the ten affected agents with filesystem or shell access and trusting its built-in guardrail as a backstop, it currently isn't one — Continue's tokenize-first approach is the one pattern in this test that held.

Full write-up and severity scoring: https://www.stupidllm.com/incident/STUPID-2026-0187/

Top comments (0)