Skip to content

Commit 6727113

Browse files
authored
gh workflow release: protect from ref_name attack (#1650)
It is not likely, but better to be safe.
1 parent f858795 commit 6727113

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,10 +209,11 @@ jobs:
209209
id: create_release
210210
env:
211211
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
212+
GITHUB_REF_NAME: ${{ github.ref_name }}
212213
run: |
213214
cd artifacts
214215
gh release create \
215216
--verify-tag \
216-
--title "Release ${{ github.ref_name }}" \
217-
"${{ github.ref_name }}" \
217+
--title "Release ${GITHUB_REF_NAME}" \
218+
"${GITHUB_REF_NAME}" \
218219
SHASUM256.txt *-latest/*.zip *-latest/*.tar.gz

0 commit comments

Comments
 (0)