Repository navigation
feat: add gh api graphql and gh project subcommands to default bash whitelist - #612
Conversation
…hitelist Add two new patterns to the default agent bash whitelist so that maintainer agents can manage issue types (via the GraphQL API) and project-board membership without per-repo config overrides: - ^gh api graphql( |$) — permits `gh api graphql -f query=...` for the updateIssueIssueType mutation and other GraphQL operations. - ^gh project (item-add|item-edit|item-list|field-list|view|list)( |$) — permits adding/editing/list-ing project-board items and managing their Status field. Both patterns sit alongside the existing gh issue/gh pr/gh api read-only patterns and remain gated by the agent's gh auth scopes; they only widen what the sandbox permits. Closes #606.
|
@claude Can you review this? can these commands be destructive or are they totally safe? use /maintainer |
|
Claude finished @edenreich's task in 3m 31s —— View job Review: are these whitelist additions destructive or safe?Short answer: one is safe, one is not. The crux is what "whitelisted" means here. Per
✅
|
|
@infer Can you drop these permissions for graphql and add instructions for the LLM to use explicit |
Todos
Pull Request✅ Infer Result: SuccessNow let me run the tests Model: Tokens: 4,233,111 in · 29,064 out · 4,262,175 total (50 requests) Tool calls: 60 total · 97% success rate
|
|
@infer you didn't push the changes. use /maintainer |
Todos
Pull Request✅ Infer Result: SuccessThe task is fully complete. Here's what was accomplished: In the repo (committed & pushed):
In the maintainer skill (applied live):
The Task is complete. Model: Tokens: 3,284,729 in · 18,849 out · 3,303,578 total (38 requests) Tool calls: 40 total · 95% success rate
|
Co-authored-by: Eden Reich <[email protected]>
Co-authored-by: Eden Reich <[email protected]>
## [0.120.0](v0.119.0...v0.120.0) (2026-06-06) ### 🚀 Features * add gh api graphql and gh project subcommands to default bash whitelist ([#612](#612)) ([b0f8bf3](b0f8bf3)), closes [#606](#606) * **tools:** restrict bash file-write redirects unless whitelisted by pattern ([#613](#613)) ([13b058a](13b058a)), closes [#581](#581) [#605](#605) [#581](#581) [#560](#560) ### ♻️ Code Refactoring * **ci:** remove NPM_TOKEN - use trusted publisher ([843457c](843457c)) ### 🧹 Maintenance * **deps:** bump infer CLI v0.117.1 -> v0.119.0, infer-action v0.11.2 -> v0.11.4 ([#611](#611)) ([30a536b](30a536b)) * regenerate config ([93e3de0](93e3de0))
|
🎉 This PR is included in version 0.120.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Summary
Add two new patterns to the default agent bash whitelist so that maintainer agents can manage issue types (via the GraphQL API) and project-board membership without per-repo config overrides.
Changes
config/config.go - Added two new whitelist patterns:
^gh api graphql( |$)— permitsgh api graphql -f query=...for theupdateIssueIssueTypemutation and other GraphQL operations via the GitHub GraphQL API.^gh project (item-add|item-edit|item-list|field-list|view|list)( |$)— permits adding/editing/listing project-board items and managing their Status field.config/bash_whitelist_test.go — Added test coverage for both new patterns:
TestIsBashCommandWhitelisted_GhApiGraphql— verifies GraphQL API commands with-fflags are allowed.TestIsBashCommandWhitelisted_GhProject— verifies project subcommands (item-add, item-edit, item-list, field-list, view, list) are allowed, while project delete/item-delete remain blocked.Acceptance Criteria
gh api graphql ...(issue-type mutation).gh project item-add|item-edit|item-list|field-list|view|list ....Closes #606