Merge pull request #1511 from barakharyati/master
Some checks failed
Docs - build & deploy / docs (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.10) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.11) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.12) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.13) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.14) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.8) (push) Has been cancelled
Run tests / build (windows-latest, 3.12) (push) Has been cancelled
Run tests / build (ubuntu-latest, 3.9) (push) Has been cancelled
Run tests / build (windows-latest, 3.10) (push) Has been cancelled
Run tests / build (windows-latest, 3.11) (push) Has been cancelled
Run tests / build (windows-latest, 3.13) (push) Has been cancelled
Run tests / build (windows-latest, 3.14) (push) Has been cancelled
Run tests / build (windows-latest, 3.8) (push) Has been cancelled
Run tests / build (windows-latest, 3.9) (push) Has been cancelled
Run tests / test_docs (3.13) (push) Has been cancelled
Run tests / test_sampleproject (3.14) (push) Has been cancelled

Critical Security Fix in CICD: move PR fields into env vars to prevent injection
This commit is contained in:
Emil Stenström 2025-12-08 12:50:48 +01:00 committed by GitHub
commit 15f0956fb0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -14,14 +14,20 @@ jobs:
- name: Post to Discord (development channel)
env:
DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_DEVELOPMENT }}
TITLE: ${{ github.event.pull_request.title }}
URL: ${{ github.event.pull_request.html_url }}
USER: ${{ github.event.pull_request.user.login }}
REPO: ${{ github.repository }}
NUMBER: ${{ github.event.pull_request.number }}
TS: ${{ github.event.pull_request.created_at }}
run: |
payload=$(jq -n \
--arg title "${{ github.event.pull_request.title }}" \
--arg url "${{ github.event.pull_request.html_url }}" \
--arg user "${{ github.event.pull_request.user.login }}" \
--arg repo "${{ github.repository }}" \
--arg number "#${{ github.event.pull_request.number }}" \
--arg timestamp "${{ github.event.pull_request.created_at }}" \
--arg title "$TITLE" \
--arg url "$URL" \
--arg user "$USER" \
--arg repo "$REPO" \
--arg number "$NUMBER" \
--arg timestamp "$TS" \
'{
"username": "GitHub Pull Requests",
"avatar_url": "https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png",