Skip to content

Let create-release's release jobs block unlisted egress behind an opt-in input #912

Open
1 of 1 issue completed
Open

Description

@devantler

🤖 Generated by the Agentic Engineer

Evidence

  • create-release's two release jobs hold the release App token and run harden-runner with egress-policy: audit, which records outbound connections and blocks none (parent Block unlisted egress in the catalogue's credential-holding publish and release jobs #628).
  • Measured on 2026-11-12 from StepSecurity's public run insights: across 12 successful release runs in 5 consumer repositories (ksail, platform, go-template, world-at-ruin, wedding-app), the ordinary Release job reached only github.com:443, api.github.com:443 and registry.npmjs.org:443, with telemetry present in every run. The list is on Block unlisted egress in the catalogue's credential-holding publish and release jobs #628.
  • The protected-source Release job (protected-release: true) did not run in that window, so its list is not measured yet.
  • Unlike the two publishers, this workflow's revision is not part of a signing identity Platform verifies, so the change needs no other approval.

Audience / problem

Every repository that releases through this workflow, about 20 of them. A compromised dependency or tool inside the release job could send the release token to any host today.

Hypothesis

If both release jobs can run harden-runner in block mode with that three-host allow-list behind a default-off input, a consumer can opt in without writing any allow-list, and an unlisted host is refused with a clear message.

Success signal

One release of a consumer that opted in succeeds in block mode, and a control run proves an unlisted host is refused.

Smallest useful change

  • Add a default-off workflow_call input (for example block-egress: false) that switches both release jobs to egress-policy: block with the measured allow-list kept in the workflow beside the step.
  • Measure the protected-source job first (one protected release run, or the insights of the next one), and add anything it needs to its list.
  • Leave offline-test and every consumer's default unchanged.

Acceptance criteria

  • Both release jobs run in block mode when the input is set and in audit mode otherwise; both states are covered by a test. Verified: feat(create-release): let callers block unlisted release egress #913 run 43333781613 at merged head 505123d6 (block job 131585571108, audit job 131585571207, both success).
  • A test proves an unlisted host is refused in block mode and the failure names it. Verified: job 131585571108 refused example.com (curl exit 7) and harden-runner logged domain not allowed: example.com.
  • One consumer release succeeds with the input set before anything defaults to it.
  • Consumers that do not set the input see no change. Verified: ascoachingogvaner (create-release v21.3.3, input unset) published v1.15.3 in run 43456255879 with egress-policy: audit.

Rough size: S.

Activity

  1. moved this to 🫴 Ready in 🌊 Project Boardon Nov 12, 2026
  2. added a commit that references this issue on Nov 12, 2026
  3. moved this from 🫴 Ready to 🏃🏻‍♂️ In Progress in 🌊 Project Boardon Nov 12, 2026
  4. devantler commented on Nov 13, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Progress (PR #913 at 505123d). The opt-in block-egress input is implemented and both states were executed in CI:

    • Block mode ([Test] Create Release - No Issue Side Effects / Release egress probe, job 131585571108): reached api.github.com, github.com and registry.npmjs.org; example.com was refused (curl exit 7), and harden-runner recorded domain not allowed: example.com. for that attempt.
    • Audit mode ([Test] Create Release - Dry Run / Release egress probe, job 131585571207): reached all three listed hosts and example.com.

    Still open here: a real opted-in release by one consumer, which is the remaining proof before anything defaults to block mode. Check two points in that trial:

    1. setup-node finds Node 22 in the runner toolcache, so it fetches nothing. If an image drops Node 22, setup-node downloads it from a host the list omits, and the release fails closed.
    2. A caller whose semantic-release GitHub plugin uploads release assets also reaches uploads.github.com, which the list omits. The measured callers upload none.
  5. devantler commented on Nov 13, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Progress — last acceptance criterion. #913 shipped the opt-in input in v21.3.0. devantler-tech/go-template#523 (merged 2026-11-13, tracked by devantler-tech/go-template#522) switched go-template's own releases to block mode; generated projects stay in audit mode because they own their release configuration and may need other hosts.

    • Branch trial, run 43376078534: egress-policy: block; App token, checkout, npm and semantic-release all ran; nothing published (not main).
    • First run on main, run 43379607353 at 9d4e0ffa: success in block mode; semantic-release found no releasable change (a ci: commit), so no release was created yet.

    Still open: the release-creation call itself. The next feat/fix merge into go-template publishes a release in block mode; its run decides this criterion (success → close; a refused host → revert #523's setting and add the host here).

  6. devantler commented on Nov 13, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Status, 13 November ~17:10Z: three of four criteria are met. The last one waits on a go-template release.

    • Criteria 1 and 2 ticked. CI run 43333781613 on feat(create-release): let callers block unlisted release egress #913's merged head 505123d6 covers both modes. The block-mode probe (job 131585571108) refused example.com, and harden-runner named the host. The audit-mode probe (job 131585571207) reached it.
    • Criterion 4 ticked. ascoachingogvaner calls create-release v21.3.3 without setting the input. It published v1.15.3 in run 43456255879 with egress-policy: audit.
    • Criterion 3 is still open. go-template has published nothing since v1.5.13 (11 November). Its two main Release runs in block mode both succeeded, but neither had a releasable change. There are no open go-template PRs, so the release can't be made to happen sooner.

    The wait is now recorded as an outcome blocker in the body, with the blocked label. The card moves from In Progress to Ready, as the board guide prescribes for delivered work waiting on an outside event. When the next go-template feat/fix release runs: if it publishes, close this issue. If a host is refused, revert go-template#523's setting and add that host here.

  7. moved this from 🏃🏻‍♂️ In Progress to 🫴 Ready in 🌊 Project Boardon Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Fields

    No fields configured for Security.

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions