P6: browser.goto — real Chromium browsing with live web taint
- SandboxSpec gains an egress flag (default false — the kernel suite
still proves zero-network for agent sandboxes). Egress-enabled
containers exist ONLY for the browser: no credentials, no broker
route, bridge network with host-gateway alias for local test pages
- images/agent-browser: Alpine Chromium, uid 10001, setuid bits
stripped — same non-root hardening as agent-base
- browser.goto tool: headless chromium --dump-dom in the agent's
browser container; HTML stripped to readable text (4k cap) and
returned with output_taint=web; viewport screenshot captured,
base64'd out of the container, stored in the blob store
- Taint semantics tightened: the step that PRODUCED untrusted output
now carries its own taint (recorded before the step row), not just
later steps — chat.inbox test updated to the stricter §15 reading
- GET /api/claws/{id}/browser/viewport.png serves the latest capture;
BrowserApp polls it and renders the live viewport (spec §7.1),
keeping the empty state until the agent has browsed
- Proven end to end with REAL Chromium against a REAL local page:
content 'Revenue up 14 percent' returned tainted web; the gated
email.send that follows carries 'web' in its approval taint_sources
(untrusted content can never quietly reach outward); screenshot
verified by PNG magic bytes
152 Rust tests + 63 frontend + 27 Playwright journeys.
Co-Authored-By: Claude Fable 5 <[email protected]>
This commit is contained in:
co-authored by
Claude Fable 5
parent
7392ce1d08
commit
4f253bec93
@@ -245,5 +245,9 @@ async fn inbox_content_taints_the_run_and_its_approvals() {
|
||||
.unwrap();
|
||||
let steps = &history.last().unwrap().steps;
|
||||
assert_eq!(steps[0].tool_name.as_deref(), Some("chat.inbox"));
|
||||
assert!(steps[0].taint.is_empty(), "inbox read itself is pre-taint");
|
||||
assert_eq!(
|
||||
steps[0].taint,
|
||||
vec!["inter_agent"],
|
||||
"the step that produced untrusted output carries its taint"
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user