Repository navigation
Recognize executable spellings in shared command checks (T42) - #200
Merged
Merged
Conversation
erickb336
marked this pull request as ready for review
October 13, 2026 19:02
This was referenced Oct 13, 2026
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.
Closes #199
Sage task T42
Shared push and expansion checks now recognize mixed-case executable names and the .exe suffix. A command such as uppercase Git uploading main receives the same refusal as lowercase Git. The executable-name comparison handles both path separators. Arguments retain their case and meaning; the exact permitted PR merge form stays unchanged.
This is the shared-policy part of #97, not its complete repair. Claude's agent-specific executable checks and PowerShell forms remain open. No Claude hook source or PR #140 files change. Source edits are in packages/sage-core/command-policy.mjs and packages/sage-core/push-policy.mjs; both plugins contain regenerated copies.
Validation:
All tests put fake ps, pgrep, and kill first on PATH. Attack text reaches parsers or hook handlers only. Positive controls cover safe topic pushes, reads, ordinary glob arguments, and repository templates. The existing exact merge form remains the only recognized merge candidate.
Head 26b89da passed two clean code, security, and QA review cycles. The full local command npm test -- --test-concurrency=1 passed: 1,160 tests, 1,160 passed, 0 failed, 0 skipped. Exact-head CI run 38450290370 also passed: 1,160 tests, 1,160 passed, 0 failed, 0 skipped. All owned local test and review processes finished. No live Git push or API attack, native automatic activation, or real-model pilot ran. The command spelling checks are parser and handler evidence, not a Windows execution test.