Skip to content

test: require client evidence in network-denial checks - #762

Open
EliasCodeFI wants to merge 1 commit into
anthropics:mainfrom
EliasCodeFI:test/network-denial-workload-evidence
Open

EliasCodeFI wants to merge 1 commit into
anthropics:mainfrom
EliasCodeFI:test/network-denial-workload-evidence

Conversation

@EliasCodeFI

Copy link
Copy Markdown

The network-denial tests accepted a command that never started the intended client: a nonzero wrapper exit, a missing DNS tool, or the shell's fallback echo could satisfy the assertion. A broken sandbox startup could therefore look like successful network enforcement.

These tests now require client start and completion markers with a normal numeric exit status. Local HTTP and DNS fixtures first prove the same client can reach a target outside the sandbox, then verify the sandboxed attempt produces an expected denial result without reaching that target. The DNS fixture distinguishes a received DNS REFUSED reply from transport refusal or timeout. HTTPS cases test rejection before TLS reaches the local target; an unrelated TLS handshake failure is rejected.

Known-bad controls that discard the intended command or run it without sandboxing both fail the selected tests. Local runtime checks pass with network.allowAllUnixSockets=true explicitly enabled; this does not validate the default seccomp helper. Typecheck, build, lint and formatting checks pass, and independent review accepted the source.

Default-helper and platform validation passes at commit 1382b7c in fork PR #3: Tests, Release/package checks. Package publication is skipped.

The initial macOS arm64 job failed in an unchanged Git-over-SSH delayed-refusal case with an early no answer. A failed-job-only retry passed at the same commit. That failure is retained for separate diagnosis; this patch does not claim to fix it.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant