Skip to content

fleet_release_bins wet witness: clear the runner's credential env; pin the temp root - #12703

Merged
gunbai-bot[bot] merged 4 commits into
mainfrom
session/neat-moth-20-relbins-env
Sep 30, 2026
Merged

gunbai-bot[bot] merged 4 commits into
mainfrom
session/neat-moth-20-relbins-env

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Part of the wet-witness host-premise census (docs/plans/wet-witness-host-premise-census.md, #12652), the latent batch deep-ferret-305 chose.

test.claim.long.fleet_release_bins_key_witness fixture_env depended on two things about the runner. First, that it exports no credential-shaped variable (release_bins_credential_pattern). Second, that no ancestor of mktemp -d (which follows TMPDIR) holds .cargo/config*. If either failed, release_bins_environment_statements refused with CredentialInBuildEnvironment, or release_bins_ancestor_statements refused with AncestorCargoConfigPresent, and the positive claims went red.

The fixture now:

  • unsets every name matching release_bins_credential_pattern, the same authority the guard reads;
  • creates its temp root at /tmp/gunbc_release_bins.XXXXXX.

The RED claims export a credential or plant an ancestor config after the fixture runs, so they still discriminate.

Local wet receipt: claim_batch --wet --source-root dag --source-root src/v2 --entry dag/test/claim/long/fleet_release_bins_key_witness_test.dag --functions <all 26>, uid 1000, with a hostile runner environment: CARGO_REGISTRY_TOKEN=runner-leak and TMPDIR=<dir>/t, where <dir>/.cargo/config.toml exists.

  • this head 58969ecec589a4ad2ce4b7a83b50a590d274991a (the working tree, committed unchanged): exit 0, 26/26 PASS.
  • control: main at 584c07d in the same environment: exit 1, 5 FAIL: release_bins_unchanged_inputs_key_equally, release_bins_release_opt_level_override_changes_the_key, release_bins_multiline_rustflags_keys_apart_from_its_first_line, release_bins_RED_compiler_override_refuses, release_bins_RED_ancestor_cargo_config_refuses. The two REDs fail because the credential refusal fires ahead of the refusal each one expects.

🤖 Generated with Claude Code

gunbc-ci-auto-heal and others added 4 commits September 29, 2026 21:25
…and pin the temp root

A runner exporting a registry token, or a TMPDIR under a home holding
.cargo/config.toml, turned the positive claims into CredentialInBuildEnvironment
or AncestorCargoConfigPresent (RFM wet_witness_keyed_to_the_runner_not_its_subject).
The fixture now unsets release_bins_credential_pattern names and pins mktemp
under /tmp; the RED claims set their token or config afterward, so they still
discriminate.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… nodes, not an eval'd string (review 73025)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor Author

Addressed review 73025 in 96ce6d4a8b2d0fa785a078c48c52afd65cbdf5ae. The eval of a concatenated loop is gone. The step is now unset $(env | grep -oE <release_bins_credential_pattern> | cut -d= -f1), built entirely from grammar nodes: cmd/cmdl/lit, bash_build_pipe twice, and bash_build_word_cmdsubst. The command substitution emits unquoted (bash_word_cmdsubst_source_text), so its output word-splits into the names and no loop is needed. The pattern is still the single gunbc.fleet_release_bins_key authority, and the grep is spelled the same way release_bins_environment_statements spells its own.

Local wet receipt at 96ce6d4a8b2d0fa785a078c48c52afd65cbdf5ae (working tree committed unchanged): same command and same hostile environment as the PR body (CARGO_REGISTRY_TOKEN=runner-leak, TMPDIR under a .cargo/config.toml), exit 0, 26/26 PASS. The run was on 8c710f4 plus this change, which is exactly this head.

— sent from neat-moth-20

@gunbai-bot
gunbai-bot Bot added this pull request to the merge queue Sep 30, 2026
Merged via the queue into main with commit c953db9 Sep 30, 2026
5 checks passed
@gunbai-bot
gunbai-bot Bot deleted the session/neat-moth-20-relbins-env branch September 30, 2026 07:22
@briansrls
briansrls restored the session/neat-moth-20-relbins-env branch September 30, 2026 07:24
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.

0 participants