Skip to content

Pass filter-option fields as raw strings and check the repository - #12

Open
NoSync wants to merge 1 commit into
ajma:mainfrom
Klartika:fix/filter-options-input
Open

NoSync wants to merge 1 commit into
ajma:mainfrom
Klartika:fix/filter-options-input

Conversation

@NoSync

@NoSync NoSync commented Oct 22, 2026

Copy link
Copy Markdown

filterOptions passed the repository's owner and name to gh api graphql with -F, which treats a value starting with @ as a file to read (and turns all-digit values into numbers). issues.filter-options also accepted any string as repo, so a value such as @/some/file/x was not refused before reaching gh. The callers are this plugin's own screens, so this is hardening rather than an exploitable path, but the pull request lookup already does both things right.

  • The owner and name are passed with -f, as pullRequests does.
  • issues.filter-options validates repo with the same owner/repo pattern as issues.pull-requests (now a shared repoSlug), and filterOptions parses its input like pullRequests.

Tested: npm run typecheck and npm test, with tests that the GraphQL call uses -f and that malformed repositories are refused before any gh call.

This touches shared/issues.ts near #11; whichever merges second needs a small rebase, which I will do.

🤖 Generated with Claude Code

filterOptions passed the owner and name to `gh api graphql` with -F,
which reads a value starting with @ from a local file and turns digits
into numbers. Use -f, as the pull request lookup does, and validate
issues.filter-options' repo as owner/repo with the same pattern.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
NoSync added a commit to Klartika/paseo-issues-workspaces that referenced this pull request Oct 22, 2026
The same hardening as ajma#12, on this branch's filter options: -f instead
of -F for the repository's owner and name, and owner/repo validation.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.

1 participant