Skip to content

Commit 10f3a97

Browse files
committed
fix: add explicit support for prerelease tags while maintaining security
- Keep secure numeric-only patterns (rejecting unsafe CodeRabbit suggestion v*.*.*) - Add explicit patterns for common prerelease formats: - v1.2.3-rc1, v1.2.3-rc2 (release candidates) - v1.2.3-beta.1, v1.2.3-beta.2 (beta releases) - v1.2.3-alpha.1, v1.2.3-alpha.2 (alpha releases) - Maintain backwards compatibility with existing patterns - General v[0-9]+.[0-9]+.[0-9]+-* pattern still covers other formats This ensures -rc1 support while preventing dangerous patterns like v*.*.* that could match malicious strings like vMALICIOUS.CODE.INJECTION-hack.
1 parent 61da4b4 commit 10f3a97

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

.github/workflows/publish.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
- "v[0-9]+.[0-9]+"
1010
- "v[0-9]+.[0-9]+.[0-9]+"
1111
- "v[0-9]+.[0-9]+.[0-9]+-*"
12+
# Explicit patterns for common prerelease formats
13+
- "v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+"
14+
- "v[0-9]+.[0-9]+.[0-9]+-beta.[0-9]+"
15+
- "v[0-9]+.[0-9]+.[0-9]+-alpha.[0-9]+"
1216

1317
concurrency:
1418
group: ${{ github.workflow }}-${{ github.ref }}

0 commit comments

Comments
 (0)