render-plans-to-html
Audited by Socket on Aug 25, 2026
2 alerts found:
AnomalySecurityThis module is a typical filesystem-based installer/uninstaller that copies a local package into user-controlled directories, then runs `npm install` there and creates a CLI link. No direct malicious payload, obfuscation, or data-exfiltration behavior is evident in the code shown. However, it materially increases supply-chain risk by executing npm dependency installation (with reduced audit visibility) and it force-deletes and recreates destination directories that can be influenced by environment variables.
This module is not overtly malicious (no network calls, credential handling, or execution primitives), but it is a high-risk HTML/XSS assembler when any of the following inputs are untrusted: `docs[*].bodyHtml` / `opts.overviewHtml`, `docs[*].id`, and `refs[*].url`. It directly injects raw HTML (`bodyHtml`) and uses unescaped values in security-relevant contexts (`id` attributes and `href` attribute without URL/scheme validation). If callers fully sanitize/allowlist these fields before invocation, practical risk is reduced; otherwise, the fragment can produce XSS payloads.