migrate-content
Audited by Socket on Oct 31, 2026
2 alerts found:
Anomalyx2This fragment is documentation and sample code for content migration and rendering, with no evident malicious behavior or credential theft. Its main risks are SSRF through unrestricted fetch(a.url), path traversal through content- or argument-derived filesystem paths, and unsafe MDX/HTML rendering if content is untrusted or sanitization is bypassed. Severity is moderate when these inputs are untrusted; constrain asset destinations, validate paths, and sanitize or safely compile content.
This is a content migration and seeding script, not clear malware: it contains no evident credential theft, persistence, or remote-control behavior. Its main security risks are content-driven outbound requests to arbitrary media URLs, unrestricted reads of asset localFile paths, and a production-database guard that relies on exact connection-string comparisons. These risks are conditional on running the script with untrusted content, especially with --yes; no specific suspicious domain, URL, or IP is hardcoded. Overall severity is moderate and the inputs and database target should be validated and constrained before use.