beautiful-mermaid

Warn

Audited by Gen Agent Trust Hub on Aug 26, 2026

Risk Level: MEDIUMEXTERNAL_DOWNLOADSREMOTE_CODE_EXECUTIONPROMPT_INJECTION
Full Analysis
  • [EXTERNAL_DOWNLOADS]: The scripts/render.ts script dynamically installs the beautiful-mermaid package from the public NPM registry at runtime using shell commands.
  • [REMOTE_CODE_EXECUTION]: The ensurePackage function in scripts/render.ts utilizes child_process.execSync to run npm install or bun add for dependencies, introducing a risk of executing untrusted code or commands if the environment is compromised.
  • [PROMPT_INJECTION]: The skill processes user-supplied Mermaid diagram syntax and interpolates the resulting SVG content directly into an HTML wrapper in scripts/create-html.ts without sanitization. This file is subsequently opened in a browser using agent-browser, creating a vector for Cross-Site Scripting (XSS) or data exfiltration via malicious Mermaid payloads.
  • Ingestion points: User-provided Mermaid code passed as string arguments or files to scripts/render.ts.
  • Boundary markers: Absent. The rendered SVG is directly inserted into the HTML body.
  • Capability inventory: The skill uses agent-browser to open the generated HTML, which could be leveraged to execute embedded scripts.
  • Sanitization: There is no filtering or sanitization performed on the Mermaid code or the SVG output to prevent the execution of malicious HTML/JS elements.
Audit Metadata
Risk Level
MEDIUM
Analyzed
Aug 26, 2026, 06:34 PM