Skip to content

feat(ocap): crew_runner applies caveats.meet() at dispatch + honest docstrings (#750)#751

Merged
hartsock merged 1 commit into
mainfrom
feat/ocap-2-crew-meet-seam
Jun 29, 2026
Merged

feat(ocap): crew_runner applies caveats.meet() at dispatch + honest docstrings (#750)#751
hartsock merged 1 commit into
mainfrom
feat/ocap-2-crew-meet-seam

Conversation

@hartsock

Copy link
Copy Markdown
Member

OCAP enforcement-floor stack — PR 2 of 8 · epic #749

Review/merge order (full ordered list + rationale in #749): a docs PR (docs/ocap-authority-review, the design review + paper — opens at the end of the stack) is the "read-first" rationale; this is step 2; step 3 (crew fs_read) branches off this. Merge bottom-up.

What this does

Wires the .meet() attenuation seam: LocalCrewRunner::dispatch now passes child = session.meet(crew_clamp) (pure dispatch_caveats helper) to run_team/run_crew instead of the session caveats unmodified. crew_clamp is config-sourced ([crew], default Caveats::top() ⇒ meet is identity ⇒ today's behavior unchanged) and is the tightening point for the per-subtask team_clamp (#749 step 8). The crew_tool.rs docstrings now claim only what meet guarantees (≤ session), replacing the false "never the session's full grant."

Test plan

dispatch_caveats_meets_the_clamp_and_stays_le_sessionred on today's code (a crew with a net-denying clamp still permitted net), green after; + default-is-top identity + the config wiring. just check green (2663 tests). The agent-mesh meet algebra is sound + unchanged.

Fixes #750. Part of #749. Refs #739, #741.

🤖 Generated with Claude Code

…ocstrings (#750)

OCAP enforcement-floor stack (#749, PR 2/8). Wires the .meet() attenuation seam:
LocalCrewRunner::dispatch now computes child_caveats = session.meet(crew_clamp) via a pure
dispatch_caveats helper and passes it to run_team/run_crew, instead of the session caveats
unmodified. crew_clamp is config-sourced ([crew] CrewPolicyConfig, default Caveats::top() so
today's behavior is unchanged — meet is identity by default) and is the tightening point for the
per-subtask team_clamp (#749 step 8). The crew_tool.rs docstrings now claim only what meet
guarantees (<= session), replacing the false "never the session's full grant."

TDD: dispatch_caveats_meets_the_clamp_and_stays_le_session (red on today's code — a crew with a
net-denying clamp still permitted net; green after) + default-is-top identity + the config wiring.
just check green (2663 tests). The agent-mesh meet algebra is sound + unchanged.

Fixes #750. Part of #749. Refs #739, #741.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ocap Object-capability / authority-security; pending full design review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OCAP step 2: crew_runner applies caveats.meet() at dispatch + honest docstrings

1 participant