feat(sandbox): services-layer capability-scope hardening - #10232
Open
kwburns-kong wants to merge 11 commits into
Open
feat(sandbox): services-layer capability-scope hardening#10232kwburns-kong wants to merge 11 commits into
kwburns-kong wants to merge 11 commits into
Conversation
Every side-effecting bridge path maps to exactly one capability group (BRIDGE_PATH_CAPABILITIES); filterByCapabilities wraps the handler map so an ungranted path rejects with 'Capability X not granted — add it to insomnia.permissions.capabilities', and an unmapped path fails closed. The template-tag surface resolves baseline ∪ manifest.capabilities; bundle (first-party) plugins get ALL_CAPABILITIES. Envelope carries grantedCapabilities for C2. Baseline capabilities: render, models.read, util, crypto (network/storage/ fs-read/credentials/app must be declared). 'util' (nodeOS/decode/encode) is baseline — same info the built-in os/base64 tags already expose. - unit: completeness test parses every __bridge() path from the bootstrap and asserts a capability mapping (new ungated path fails); filter matrix; e2e grant/deny/baseline - e2e: plugin declaring 'storage' round-trips context.store; undeclared denied with the exact message; baseline util.render still works (per-capability) - demo: capabilityprobe tag + storage grant Deviations from plan letter: added 'util' baseline (canary needs nodeOS); used storage not network for the positive-path e2e (cleaner than building a request).
…dules (C1) - resolveTemplateTagCapabilities now drops declared names that aren't real Capability values, matching its docstring (keeps the envelope clean for the P1 ceiling intersection). - Bundle (trusted first-party) plugins now receive ALL_SANDBOX_MODULES too, so the 'every module + capability' comment is accurate — they no longer silently run on the baseline module set.
…ary file read Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ock cross-collection write Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…list Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Closes a gap where a symlink inside an allowed directory could point outside it and bypass the allowlist.
✅ Circular References ReportGenerated at: 2026-07-09T20:21:25.670Z Summary
Click to view all circular references in PR (9)Click to view all circular references in base branch (9)Analysis✅ No Change: This PR does not introduce or remove any circular references. This report was generated automatically by comparing against the |
…s fixture The 'invalid' dataFolders entry only worked by string-prefix coincidence with invalid.cert/invalid.key, which the separator-boundary fix in ebece69 correctly no longer allows. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…nstance A disallowed or unreadable path on one client certificate threw out of the forEach loop and aborted curl setup for the whole request, so a single bad certificate silently dropped every other valid one too. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
Author
|
The |
…lders fixture 'certificates/client' isn't a real directory — client.crt/client.key are flat files under certificates/. It only worked by the same string-prefix coincidence the separator-boundary fix in ebece69 correctly no longer allows. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
jackkav
force-pushed
the
claude/sandbox-pr5-capability-context
branch
from
July 13, 2026 13:10
a6a21a3 to
630d1c0
Compare
Base automatically changed from
claude/sandbox-pr5-capability-context
to
develop
July 13, 2026 14:14
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does
_idingetBodyBufferinstead of trusting a plugin-supplied path. This is used to block arbitrary file reads via models.read_idincloudCredential.updateand strip identity fields from the patch. This is used to block cross-collection writes via credentials.$ne,$where, etc.).