mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 22:13:26 +00:00
ci: Limit GitHub token permissions for workflows.
This limits the ability for an Action to do mischief with this token. Fixes #22786. Signed-off-by: Varun Sharma <varunsh@stepsecurity.io>
This commit is contained in:
7
.github/workflows/codeql-analysis.yml
vendored
7
.github/workflows/codeql-analysis.yml
vendored
@@ -12,8 +12,15 @@ concurrency:
|
|||||||
group: "${{ github.workflow }}-${{ github.head_ref || github.run_id }}"
|
group: "${{ github.workflow }}-${{ github.head_ref || github.run_id }}"
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
CodeQL:
|
CodeQL:
|
||||||
|
permissions:
|
||||||
|
actions: read # for github/codeql-action/init to get workflow details
|
||||||
|
contents: read # for actions/checkout to fetch code
|
||||||
|
security-events: write # for github/codeql-action/analyze to upload SARIF results
|
||||||
if: ${{!github.event.repository.private}}
|
if: ${{!github.event.repository.private}}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
|||||||
3
.github/workflows/production-suite.yml
vendored
3
.github/workflows/production-suite.yml
vendored
@@ -33,6 +33,9 @@ defaults:
|
|||||||
run:
|
run:
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
production_build:
|
production_build:
|
||||||
# This job builds a release tarball from the current commit, which
|
# This job builds a release tarball from the current commit, which
|
||||||
|
|||||||
3
.github/workflows/update-oneclick-apps.yml
vendored
3
.github/workflows/update-oneclick-apps.yml
vendored
@@ -2,6 +2,9 @@ name: Update one click apps
|
|||||||
on:
|
on:
|
||||||
release:
|
release:
|
||||||
types: [published]
|
types: [published]
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-digitalocean-oneclick-app:
|
update-digitalocean-oneclick-app:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
3
.github/workflows/zulip-ci.yml
vendored
3
.github/workflows/zulip-ci.yml
vendored
@@ -19,6 +19,9 @@ defaults:
|
|||||||
run:
|
run:
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
strategy:
|
strategy:
|
||||||
|
|||||||
Reference in New Issue
Block a user