Repository navigation
SR-3: engine hardening, round 2 (paths, turn-end reads, person-only checks) - #324
Draft
jothimani-rajendran wants to merge 2 commits into
Draft
jothimani-rajendran wants to merge 2 commits into
jothimani-rajendran wants to merge 2 commits into
Conversation
- cli: `--check` opens a person-only command only where its parser defines the flag (sync, recompile) and only before `--`. - gate: writes of empty content and apply_patch deletes/moves are judged by path; the turn-end listing names deleted files and a rename's old name; path gates also cover a policy's own folders (content scans still skip them). - gate: plugin gates judge from the repository top level; the turn-end read uses lstat/O_NOFOLLOW/O_NONBLOCK and refuses what it cannot read safely; on-disk case is judged on case-insensitive platforms. - gateway: judge the folded, resolved and cased spellings write_gate uses; a scoped gate treats a path it cannot place in the repository as in scope. - guardrails: in a repository a member is off only where HEAD's toggle file says so; the shell guard refuses a write through a path built by expansion. - tests for each; runtime goldens regenerated. .chock/bin is re-rendered by the owner's sync. Signed-off-by: Jothi Mani Rajendran <250249270+jothimani-rajendran@users.noreply.github.com>
Signed-off-by: Jothi Mani Rajendran <250249270+jothimani-rajendran@users.noreply.github.com>
This branch has not been deployed
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.
What
Hardening of the engine's path handling, turn-end worktree read, person-only command check and guardrails toggle lookup (plan item SR-3 in org-plan
plan/internal-release.md).cli:--checkopens a person-only command only where its parser defines the flag (sync,recompile), and only before--.apply_patchdelete or move are judged by path; the turn-end listing names deleted files and a rename's old name; a path gate also covers the policy's own compiled and source folders (content scans still skip them).write_gate.repo_paths; a scoped gate treats a path it cannot place in the repository as in scope..chock/guardrails.jsonsays so; the shell guard refuses a write through a path built by expansion.gate/repo_names.py,gate/worktree_read.py,chock_guardrails_protect/names.pykeep files under the 300-line budget.Definition of done
ruff checkandruff format --checkcleanpytest(full suite,-n 4,tests/test_properties.pyexcluded: needshypothesis, unmeasured) green except the two freshness tests belowchock sync --repo . --checkclean: needs the owner'schock syncto re-render.chock/bin(owner-only). Expected red until then:test_vendored_gate_py_matches_source,test_this_repo_has_compiled_what_it_declareschangelog.d/engine-hardening-round-2.mdaddedCHOCK_REGEN_GOLDENS=1)Claims
No new surface is installed or described as enforcing more than before.