From b4692eeee231478b7070c37fbc9977ca4d4e7eb2 Mon Sep 17 00:00:00 2001 From: Ale Paredes <1709578+ale7714@users.noreply.github.com> Date: Mon, 27 Jul 2026 15:24:25 -0400 Subject: [PATCH] Run PR CI on pull_request instead of pull_request_target pullrequest.yml ran fork PRs under pull_request_target, which executes untrusted PR code with repo secrets available and a privileged GITHUB_TOKEN persisted by checkout. The PR jobs reference no secrets, so plain pull_request does the same work while GitHub withholds secrets and issues a read-only token for fork runs. Co-Authored-By: Claude Fable 5 --- .github/workflows/pullrequest.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pullrequest.yml b/.github/workflows/pullrequest.yml index afab1ab..92c2d2b 100644 --- a/.github/workflows/pullrequest.yml +++ b/.github/workflows/pullrequest.yml @@ -5,7 +5,8 @@ concurrency: cancel-in-progress: true on: - pull_request_target: + # plain pull_request: fork runs get no secrets and a read-only token + pull_request: branches: [ 'main' ] jobs: