sandbox: leak-free placement for the .cliguard exec symlink #227

Merged
coilysiren merged 5 commits from issue-185-sandbox-leakfree into main 2026-07-14 09:29:40 +00:00
Member

This keeps the sandbox's $0-sensitive exec symlink inside a private tmpfs view of the canonical tool directory, so the helper can still exec .<tool>.cliguard without leaving a host-side artifact.

  • What changed: pre-resolve wrapped tools, stash real binaries first, overlay the canonical tool dir with a private tmpfs, and place the exec symlink there.
  • Why: the old path worked but left .<tool>.cliguard behind on the host.
  • Tests: go test -vet=off -p 1 ./cli/sandbox ./cli/shell; full make test hit container scratch-space limits in this environment.

closes #185
ward.workflow: pull-request-and-merge

This keeps the sandbox's `$0`-sensitive exec symlink inside a private tmpfs view of the canonical tool directory, so the helper can still exec `.<tool>.cliguard` without leaving a host-side artifact. - What changed: pre-resolve wrapped tools, stash real binaries first, overlay the canonical tool dir with a private tmpfs, and place the exec symlink there. - Why: the old path worked but left `.<tool>.cliguard` behind on the host. - Tests: `go test -vet=off -p 1 ./cli/sandbox ./cli/shell`; full `make test` hit container scratch-space limits in this environment. closes #185 ward.workflow: pull-request-and-merge
sandbox: keep exec symlink off host filesystem
Some checks failed
ci / lint (pull_request) Failing after 36s
ci / secrets (pull_request) Successful in 20s
ci / test (pull_request) Successful in 1m2s
d4bb2a1062
closes #185
ci: route Go scratch to runner temp
Some checks failed
ci / test (pull_request) Failing after 0s
ci / lint (pull_request) Failing after 0s
ci / secrets (pull_request) Successful in 6s
d13a169c9a
Use runner.temp for Go build, module, and golangci-lint caches so the CI jobs do not fill the container overlay during typecheck.
ci: export Go scratch through runner env
Some checks failed
ci / lint (pull_request) Failing after 19s
ci / secrets (pull_request) Successful in 8s
ci / test (pull_request) Successful in 47s
d1057cd33f
Configure Go build, module, and golangci-lint scratch through GITHUB_ENV so Forgejo and GitHub runners can use the runner temp volume without relying on unsupported job-level expressions.
ci: tame golangci-lint scratch use
Some checks failed
ci / lint (pull_request) Failing after 50s
ci / test (pull_request) Successful in 1m4s
ci / secrets (pull_request) Successful in 11s
f64e4cc35e
sandbox: reduce jail setup complexity
All checks were successful
ci / test (pull_request) Successful in 1m16s
ci / secrets (pull_request) Successful in 9s
ci / lint (pull_request) Successful in 31s
97a01ccfba
Signed-off-by: Codex <noreply@openai.com>
Sign in to join this conversation.
No description provided.