beautiful-mermaid
Warn
Audited by Gen Agent Trust Hub on Nov 1, 2026
Risk Level: MEDIUMDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTIONCOMMAND_EXECUTIONEXTERNAL_DOWNLOADS
Full Analysis
- [DYNAMIC_EXECUTION]: The
scripts/render.tsfile contains anensurePackagefunction that dynamically installs thebeautiful-mermaidpackage usingnpm installorbun addviachild_process.execSync. This runtime dependency installation lacks version pinning and relies on the integrity of public package registries at execution time. - [INDIRECT_PROMPT_INJECTION]: The skill processes user-supplied Mermaid diagram code which is rendered to SVG and subsequently embedded into an HTML wrapper by
scripts/create-html.ts. The SVG content is interpolated directly into the HTML without sanitization. This creates an XSS vulnerability where malicious Mermaid code could generate an SVG with embedded scripts that execute when theagent-browsertool opens the generated HTML file. - [COMMAND_EXECUTION]: The skill's workflow involves frequent use of shell commands such as
bun run,npx tsx, andrmto manage the rendering process and clean up temporary files. While these are functional requirements, they represent a broad execution surface. - [EXTERNAL_DOWNLOADS]: The skill attempts to fetch the
beautiful-mermaidlibrary from external package registries during the diagram rendering process if it is not already present in the environment.
Audit Metadata