Skip to content

security(gha): fix potential for shell injection - #4099

Merged
antonpirker merged 1 commit into
masterfrom
mdtro/fix-gha-injection
Feb 26, 2025
Merged

antonpirker merged 1 commit into
masterfrom
mdtro/fix-gha-injection

Conversation

@mdtro

@mdtro mdtro commented Feb 25, 2025

Copy link
Copy Markdown
Contributor

Running these workflows is gated pretty well, but this mitigates the potential for a script injection attack by passing the input to an intermediary environment variable first.

See https://docs.github.com/en/actions/security-for-github-actions/security-guides/security-hardening-for-github-actions#example-of-a-script-injection-attack for more details.

@mdtro
mdtro requested review from a team and antonpirker February 25, 2025 14:24
@codecov

codecov Bot commented Feb 25, 2025 •

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 79.52%. Comparing base (189e4a9) to head (c2c2f66).
Report is 1 commits behind head on master.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4099      +/-   ##
==========================================
- Coverage   79.55%   79.52%   -0.03%     
==========================================
  Files         140      140              
  Lines       15521    15521              
  Branches     2631     2631              
==========================================
- Hits        12347    12343       -4     
- Misses       2338     2340       +2     
- Partials      836      838       +2     

see 3 files with indirect coverage changes

@antonpirker antonpirker left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! Thank's @mdtro for discovering and fixing this!

@antonpirker
antonpirker merged commit 07d2dce into master Feb 26, 2025
@antonpirker
antonpirker deleted the mdtro/fix-gha-injection branch February 26, 2025 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants