mermaid-diagrams
Warn
Audited by Gen Agent Trust Hub on Jul 15, 2026
Risk Level: MEDIUMCOMMAND_EXECUTIONEXTERNAL_DOWNLOADS
Full Analysis
- [COMMAND_EXECUTION]: The script
scripts/validate-mermaid.shcontains a code injection vulnerability. It interpolates a shell variable ($FILE) directly into a Node.jsnode -ecommand string within single quotes. If an attacker provides a filename containing a single quote and arbitrary JavaScript (e.g.,test.mmd', 'utf-8'); require('child_process').execSync('whoami'); //), it could result in arbitrary code execution on the host system. - [EXTERNAL_DOWNLOADS]: The skill instructions frequently reference
npx @mermaid-js/mermaid-cliandhttps://cdn.jsdelivr.net/npm/mermaid, which involve downloading and executing code from the NPM registry and JSDelivr CDN. While these are well-known services, they constitute external code dependencies. - [DYNAMIC_EXECUTION]: The skill provides snippets of JavaScript (for PDF generation using Puppeteer) and Python (for image processing) in the
references/directory. These are intended for runtime execution to fulfill the skill's diagramming and rendering purposes. - [PRIVILEGE_ESCALATION]: The Puppeteer configuration example in
references/pdf-rendering-pipeline.mdsuggests using the--no-sandboxand--disable-setuid-sandboxflags. While common in containerized environments, these flags disable core browser security boundaries and increase the risk when rendering untrusted HTML content.
Audit Metadata