minimax-pdf
Audited by Socket on Aug 24, 2026
2 alerts found:
SecurityAnomalyNo confirmed malicious payload (e.g., backdoor/exfiltration/credential theft) is evident in the provided fragment. However, the code executes external package-manager commands synchronously and can install Chromium at runtime via `npx playwright install chromium` (with `shell: true`), which materially increases supply-chain integrity risk and reduces reproducibility. Additionally, the render pipeline can cause outbound network requests during HTML/CSS rendering when third-party resources (e.g., fonts) are referenced, creating privacy and sandboxing concerns. Treat as security-relevant and restrict/approve installation steps; pin versions and run in a controlled environment with network controls.
This module is a PDF rendering utility with significant security-relevant behaviors: it can execute code from newly installed dependencies at runtime via unpinned pip installation (with '--break-system-packages'), and it allows untrusted JSON to reference arbitrary local font and image file paths that may be embedded into the generated PDF. The math/chart/flowchart rendering pipeline further increases the risk of denial-of-service through compute-intensive rendering driven by attacker-controlled data. No clear evidence of overt malware (exfiltration/backdoor/reverse shell) is present in the snippet, but supply-chain and local file inclusion/confidentiality risks are meaningful.