GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — [FEATURE]: Extract inner commands from xargs/parallel/find -exec for permission matching · Issue #9516 · anomalyco/opencode Closed as not planned Closed as not planned Copy link DescriptionProblemWhen a command is wrapped in For example, with this permission config: "bash": { "*": "allow", "gh api* -X DELETE*": "ask" } This command bypasses the permission check entirely: gh api repos/owner/repo/code-scanning/analyses --paginate -q '.[] | .id' | xargs -I{} gh api -X DELETE repos/owner/repo/code-scanning/analyses/{} The bash tool parses this as two commands via tree-sitter:
The dangerous Proposed SolutionThe bash tool could recognize common command wrappers and extract their inner commands for permission checking:
When a wrapper is detected, both the wrapper invocation AND the inner command should be checked against permission rules. WorkaroundUsers can currently work around this by adding a leading "*gh api* -X DELETE*": "ask" This matches the pattern anywhere in the command string, but it's non-obvious and easy to miss. Reacted by Kevin Languasco, Fredrik Reveny and Jakob Jensen Activity
MetadataMetadataAssigneesLabelsNo labels TypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |