Commit 7279a6f
committed
ci: correct the security claim in the windows routing comment
The comment landed in aeb7423 claimed fork PRs "therefore stay on
GitHub-hosted runners, unconditionally." That does not follow, and the same
comment supplies the reason: on `pull_request` this workflow is loaded from
the PR head. The `case "$EVENT_NAME"` block is owned by the proposed patch
exactly like the `if:` guard the comment correctly rejects. A hostile PR
deletes the branch, hardcodes the self-hosted labels into `$GITHUB_OUTPUT`,
and `runs-on` honours it. That `select-windows-runner` itself runs on
ubuntu-latest is irrelevant — the untrusted part is its output, not its host.
The path is reachable rather than theoretical: `.github/workflows/ci.yml` is
in this workflow's own `pull_request.paths`, so the edit triggers the run it
needs. This repository is public with 506 forks.
An independent audit of the routing design caught this. Leaving the claim in
place would have been worse than the original wiring error: a maintainer
reading ci.yml to decide whether flipping OCX_SELF_HOSTED_WINDOWS is safe
would have found a guarantee that does not exist, in the most authoritative
place to look for one.
What actually holds the boundary lives outside this file, where a PR cannot
reach it — the fork-PR approval policy, runner-group restrictions, and the
judgement of whoever approves the run. GitHub recommends against self-hosted
runners on public repositories for exactly this reason, and the comment now
says so rather than implying the wiring solved it.
The routing is unchanged and still worth having: it keeps honest pull
requests on GitHub-hosted runners. It is a cost control, and the comment now
describes it as one. The kill-switch comment gets the same treatment, and the
`push`/`workflow_dispatch` note now records that a trusted author is not
audited code, since merging a contributor PR to `dev` fires `push` and runs
its dependencies and postinstall hooks on the self-hosted box.
No behaviour change: comments only.1 parent 58be730 commit 7279a6f
1 file changed
Lines changed: 27 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
| 50 | + | |
54 | 51 | | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
61 | 59 | | |
62 | | - | |
63 | | - | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
64 | 73 | | |
65 | 74 | | |
66 | 75 | | |
| |||
85 | 94 | | |
86 | 95 | | |
87 | 96 | | |
88 | | - | |
89 | | - | |
90 | | - | |
91 | | - | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
92 | 103 | | |
93 | 104 | | |
94 | 105 | | |
| |||
0 commit comments