Skip to content

fix(env): verify isolated acceptance responses in release builds - #728

Merged
tolgaergin merged 2 commits into
mainfrom
codex/acceptance-env-signatures
Sep 14, 2026
Merged

tolgaergin merged 2 commits into
mainfrom
codex/acceptance-env-signatures

Conversation

@tolgaergin

@tolgaergin tolgaergin commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

Optimized acceptance binaries reject authenticated env responses from the local test server with vault response signing key ID is unknown. Debug builds accept the same signed response. This blocks cloud env certification after CLI login and local storage succeed.

Allow the compiled fixture key in release builds only when acceptance-test-hooks is enabled and the existing file-storage isolation guard passes. The response must use the exact fixture key ID and an HTTP loopback origin. Ordinary release binaries retain production-only verification. Env sync and platform connections use one verifier so both paths enforce the same origin and isolation checks.

The integration tests exercise the non-test library through signed HTTP responses in isolated subprocesses. They cover valid responses, tampered responses, invalid storage isolation, and remote or TLS origins. CI runs the tests in optimized builds with and without the acceptance feature.

Validation on Linux ARM64 with Rust 1.94.0:

  • cargo clippy --workspace --all-targets --locked -- -D warnings: passed.

  • cargo fmt --check: passed.

  • cargo build --workspace --locked: passed.

  • Fast libraries and integrations: 6,217 passed.

  • Serial CLI unit tests: 5,109 passed.

  • CLI binary surfaces: 97 passed.

  • Optimized signature tests: three passed with the feature and three passed without it, on Linux and macOS.

  • The new reproduction failed before the fix and passed afterward.

  • Full isolated nextest gate: 14,203 passed, 21 skipped.

  • Ignored real-world audit fixture: one passed.

Registry release certification uses a locally compiled optimized binary, as requested by the maintainer; it does not wait for a scheduled CI artifact.

@tolgaergin
tolgaergin merged commit 13ab28b into main Sep 14, 2026
16 checks passed
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