fix(security): address audit findings in CLI and scripts#201
Open
freQuensy23-coder wants to merge 1 commit intonextlevelbuilder:mainfrom
Open
fix(security): address audit findings in CLI and scripts#201freQuensy23-coder wants to merge 1 commit intonextlevelbuilder:mainfrom
freQuensy23-coder wants to merge 1 commit intonextlevelbuilder:mainfrom
Conversation
- Replace exec()/execSync() with execFile()/execFileSync() in extract.ts and sync-brand-to-tokens.cjs to prevent command injection - Add Zip Slip path traversal protection after ZIP extraction in extract.ts - Add html.escape() to all user-provided data in render-html.py and generate-slide.py to prevent XSS in generated HTML - Add URL sanitization for href attributes in generate-slide.py CTA slides - Add download size limit (50MB) and tag_name semver validation in github.ts - Add .coverage to .gitignore and remove committed .coverage SQLite file Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
|
@claude review |
|
I'll analyze this and get back to you. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
exec()/execSync()withexecFile()/execFileSync()inextract.tsandsync-brand-to-tokens.cjsto prevent shell metacharacter injectionextract.tshtml.escape()to all user-provided data inrender-html.pyandgenerate-slide.py; add URL sanitization blockingjavascript:URIs in CTA slide hrefstag_nameingithub.ts.coverageSQLite file, add.coverageto.gitignoreTest plan
npx tsc --noEmitto verify CLI compiles afterextract.tschangespython3 render-html.pywith a brand name containing<script>to confirm it's escapedpython3 generate-slide.py --demoto verify slides still render correctlynode sync-brand-to-tokens.cjsto verify token sync still works (exits cleanly when no brand-guidelines.md present)🤖 Generated with Claude Code