test(sandbox): strengthen Seatbelt integration coverage - #391
Merged
Conversation
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Lokesh7025
approved these changes
Sep 12, 2026
Signed-off-by: VishnuM049 <vishnu.muthiah04@gmail.com>
Haz3-jolt
force-pushed
the
test/macos-seatbelt-integration
branch
from
September 13, 2026 19:14
b843285 to
ffda0b6
Compare
Haz3-jolt
approved these changes
Sep 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.
Purpose
Make the macOS Seatbelt integration tests exercise the real policy reliably. The previous fixture used the
/varalias while Seatbelt evaluates its canonical/private/varpath. The previous network check also targeted a closed port, so it could pass without proving that Seatbelt blocked a reachable endpoint.Fixes
N/A
Approach
Canonicalize the temporary fixture root before constructing
WorkspacePolicy. Start a local TCP listener and verify that a sandboxed command cannot connect to it.This changes tests only. It does not change sandbox policy or runtime behavior.
How was this tested?
pnpm exec biome format packages/sandbox/test/seatbelt.test.ts: passed with no changes.pnpm exec biome lint --error-on-warnings packages/sandbox/test/seatbelt.test.ts: passed.pnpm --filter @axl/sandbox typecheck: passed.pnpm --filter @axl/protocol build: passed.pnpm --filter @axl/kernel build: passed.node --test --test-reporter=spec packages/sandbox/test/seatbelt.test.ts: passed, 10 tests.git diff --exit-codein a clean detached worktree: passed.pnpm --filter @axl/sandbox test: Seatbelt tests passed. Two unrelated OCI tests failed on macOS because they read Linux-only/proc/self/mountinfo. Bubblewrap and unavailable OCI engine integration tests skipped as expected on this host.Learning
macOS temporary paths may be presented through
/varwhile their physical path is under/private/var. Seatbelt profiles must receive canonical paths. A network denial test needs a reachable endpoint to distinguish policy enforcement from an ordinary connection refusal.Checklist
REUSE.toml.Signed-off-bytrailer.AI assistance