main · Records: findings and
disposition only. AUDIT.md is the full pre-publication audit narrative and
is not superseded by this document; this is a dated follow-up review, not a
replacement.
Threat model
Same boundarySECURITY.md already states, read again from an attacker’s
seat rather than a reader’s:
In scope. A malicious caller, malicious executed code, or adversarial
tool input that:
- escapes the sandbox to run code outside the executor’s constraints,
- reads or writes host files outside the session workspace or the 23-entry env allowlist,
- reaches the network when
no_netwas requested and believed enforced, - or — the class this audit spent the most time on — makes the server
report a guarantee it did not apply. A false
unenforced: []is in scope even where no data actually left the machine, because the caller has no way to tell the difference from the result alone.
SECURITY.md). This audit did not test multi-tenant
isolation, did not assume a hostile co-tenant sharing the same server process,
and did not treat same-uid resource exhaustion as a finding — both are
already named as out of scope by the project’s own threat model, and testing
against a boundary the software never claimed to have would not have produced
an actionable finding.
Method
Two passes, not one:- Read. Every surface below, source plus its own docstrings/comments,
checking each claim a comment or docstring makes against what the code
actually does — the same discipline
AUDIT.mdand the fuzz campaign already established for this repo (a docstring that asserts a mitigation is a claim, and claims get checked, not trusted). - Live adversarial probes. Where a claim was checkable by running code
through the real sandbox — Rust backend, native binary,
no_netshim loaded — it was run, not reasoned about. E-1 traces to exactly such a probe: ano_netresult that returned a different answer than theunenforcedfield beside it promised. N-2 was found the other way, by reading — a write-path docstring that contradicted the read-path one — and its parent-directory TOCTOU residual is accepted from the code’s structure (final-componentO_NOFOLLOWonly), not demonstrated by a live exploit.
Surfaces reviewed
Six, chosen as the boundaries between a caller/executed-code and something that matters if crossed:- Parse screen (
safe_expr.py,logic.py,linalg.py) — the denylist between a caller’s expression string and SymPy’sparse_expr. - Session jail (
sessions.py) — path confinement, symlink handling, quotas, and workspace cleanup for stateful sessions. - Executor (
executor.py,executor/src/*.rs) — env allowlist, rlimits, process-group kill,no_net, and result-shape parity between the Rust and Python-fallback backends. - Packages (
packages.py) —install_package’s argv construction and fail-closed behaviour when a manager cannot be confined. - HTTP transport (
server.py,mcp_middleware.py) — DNS-rebinding protection, token auth, and the request/response size guard onserve-http. - Info leaks (
errors.py,audit.py, pydantic validation) — whether an error path, an audit log entry, or a validation failure echoes something it should not (a raw argument value, a host path, a secret).
Findings
What held
Per surface, what was probed and did not break:- Parse screen. No RCE reachable through
safe_expr/logic.truth_table/ SymPyparse_exprin this pass — CRITICAL-01’s dunder-chain class stays closed (tests/test_security.pystill asserts it live).safe_global_dict()has no Python builtins in it, verified by inspection and by probing for an evaluator reachable through the exposed SymPy namespace; none was found. Cost bounds (MAX_SYMBOLIC_EXPONENT,MAX_NUMERIC_DIGITS, the variable-count and expression-length caps) fired on the inputs built to trip them. - Session jail. No escape found: the component-wise
is_relative_toboundary check held against sibling-directory and symlink probes;_jail’s length/segment caps held against the fuzz-shaped DoS inputs surfaced; quota accounting and workspace cleanup (_rmtree_checked, identity-checked against a swapped directory) held. - Executor. Env-drop (the 23-entry allowlist), rlimits (CPU/memory/output/
process-count), process-group kill on timeout, and workdir-identity cleanup
all held under adversarial probes — except
no_net, which is E-1 above. Every other ceiling that claims enforcement on this platform (test_platform_contract.py’s “anything NOT reported unenforced must actually bite” half) still bites. - Packages.
install_packagestill passes package strings as argv only, never through a shell, and still fails closed rather than silently degrading when a manager cannot be confined (Landlock unavailable, or a platform with no equivalent). - HTTP. DNS-rebinding protection (loopback allowlist vs. a spoofed Host
header), token auth, and the request/response size guard on
serve-httpall held against the probes built against them. - Info leaks. pydantic validation errors no longer echo a caller’s raw argument value (#212b) and still hold; audit-log entries and error paths probed for this audit did not surface a host path, secret, or argument value that the existing redaction should have caught.
Residuals for the owner
Nothing here is new — each is already named inSECURITY.md or AUDIT.md’s
own residual-risk sections — restated because this audit specifically
re-checked each one rather than assuming it still held:
- No true network isolation without a container/microVM.
no_net(post-E-1) now says so honestly; it was never meant to be more than a speed bump. Real isolation is--network=noneor gVisor/Firecracker, not a symbol shim, on any platform. Update 2026-08-21: narrower than stated above for Linux specifically — a seccomp-bpf filter now enforcesno_netthere in-kernel (the socket syscall itself is refused, not just the symbol), so this residual is now a macOS/no-seccomp-fallback statement rather than a universal one. The container/microVM caveat still holds everywhere for isolation beyondno_netalone (filesystem, other same-uid processes, etc.). - Same-uid execution. rlimits constrain, they do not sandbox a hostile program away from other files this user can read. Full isolation needs containers or a VM — out of scope for the tool as documented, in scope the moment anyone points it at multi-tenant or internet-facing traffic.
- No independent third-party review. This audit and its fuzzing-campaign predecessor are both Claude-family (in-house). The attempted cross-vendor Codex pass was blocked by Codex’s own content filter before it could examine sandbox code at all (see Method) — a genuinely independent security review (a firm, or an external maintainer with no relationship to this codebase’s own model family) has not happened and remains an owner action, not something addressable from inside this audit.
- No external maintainer. Single-maintainer project (
SECURITY.mdalready says so for response-time expectations); a second set of eyes with commit access and no stake in any given PR would catch a different class of thing than either this audit or a fuzz campaign can.
What this document is not
Not a certification, not a warranty, and not independent of the codebase it reviews — an in-family model auditing a project whose threat model centers on “a model executes code here” carries the same limitationAUDIT.md already
names for its own author. Weigh it accordingly, same instruction
SECURITY.md gives for AUDIT.md itself.