Skip to content

test(ci): run the 3.5.0 testsuite over a loopback TCP daemon on macOS - #7691

Merged
oferchen merged 1 commit into
masterfrom
feat/uts-macos-tcp-leg
Sep 5, 2026
Merged

oferchen merged 1 commit into
masterfrom
feat/uts-macos-tcp-leg

Conversation

@oferchen

@oferchen oferchen commented Sep 5, 2026

Copy link
Copy Markdown
Owner

Extends the upstream 3.5.0 testsuite matrix across platforms: macOS ran only the
pipe transport, so accept(), the hosts allow/hosts deny decision and
peer-address resolution — the surface the 3.5.0 daemon CVEs live on — were
covered on Linux only.

Coverage before / after

pipe nonroot pipe root tcp nonroot tcp root
Linux required required required required
macOS non-required absent this PR absent

Measured, not predicted

A real run of this exact configuration on macOS, before wiring it:

155 selected / 120 run - 113 pass, 7 fail, 35 skip
+32 cells RUN that the macOS pipe leg skips, 25 of them passing
 0 regressions - nothing passing on macOS/pipe fails here
 0 macOS-only failures

All 7 failures are shared with the Linux tcp legs and already tracked: the
six-cell proto-* cluster, plus daemon-zstd-thread-exhaustion and
malicious-server-partial-basis-symlink-overwrite. The manifest records them as
fail, so the leg is non-vacuous from its first run and fires on drift. Nothing
is re-baselined.

The manifest is generated by the runner (EMIT_EXPECT_RESULT), never typed. Its
two legacy-oracle-dependent rows agree exactly with the committed Linux
nonroot/tcp manifest (daemon-auth-digest-floor pass, daemon-max-alloc-zero skip) — expected, since that leg also runs with legacy oracles off.

⚠ A prediction here was wrong by 20 cells

Crossing the Linux manifests predicted 52 cells; the executed run gives
32. Cells can skip on macOS for platform reasons the Linux manifests cannot
express. That is why the manifest comes from the run.

The same correction is why the macOS root leg is documented but not added.
Its "29 cells" figure is the same kind of prediction and needs its own executed
run (GitHub macOS runners have sudo; dispatch and take the artifact).

That said, the crossing did refute the rationale the reusable workflow carried
for declining a root leg. It argued the unlocked cells are chown/devices/dir-sgid,
already in upstream's macos.txt. Measured: 29 cells would newly run, only 3 of
the 32 privilege-keyed cells are upstream-waived, and the set is dominated by the
symlink-race and confinement family — backup-dir-symlink-race,
symlink-race-dest, temp-dir-symlink-injection, daemon-module-chdir-symlink,
operator-path-backup-symlink, all five chroot-*-inner-module. That is the
family whose Linux passes are known to rest on Landlock rather than on the
userspace confinement guard, so a platform without Landlock is the only place
that guard is tested unaided. The header now records this instead of the
refuted argument.

Consolidation

Both macOS legs share one reusable workflow via a transport input, mirroring
_upstream-testsuite.yml rather than adding a fourth copy of the job body.

Two things had to become transport-scoped or the second leg would have silently
damaged the first:

  • the emitted manifest path, and
  • the uploaded artifact name — artifact names are unique per run, not per
    job, so one shared name means the second leg clobbers the first and a later
    re-baseline diffs the wrong leg.

Verification

  • Workflows verified by parsing the committed YAML with yaml.safe_load,
    not by re-reading the intended edit — a quoting-level mistake is invisible to
    a hand check. Confirms: transport input present and defaulting to pipe;
    USE_TCP/DAEMON_TESTS_ONLY set only on the tcp leg; two callers, two
    distinct manifests.
  • tools/ci/check_pr_check_name_uniqueness.py — 78 pull_request check names,
    each with one publisher.
  • bash tools/ci/run_tools_tests.sh — 81 tests, exit 0. The manifest-header
    gate discovers and accepts the new file (header counts agree with its rows).

Not a required status check, matching the macOS pipe leg.

@github-actions github-actions Bot added the test label Sep 5, 2026
The macOS leg used only upstream's secure default - a stdio socketpair with
no listening socket - so it never reached accept(), the `hosts allow`/`hosts
deny` decision, or peer-address resolution. Every cell that needs a real bound
socket was therefore Linux-only, including the surface the 3.5.0 daemon CVEs
live on.

MEASURED on a real run of this exact configuration before adding it, not
predicted:

    155 selected / 120 run - 113 pass, 7 fail, 35 skip
    +32 cells RUN that the macOS pipe leg skips, 25 of them passing
     0 regressions - nothing passing on macOS/pipe fails here
     0 macOS-only failures

All 7 failures are shared with the Linux tcp legs and already tracked: the
six-cell proto-* cluster, plus daemon-zstd-thread-exhaustion and
malicious-server-partial-basis-symlink-overwrite. The manifest records them as
`fail`, so the leg is non-vacuous from its first run and fires on drift - it
is not a re-baseline of anything.

The manifest is GENERATED by the runner (EMIT_EXPECT_RESULT), never typed.
Its two legacy-oracle-dependent rows land on the same values the committed
Linux nonroot/tcp manifest carries (daemon-auth-digest-floor pass,
daemon-max-alloc-zero skip), which is the expected agreement: that leg runs
with legacy oracles off too, so the configurations match.

⚠ A PREDICTION FROM THE LINUX MANIFESTS SAID 52 CELLS, NOT 32. Cells can skip
on macOS for platform reasons the Linux manifests cannot express, so the
prediction over-counted by 20. That is why the committed manifest comes from
the executed run, and why the macOS ROOT leg is documented but NOT added here:
its own "29 cells" figure is the same kind of prediction and needs its own run.
The reusable workflow's header now says so, replacing a rationale the same
crossing refuted - it argued a root leg would unlock only chown/devices/dir-sgid
when the privilege-keyed set is actually dominated by the symlink-race and
confinement family.

Both legs share one reusable workflow via a `transport` input, mirroring
`_upstream-testsuite.yml`. Two things had to become transport-scoped or the
second leg would have silently damaged the first: the emitted manifest path,
and the uploaded artifact NAME - artifact names are unique per run, not per
job, so one name means the second leg clobbers the first and a later
re-baseline diffs the wrong leg.

Reported as `upstream-testsuite-macos-tcp / upstream testsuite (macOS)`; the
check-name uniqueness lint confirms 78 names each with one publisher. Not a
required context, matching the macOS pipe leg.
@oferchen
oferchen force-pushed the feat/uts-macos-tcp-leg branch from 23d71b1 to dfb3a08 Compare September 5, 2026 12:11
@oferchen
oferchen merged commit d72cc4f into master Sep 5, 2026
73 checks passed
@oferchen
oferchen deleted the feat/uts-macos-tcp-leg branch September 5, 2026 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant