Skip to content

Commit 60aed02

Browse files
committed
Rename 'Correct Pattern' to 'Bypassing Mechanism', reframe as partial defense
1 parent b3f23d3 commit 60aed02

1 file changed

Lines changed: 9 additions & 11 deletions

File tree

agentic-supply-chain-security.md

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -140,25 +140,23 @@ We tested the hook against all major variants. All five dangerous patterns are b
140140
| `curl https://example.com/install.sh -o /tmp/install.sh` | allowed |
141141
| `echo hello` | allowed |
142142

143-
## The Correct Pattern
143+
## Bypassing Mechanism
144144

145-
When an agent (or a human) genuinely needs to install software from a remote script, the correct sequence is:
145+
The hook blocks the direct pipe pattern. An agent (or a human) that needs to install software from a remote script can bypass the hook by downloading first:
146146

147147
```bash
148-
# 1. Download
148+
# Download
149149
curl -fsSL https://example.com/install.sh -o /tmp/install.sh
150150
151-
# 2. Inspect (the agent can read and reason about this)
152-
cat /tmp/install.sh
153-
154-
# 3. Verify integrity if a checksum is published
155-
sha256sum /tmp/install.sh
156-
157-
# 4. Execute only after review
151+
# Then execute
158152
bash /tmp/install.sh
159153
```
160154

161-
This sequence gives the agent — and the developer reviewing the agent's transcript — a clear point at which the script content is visible and auditable before execution. It also eliminates MITM-based content swapping, since the downloaded file is stable on disk.
155+
This two-step form is not blocked. It provides *some* security improvement over the direct pipe: the script is written to disk before execution, giving the agent — and the developer reviewing the transcript — a visible artifact. A human can inspect it; the agent can read and reason about its content before deciding to run it.
156+
157+
However, this is not a security guarantee. The downloaded script is still untrusted remote code. An attacker controlling the server can serve arbitrary content, and downloading to disk does not make that content safe. Integrity verification against a published checksum would be a stronger control, but checksums are rarely provided and trivially bypassable if the attacker also controls the checksum endpoint.
158+
159+
In short: the hook raises the bar by eliminating the most dangerous pattern, but it does not solve the underlying problem of executing untrusted remote scripts.
162160

163161
## Broader Implications
164162

0 commit comments

Comments
 (0)