Repository navigation
fix(session-control): let the owner's Conductor dispatch workers - #24653
Conversation
UX Review (Opus 5.5) — ⏭️ skippedRevision |
|
Local adversarial review (a fresh subagent that saw only the diff) tried to break the ownership fence. Nothing breaks it outright; each conditional attack checked against the code:
The GPT local lane raised one Medium: an autouse fixture used the shared |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks: the bypass checks the caller's identity directly, it is capped by the existing Notes
[DESIGN-REVIEWED] 184f058 Description read[DESCRIPTION-READ] 8a4079ed53c07e9fbe547648967792337efdf954defc32d184f0c972ef4bc99e That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing blocks. The bypass fixes the reported defect (#24620) under the existing Notes
What this change shipsInventory (7 items) — 5 justifiedIntent: let a person's own-tab Conductor dispatch workers on installs that stored
[FIRST-PRINCIPLES-REVIEWED] 184f058 Description read[DESCRIPTION-READ] dfa3786ccdd790467df0b259d7eb26d6d1df6c302eb8ee9b4176a770e1d6fa7d That sha256 names the PR description this verdict read. Recompute it with |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
3fdda3c to
7a2ef94
Compare
|
self-added: no
|
|
7a2ef94 to
9e24101
Compare
… session_control off
9e24101 to
184f058
Compare
|
Holding 184f058 for a maintainer, for two reasons.
I found no defect. The predicate is positive identity on the caller's own slot: a What clears it: a maintainer ruling on the product question (an override or RFC note, as the disposition proposes) and a human review of the bypass. — crew-pr-reviewer (r128) |
KiroCrewCaptain
left a comment
There was a problem hiding this comment.
Approved on behalf of the watch holder (bolichen). Design and First Principles pass on this head (or skipped / author override), UX skipped or pass, no conflict, no open change request.
|
🤖 Kiro Crew Auto-Pipeline [operator: buluoray]: The open policy question (a stored |
Problem / Motivation
Goal: A Conductor the person starts in their own dashboard chat can open and drive its worker chats even when
agent.session_controlisfalse, reaching only the sessions it created.On an install whose config stores
agent.session_control: false(the pre-#8375 default, which Doctor reports but never overrides), akirocrew-conductorchat cannot dispatch anything:session_createrefuses withsession control is disabled in config (agent.session_control)(session_control_disabled). Crew members already bypass that switch; the owner's own Conductor does not, so Crew Mode cannot do its one job out of the box on those installs.Why it matters
Crew Mode and the shipped Conductor exist to dispatch workers. Anyone with the stored old default gets a Conductor that can only chat, with a refusal that points at a switch they may never have set on purpose.
Not a goal
agent.session_controldefault or migrating stored values.agent.member_dispatchceiling governs this bypass.agent.session_controlis on.What changed (motivation → approach → change)
Security-relevant authorization change. It adds a switch bypass to session control, so it needs a careful review.
The switch gates in
create_session,fork_sessionandauthorize_targetexempted only crew members (_member_bypass). The owner's Conductor is now exempt on the same terms:_owner_tab_conductor)chat-tab key, agent inCONDUCTOR_AGENTS(kirocrew-conductorand its deprecated alias), no_created_by, no channel or cron link, not channel-born, not app-scoped, no non-user origin, not a crew member_conductor_bypass)member_dispatch_enabled(), soagent.member_dispatch: false, an unreadable config, or a degradedagentsection withdraws it, the same as for members_conductor_fenced)_caller_is_ownership_fencedand_delegation_lineage_fenced: it reaches only sessions it created (not_creatorotherwise, with Conductor-specific wording) and binds no private-member store_dispatch_bypass(member OR Conductor) replaces_member_bypassat the three switch gatesA worker the Conductor creates carries
_created_by, so it gets no bypass and stays fenced whatever agent it inherits. With the switch on, the Conductor keeps the owner's reach, as before. I reusedmember_dispatchinstead of adding a sibling key: it is already the operator's one ceiling on "a dispatching agent works withoutsession_control", it already fails closed, and a second key would be a second thing to find when withdrawing it.The session-control spec gains "The owner's Conductor" section, and its refusal table and
member_dispatchconfig entry name the new bypass. The operator-facing text says the same: thesession_controlandmember_dispatchfield descriptions insections_agent.py(andconfig-baseline.json, regenerated) and the packagedsrc/kiro_crew/docs/session-control.mdswitches table. The superseded-default note foragent.session_control(superseded_defaults.pyand the config spec's table) says a storedfalsewithdraws session control from ordinary agents, with members and the owner-tab Conductor keeping the fenced bypass unlessagent.member_dispatchis alsofalse.Backwards compatibility
Compatible: a call refused today with
session_control_disabledcan now succeed for the owner-tab Conductor only. Every other caller sees the same answers, and nothing main accepts is rejected.Removes nothing: the diff adds a bypass and a fence population; no key, path, record or public function is removed or renamed.
Tests
test/test_session_control_conductor_bypass.py(29 tests), through the realcreate_session/authorize_targetpaths:send/read/stop/closeit with the switch off;not_creatoron the person's other chat and on a peer Conductor's worker;session_control_disabled;not_creator-fenced with it on; the lineage walk fences both for private-member dispatch;member_dispatch=false, a degradedagent/ whole config, and an unreadable config each withdraw the bypass;_created_by, Slack or cron link, channel-born, app, cron/app origin, cron/workflow/member keys, member store, missing slot) answers false.Proof: PROVEN test/test_session_control_conductor_bypass.py::TestOwnerTabConductorEndToEnd::test_is_refused_on_a_session_it_did_not_create (head 184f058)
Related suites (43 session-control, member, cron and facade test files, 1538 tests) pass locally. Determinism: the new file passed 5 consecutive runs and one run in a shuffled node order (seed 7).
Manual verification
N/A: unit coverage drives the real gate, fence and create paths. A live-gateway check with a Conductor tab was not run.
Related Issues
Closes #24620
Sibling sweep
Swept: git grep -n "_member_bypass|session_control_enabled()" -- src/kiro_crew
Sibling: src/kiro_crew/dashboard/session_control_parts/session_create.py -- changed here
Sibling: src/kiro_crew/dashboard/session_control_parts/target_authorization.py -- changed here
Sibling: src/kiro_crew/dashboard/session_control_parts/session_tree.py -- changed here
Sibling: src/kiro_crew/dashboard/handlers/session_control.py -- not affected -- its scoped-caller gate lets an owner (unscoped) caller through unchanged
Sibling: src/kiro_crew/dashboard/handlers/_shared_route_guards.py -- not affected -- it gates only scoped (private-store) callers, never the owner tab
Pattern harvest
Not generalizable: the defect is one missing caller class at a deliberate operator switch, not a repeated code shape a rule can match.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)