server: block proxy-role agents from self-approving proposals#140
Merged
dangtony98 merged 1 commit intomainfrom Apr 28, 2026
Merged
server: block proxy-role agents from self-approving proposals#140dangtony98 merged 1 commit intomainfrom
dangtony98 merged 1 commit intomainfrom
Conversation
requireProposalReview's instance-level branch fell through to requireVaultAccess, which only checks for ANY row in vault_grants regardless of role. A proxy-role agent could create a proposal pointing at an attacker-controlled host and approve it itself, then have the broker inject the credential on the next /proxy call. Switch to requireVaultMember so member+ is required (matches the rule the call-site comments already claimed). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
💬 Discussion in Slack: #pr-review-agent-vault-140-server-block-proxy-role-agents-from-self-approving-pro Posted by Review Police — reviews, comments, new commits, and CI failures will stream into this channel. |
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.
Summary
/proxy/...call.requireProposalReview's instance-level branch calledrequireVaultAccess(existence-only check onvault_grants) instead of enforcing a role floor. Switched torequireVaultMemberso member+ is required — proxy is now blocked, matching what the call-site comments already claimed.Test plan
TestInstanceLevelProxyCannotApproveProposal/TestInstanceLevelProxyCannotRejectProposalassert 403 and that the proposal stayspending(proves the apply step never ran, so credential injection cannot occur)TestMemberCanApproveProposalInAnyMemberVaultstill passes via the newrequireVaultMemberpath — locks in non-regression of the legitimate member-approval flowgo test ./internal/server/andmake testare greenrequireVaultAccessshould have beenrequireVaultMember🤖 Generated with Claude Code