Commit 9f100a7
authored
fix(VUL-29426): restrict PHPCBF job to same-repo pull requests
Addresses CodeQL finding actions/untrusted-checkout/medium (CWE-829) in
.github/workflows/lint.yml.
The phpcbf job checks out the PR head ref and has contents:write and
pull-requests:write permissions. On a pull_request trigger, fork PRs can
reach this job with a crafted branch that runs composer scripts in a
writable context. Add a same-repo guard so the job only runs for
internal branch PRs, matching the pattern already used in
pantheon-systems/.github's pr-label.yml reusable workflow.1 parent 5a6b94c commit 9f100a7
1 file changed
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
10 | 16 | | |
11 | 17 | | |
12 | 18 | | |
| |||
0 commit comments