Skip to content

Commit

Permalink
ci(pr-title-checks): Remove default GH workflow permissions and docum…
Browse files Browse the repository at this point in the history
…ent risk of `pull_request_target` workflow trigger. (#633)
  • Loading branch information
kirkrodrigues authored Dec 12, 2024
1 parent 6dd8fc1 commit 909e19e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/clp-pr-title-checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,16 @@ name: "clp-pr-title-checks"

on:
pull_request_target:
# NOTE: Workflows triggered by this event give the workflow access to secrets and grant the
# `GITHUB_TOKEN` read/write repository access by default. So we need to ensure:
# - This workflow doesn't inadvertently check out, build, or execute untrusted code from the
# pull request triggered by this event.
# - Each job has `permissions` set to only those necessary.
types: ["edited", "opened", "reopened"]
branches: ["main"]

permissions: {}

concurrency:
group: "${{github.workflow}}-${{github.ref}}"

Expand Down

0 comments on commit 909e19e

Please sign in to comment.