Turning the audit on ourselves
A governance product that cannot show you where its own edges were is not one you should trust with a boundary. So this release is the result of pointing the method at ourselves: four systematic sweeps over packages/*/src, each asking exactly one question, with findings verified by reading the enforcing code rather than accepting the comment above it.
The four questions, verbatim from the release notes:
- Fail-open defaults — where does a default, fallback, error path, or unmatched condition permit rather than deny, in a deny-by-default system?
- Claimed but not enforced — which guarantees are stated in a comment or doc but have no enforcing code, or a second code path around the check?
- Gameable defensive logic — which scoring, normalization, or denylist can be defeated at the edges with specific inputs?
- The second privileged path — where is the desktop/IPC surface less governed than the agent path?
Every fix landed with an adversarial regression test in the same loop — never "fix now, prove later." The suite went from 602 to 656 passing across 99 files, then to 677 across 101 once the desktop IPC work folded in.
The shape of the work is visible in the history: one commit closing eighteen findings across 26 files, then four more commits over two days for the remainder, then two commits and 691 lines for the desktop IPC authority work alone.
Where a careful engineer still writes the bug
The interesting finding isn't the count. It's that most of these are idiomatic code. Ranked by how readily a competent reviewer would have approved them:
A check with no input is not a check that failed
The PDP's boundary and secret screening iterate a tool's declared pathParams. A shell tool declares none — correctly, because its argument is a command, not a path. So the loop ran zero iterations and reported nothing wrong. cat ~/.ssh/id_rsa arrived at the risk scorer as an ordinary exec call and, at Medium tolerance, auto-allowed silently.
Nothing was bypassed. The check simply had no domain to operate over — which is the hardest class of bug to see in review, because there is no wrong condition to spot. The fix adds commandReadsSecret(): a verb set (cat|less|head|tail|xxd|strings|base64|cp|scp|rsync|dd|gpg|openssl|hexdump|bat and friends, plus an input-redirect check) matched against the existing secret-path token set. Enforced in PDP.ingress as askOrigin: 'floor', which is the mechanism that matters: floors resolve before the tolerance ceiling, so no convenience setting can lift it. It escalates rather than denying — reading a secret file is sometimes the job — but it cannot happen with nobody watching.
Removing a root does nothing if the forbidden thing lives under one
Boundary derivation implemented "forbidden paths" by dropping them from the allowed roots. That is correct whenever the forbidden path is a root, and silently does nothing otherwise. Governance config, the audit log and state all live underneath the project root you are deliberately keeping — so containCheck happily admitted reads of them.
The fix is a different kind of list, not a better version of the same one: BoundarySet.deny, an explicit set of denied subtrees checked with sameOrUnder. A related finding caught the same omission on the desktop delete path, where a custodian boundary without deny let the IPC delete route trash audit.jsonl itself — files under the root but under no protected tree, which would have broken the tamper-evident chain from inside.
undefined routed the least-understood case to the most permissive outcome
Risk classification read tool.riskTier ?? CATEGORY_TIER[tool.category]. That looks complete. An unrecognised category made the lookup undefined, which propagated to composite 10, which banded to low, which auto-allowed. The input we understood least landed on the outcome we should have reserved for the input we understood best, purely through JavaScript's coalescing semantics. Now it defaults to critical.
A meter is a control surface, and arithmetic is attackable
The Token Governor accumulated whatever usage the provider reported. meter += reported is how every metering loop is written. But a compromised or redirected model endpoint reporting negative usage subtracts from the meter, walks an agent back under its hard limit, and defeats pause-at-limit entirely. Both values are now clamped to positive finite numbers — usage may only ever increase.
A control that reports success and blocks nothing
The nastiest of the set. Signed source revocations were stored using the issuer's key verbatim, while lookups at admission time used normalizeSource(). A revocation for http:https://Evil.com/ — capitalized, trailing slash — was stored as given and never matched the canonical form. The call returned applied: true. Green light, zero enforcement.
Any system with a normalize function applied to one side of a comparison has this bug waiting.
The data can contain the delimiter
Retrieved memory is wrapped in an untrusted-content fence so a model treats it as data rather than instruction. A page whose body contained a literal <<END UNTRUSTED MEMORY>> string could make attacker-authored continuation appear to sit outside the fence. Delimiter-based trust boundaries are the standard mitigation, and this is the same escape SQL and shell taught us. Markers in served content are now neutralized before the fence is applied.
catch { return fallback } as a censorship primitive
State restore used a helper that swallowed parse errors and returned its fallback, making an absent file indistinguishable from a corrupt one. Idiomatic, defensive-looking code — right up until the thing being restored is a list of refusals. Truncate the memory state file and every quarantine and rejection disposition silently comes back empty, with no signal. That is a tamper-denial-of-service with a clean bill of health.
Boot now uses an UNREADABLE sentinel distinct from null: absent restores empty, corrupt enters safe mode and audits state-corrupt — or memory-state-corrupt at critical tier. This reasoning later turned out to be the thing we had got right for state files and not applied to the audit log itself, which became the sharpest finding of the following release.
Every artefact of a control except the enforcing line
Per-agent allowedTools was declared in the registry, displayed in the UI, and described as deny-by-default. Only the inverse check existed — does the tool permit this agent — so a read-only agent could call any *-granted tool. The field was populated, the docs were right, the test suite was green, and nothing consulted it.
The check now exists. "No list = unrestricted" is preserved for backward compatibility, but it is audited once per agent, and there is an opt-in strict mode that makes absence a denial. Which surfaces the real lesson: absence of configuration was granting authority, invisibly.
Making "is this control even on?" answerable
That last point generalises, and the fix for it is the most quietly important thing in the release. Optional enforcement gates could be off silently, which is worse than being off and labelled — the operator's mental model is simply wrong.
EnforcementPosture is now recorded and audited at boot as enforcement-posture, carrying which gates are actually live. With one rule attached, which cost us later and was worth it:
false reads as an honest disclosure while being unfalsifiable.Verify-before-invoke was also turned on by default in both shipped roots. Scope non-deviation was reported off — honestly, because nothing issued a scope contract at runtime yet, so displaying it as on would have been a lie. That gap gets its own story in the next release.
The second privileged path
Sweep four asked where the desktop surface is less governed than the agent path, and found the structural answer: Electron IPC gives the main process no way to authenticate the caller. So the app trusted renderer-supplied authority — an actor field on approvals, a confirmed boolean on tolerance changes and permanent deletes. Any renderer code, including injected code, could claim to be the operator, self-approve a governed decision, raise risk tolerance to widen auto-run, or purge the recovery store.
Three passes closed it:
A capability token the renderer cannot mint. 32 random bytes per process, delivered only into the preload closure via an additional argument, never page-readable, never logged, compared with timingSafeEqual. Authorization order is integrity → token → operator-assigned-by-main. The renderer supplies nothing authoritative — not the actor, not a confirmed flag — and the operator identity is returned by the authority for the caller to attribute the action to. A self-approval becomes impossible by construction, because the approver is always the main-owned operator and proposer≠approver still runs downstream.
Renderer integrity, plus removing the vector it depends on. A sha256 manifest of the renderer bundle, verified on load, on fs.watch change, and on a periodic sweep, latching on first failure and refusing every privileged op thereafter. The reasoning is worth stating: if no attacker code can execute in the renderer, "renderer JS self-approves" reduces to "our own UI ran an approve on a real user action." So the same pass added sandbox: true, contextIsolation: true, and a strict CSP with no remote or inline script — closing the injection vector the integrity check exists to detect.
A trusted path for the irreversible ones. Authorization was extracted into single-gated functions so a handler cannot forget to call it, and permanent purge and destructive delete additionally require a native OS confirmation dialog the renderer cannot synthesize even with code execution. That is the layer that survives a renderer RCE: an exploit cannot click a main-process dialog for the user. No dialog available fails closed.
21 tests across the two IPC suites assert the properties directly — no token means the underlying action is never called; a tampered renderer refuses every privileged op even with a valid token.
What this does not fix
The residual is the same one it has always been, and it is structural rather than a backlog item. There is no OS-level isolation. Untrusted tasks run to the enforcement seam, not to a container, microVM or namespace boundary. A Chromium RCE that defeats the trusted-path dialog itself — faking the click through the compositor — sits in exactly that territory. Starfish governs a cooperative process; it does not contain a hostile one.
Path containment for arbitrary shell arguments also remains broad by design; routing exec through hardened command templates is the architectural direction and is tracked separately. And our OpenSSF Scorecard sits at 3.7/10, with remediation planned rather than done.
Stating those plainly is the same discipline as the rest of the release. A governance system's claims are the first thing that should be audited, and we are not exempt from our own method.