-
Notifications
You must be signed in to change notification settings - Fork 5
Fix Code Injection issues #56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -20,10 +20,12 @@ jobs: | |||||||||||||
steps: | ||||||||||||||
- name: Set matrix | ||||||||||||||
id: set-matrix | ||||||||||||||
env: | ||||||||||||||
VERSIONS: ${{ inputs.versions }} | ||||||||||||||
run: | | ||||||||||||||
versions="${{ inputs.versions }}" | ||||||||||||||
echo "Version Input :: $versions" | ||||||||||||||
matrix=$(echo "$versions" | tr "," "\n" | awk '{print "\""$1"\""}' | paste -sd "," -) | ||||||||||||||
set -e | ||||||||||||||
echo "Version Input :: $VERSIONS" | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shell interpolation of
Suggested change
Copilot uses AI. Check for mistakes. Positive FeedbackNegative Feedback |
||||||||||||||
matrix=$(echo "$VERSIONS" | tr "," "\n" | awk '{print "\""$1"\""}' | paste -sd "," -) | ||||||||||||||
echo "matrix :: [$matrix]" | ||||||||||||||
echo "matrix=[$matrix]" >> "$GITHUB_OUTPUT" | ||||||||||||||
|
||||||||||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As above, unvalidated
$VERSIONS
input is interpolated directly into shell commands, which risks code injection. Add explicit input validation or restrict accepted formats to a safe whitelist.Copilot uses AI. Check for mistakes.