Make WordPress Core


Ignore:
Timestamp:
05/03/2023 10:15:27 PM (2 years ago)
Author:
johnbillion
Message:

Build/Test Tools: Restrict the permissions granted to jobs on GitHub Actions

The permissions key in a job declares the GitHub permissions that are granted to the token that's used by the job. Restricting the permissions reduces the impact that a vulnerability in the CI system can have.

Props desrosj, johnbillion

See #57865

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/.github/workflows/test-old-branches.yml

    r55507 r55715  
    1313    - cron: '0 0 15 * *'
    1414
     15# Disable permissions for all available scopes by default.
     16# Any needed permissions should be configured at the job level.
     17permissions: {}
     18
    1519jobs:
    1620  dispatch-workflows-for-old-branches:
    1721    name: ${{ matrix.workflow }} for ${{ matrix.branch }}
    1822    runs-on: ubuntu-latest
     23    permissions:
     24      actions: write
    1925    timeout-minutes: 20
    2026    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
Note: See TracChangeset for help on using the changeset viewer.