You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(ci): check-trusted-trigger proceeds on a PR whose base is not the default branch #8979
area: securitySecurity-relevant: vulnerability, hardening, or disclosure follow-up.needs-humanHuman-in-the-loop required; autonomous sessions must not resolve items carrying this.status: confirmedA maintainer confirmed the item is real and in scope; ready to be worked.
check-trusted-trigger.mjs returns proceed: true for a pull request without checking that the PR's base is the default branch (.github/actions/check-trusted-trigger/check-trusted-trigger.mjs:812-822). It does check the default branch on its other paths (requireOnDefaultBranch, :298; push and dispatch, :419-464), but not on pull.base.ref. A trusted author's PR into a non-default branch could therefore pass the trust check.
Fix
Stop with a named reason when pull.base.ref is not the repository's default branch, unless a caller explicitly allows other bases. Add a test for each case.
Acceptance criteria
A PR whose base is not the default branch stops with a named reason.
A PR into the default branch still proceeds.
The PR's CI runs check-trusted-trigger.test.mjs, and it passes.
Attended: .github/** is protected, so this goes to Automation Lanes, with a Security & Cost pass.
area: securitySecurity-relevant: vulnerability, hardening, or disclosure follow-up.needs-humanHuman-in-the-loop required; autonomous sessions must not resolve items carrying this.status: confirmedA maintainer confirmed the item is real and in scope; ready to be worked.
Activity