Skip to content

Clamp child thread permission mode to the parent's mode - #1594

Merged
SawyerHood merged 1 commit into
get-bb:mainfrom
sholub-dev:clamp-child-permission-to-parent
Aug 14, 2026
Merged

SawyerHood merged 1 commit into
get-bb:mainfrom
sholub-dev:clamp-child-permission-to-parent

Conversation

@sholub-dev

Copy link
Copy Markdown
Contributor

Fixes #1593.

Summary

  • The parent thread's last-executed permission mode is now a hard ceiling for managed child threads. resolveThreadExecutionPermissionMode resolves the preferred mode as before (explicit request, then the child's recorded mode, then parent inheritance, then project defaults) and then clamps it with the existing clampPermissionModeToCeiling domain helper.
  • This closes both escalation paths: an explicit --permission-mode full from a sandboxed parent now resolves to the parent's mode, and provider-support reconciliation can no longer upgrade an inherited mode (a Pi child of an auto parent fails provider validation instead of silently getting full).
  • A child can still run below its parent's mode, and a full parent's children are unaffected.
  • Updated the bb-cli skill and the threads guide template to document the ceiling.

AGENT GENERATED: by Claude Fable 5

@SawyerHood
SawyerHood force-pushed the clamp-child-permission-to-parent branch from 2d4cdbb to 6c31811 Compare August 14, 2026 21:27
@SawyerHood
SawyerHood merged commit b55e89c into get-bb:main Aug 14, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Child threads can run with more permissions than their parent

2 participants