Trust boundaries

A trust boundary is a line where data from a less trusted source enters a part with more power. A filter that blocks 95 percent of known attacks still lets new wording through. A separate reader with no tools keeps untrusted text away from the parts that act.

Play a level

See it on the board

The same traffic runs on two boards. The simulator measured both when this page was built.

Board to show
HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2UsersPartner appsWorker2 vCPU · 2 GBLLM API1 vCPU · 1 GBEmail servi…1 vCPU · 1 GBExternal API1 vCPU · 1 GBWeb firewall1 vCPU · 1 GB
HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2UsersPartner…WorkerLLM APIEmail se…External…Web fire…
Agent reads pages and holds the tools: misses a goal
HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2UsersPartner appsWorker2 vCPU · 2 GBLLM API1 vCPU · 1 GBEmail servi…1 vCPU · 1 GBExternal API1 vCPU · 1 GBWorker1 vCPU · 1 GB
HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2HTTP/2UsersPartner…WorkerLLM APIEmail se…External…Worker
Separate reader with no tools handles pages: meets the goals
See it on the board
Measure Goal Agent reads pages and holds the tools Separate reader with no tools handles pages
p99 latency (Tasks) under 4 s 2.7 s Pass 2.7 s Pass
Error rate (*) under 1% 0% Pass 0% Pass
Monthly cost 24 USD/mo 24 USD/mo
Error rate 0% 0%
Level rules none broken Board is not complete Fail Pass

Key numbers

Default part values from the catalog and the price table. The simulator uses the same values.
NumberValue
Share of known attacks a filter blocks, default0.95 fraction
Share of good requests a filter blocks, default0.005 fraction
Call to a language model, median150 ms
Price of one more worker4 USD/mo
A reader with no tools stops page ordersTap or press Space to add or remove the reader

Separate reader · 0 of 100 attacks reach a tool

How it works

Each system takes input that it does not control: user forms, uploaded files, web pages and messages from partners. A trust boundary is each point where such input meets a part with more power, such as access to a database, to money or to email.

At each boundary, decide what the input may do. Check its shape and size. Treat it as data, never as code or as an order. Classic attacks break this rule: SQL injection changes form text into a query, and cross-site scripting changes a comment into a script.

Language model agents add a new case. An agent that reads a web page and also holds tools can obey orders that hide in that page. This is prompt injection. Filters for known phrases help a little, but an attacker can always write new words. Separation is safer. A reader with no tools changes the untrusted page into a summary. The agent that holds the tools sees only that summary, and risky tool calls need approval.

Each boundary has a cost: one more step, more latency and one more part to run. Put the boundaries where the damage would be large.

In the levels you move untrusted input into a separate part that cannot act on it.