fix: resolve SonarCloud security hotspots for clear-text protocols and npm ignore-scripts#397
Conversation
…d npm ignore-scripts - Add NOSONAR comments to localhost-only HTTP URLs in agent-test-helper.sh (OpenCode dev server on localhost:4096, TLS not needed for loopback) - Add --ignore-scripts to npm install in schema-validator-helper.sh (prevents arbitrary script execution from npm packages)
Summary of ChangesHello @marcusquinn, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the project's security posture by resolving all identified SonarCloud security hotspots within shell scripts. It clarifies intentional use cases for clear-text protocols in local development environments and mitigates potential risks associated with Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
WalkthroughTwo helper shell scripts are updated: Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🔍 Code Quality Report�[0;35m[MONITOR]�[0m Code Review Monitoring Report �[0;34m[INFO]�[0m Latest Quality Status: �[0;34m[INFO]�[0m Recent monitoring activity: 📈 Current Quality Metrics
Generated on: Fri Feb 6 18:38:05 UTC 2026 Generated by AI DevOps Framework Code Review Monitoring |
|
There was a problem hiding this comment.
Code Review
This pull request effectively addresses the identified SonarCloud security hotspots. The additions of NOSONAR comments in agent-test-helper.sh are well-justified, clearly documenting that clear-text HTTP is intentional for localhost-only development server communication, which does not require TLS. Furthermore, the inclusion of --ignore-scripts in the npm install command within schema-validator-helper.sh is a significant security enhancement, preventing potential arbitrary script execution from npm packages. Overall, these changes improve the project's security posture and clarity regarding intentional design choices.



Summary
Resolves all 9 open SonarCloud security hotspots on the
mainbranch (new code period):shell:S5332("Make sure that using clear-text protocols is safe here.") inagent-test-helper.sh- Added NOSONAR comments documenting that HTTP is intentional for localhost-only OpenCode dev server communication (loopback, no TLS needed)shell:S6505("Omitting --ignore-scripts can lead to execution of shell scripts.") inschema-validator-helper.sh- Added--ignore-scriptsflag tonpm installto prevent arbitrary script execution from npm packagesChanges
agent-test-helper.sh# NOSONARsuppression on URL construction and eachcurlcall to the local OpenCode server APIlocalhost:4096(loopback only)schema-validator-helper.sh--ignore-scriptstonpm installcommand for@adobe/structured-data-validator,@marbec/web-auto-extractor, andnode-fetch(pure JS packages that don't require post-install scripts)# NOSONARcomment that was insufficient to suppress the hotspotSonarCloud Reference
https://sonarcloud.io/project/security_hotspots?id=marcusquinn_aidevops&branch=main&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true
Summary by CodeRabbit