checkpoints: snapshots copy untracked secret files into git objects
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 62/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- git, javascript
Research direction
Start in packages/server/src/checkpoint-manager.js at _createGitSnapshot, following the private-index setup through the git add -A -- . call to see where pathspec excludes can be attached and where the commit and tag are written. Read the existing checkpoint tests to learn the fixture setup, then add a regression case with an untracked credentials/x.p12, an untracked .env and a .env.example, asserting via git cat-file -e that only the first two are absent and that the warning fires once per snapshot. Finish by documenting in the checkpoint docs that untracked, non-ignored files are included unless excluded.
Written by the indexing model from the issue text.
Description
Context
CheckpointManager._createGitSnapshot (packages/server/src/checkpoint-manager.js) builds a checkpoint by staging everything under the session's cwd into a private index with git add -A -- ., writing a commit with commit-tree, and tagging it chroxy-checkpoint/<id>.
git add -A respects .gitignore but nothing else. Any untracked file that isn't ignored is therefore copied into the repository's object store, and kept there for as long as the checkpoint tag exists. That includes local credentials, signing material, .env files and exported keys that a user keeps beside the code without a gitignore rule.
The tags are local. But git push --tags, git push --mirror, or a mirror clone used as a backup then carries those files off the machine, and nothing in the UI says a checkpoint captured them.
Proposal
- Before staging, exclude common secret paths and extensions from the snapshot through pathspec excludes on the
add. Examples:*.p12,*.pfx,*.pem,*.key,*.keystore,*.jks,*.mobileprovision,.envand.env.*(but not.env.example), andcredentials/. - When an untracked, non-ignored file matches one of those patterns, leave it out and emit a warning that names the path, so the user can add a gitignore rule.
- Document that checkpoints include untracked, non-ignored files.
Acceptance
- A snapshot of a tree containing an untracked
credentials/x.p12and an untracked.envdoes not contain either blob (git cat-file -efails for both). The checkpoint still restores the rest of the tree. - The skipped paths are reported once per snapshot.
- Existing checkpoint tests pass. A regression test covers both exclusions and the
.env.exampleexception.
- Dominant language
- JavaScript
- Stars
- 7
- Forks
- 1
- Avg merge
- 2h 3m
- Merged PRs (30d)
- 333
Getting set up
- Ships a Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from blamechris/chroxy
-
from-review tech-debt testing
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
blamechris/chroxy#9520 ·
Maintainers usually reply within 1 day
-
priority: low server
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
blamechris/chroxy#9340 ·
Maintainers usually reply within 1 day
-
documentation from-review
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
blamechris/chroxy#9237 ·
Maintainers usually reply within 1 day
-
agent-control client: notify() docstring should say the outbound gate applies only in principal modeOpenenhancement from-review
Difficulty 1/5 Under an hour Newbie friendliness 80/100
blamechris/chroxy#9227 ·
Maintainers usually reply within 1 day
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
blamechris/chroxy#9108 ·
Maintainers usually reply within 1 day
All issues in blamechris/chroxy
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
Use one constant for the 10,000-character input limitPossibly taken @NginxL claimed this today. Opengood first issue refactor
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
aniru-dh21/snap-validate#51 ·
Maintainers usually reply within 1 day
-
Documentation pleaseOpen
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
area/host bug P2
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Fei2411/DeepSeek-Bot#3190 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
freelawproject/litigant-portal#1307 ·
Maintainers usually reply within 2 days