V31 Gate 6: Organization Team Role Policy Authority#49
Conversation
Own the organization/team/role/policy authority projection in @bitcode/btd, map it through Auxillaries contracts, and share it with Auxillaries Profile and Terminal detail surfaces. Add fail-closed BTD tests, API contract coverage, UI projection tests, Gate 6 spec/docs updates, and the Gate 6 checker/workflow hook.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2a3d16d4a1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| return typeof value === 'string' && value in ACTION_REQUIREMENTS | ||
| ? value as BtdOrganizationPermissionAction |
There was a problem hiding this comment.
Guard action normalization against prototype keys
Use an own-property check here instead of value in ACTION_REQUIREMENTS. With the current check, inherited keys like "toString" are treated as valid actions, so buildBtdOrganizationPolicyAuthority can select a non-requirements value and then crash when it tries requirements.permissionGrants.includes(...). Any caller that forwards untrusted string input into action can trigger this runtime failure instead of returning a fail-closed denied decision.
Useful? React with 👍 / 👎.
| readString(profile?.multiSigPolicyRoot) ?? | ||
| null, | ||
| }, | ||
| recoveryRoute: '/terminal?auxillary-open-to=profile', |
There was a problem hiding this comment.
Let authority derive recovery route from denial reason
Remove the hardcoded profile route override so the builder can emit reason-specific repair routing. Passing '/terminal?auxillary-open-to=profile' here forces every denied authority to use the same recovery route, even when the denial is wallet_binding_missing or interface_not_admitted, which should direct users to wallet/interfaces. This regresses remediation UX because downstream repair links can send users to the wrong pane.
Useful? React with 👍 / 👎.
Summary
Validation