Malicious code in modules-newline (npm)
Description
The modules-newline npm package version 0.0.6 declares its own name as a dependency and devDependency pointing to an external HTTP URL outside the official npm registry. This allows arbitrary code from an untrusted source to be fetched and executed during installation, bypassing npm registry auditing and integrity checks. The package's main file is a near-copy of another plugin but includes a comment indicating it is for security research testing. This behavior poses a risk of executing malicious code during package installation.
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The modules-newline package version 0.0.6 is configured to fetch its dependency from an external HTTP URL (http://pack.nppacks.com/npm/modules-newline) rather than the official npm registry. This URL is unpinned, uses plain HTTP (vulnerable to man-in-the-middle attacks), and is hosted on a domain unrelated to npm. Consequently, any project installing this package will execute code from this external source at install time, including lifecycle scripts within the fetched tarball. The shipped index.js is almost identical to babel-plugin-transform-define but includes a comment stating it is for security research testing. This setup effectively allows arbitrary code execution during installation, representing a supply chain risk.
Potential Impact
Projects that install modules-newline version 0.0.6, directly or transitively, risk executing arbitrary code from an untrusted external source during npm install. This can lead to compromise of the build environment or further downstream impacts depending on the executed code. The use of plain HTTP and lack of integrity verification increases the risk of man-in-the-middle attacks substituting malicious payloads.
Mitigation Recommendations
No official patch or remediation is provided in the available data. Users should avoid installing modules-newline version 0.0.6 or any package that depends on it. Review package dependencies for references to modules-newline and remove or replace them. Consider auditing package.json files for dependencies that reference external HTTP URLs outside the official npm registry. Monitor vendor advisories for updates or fixes.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-14483
- Osv Schema Version
- 1.7.4
- Ecosystems
- ["npm"]
Threat ID: 6a8d9ae7acd9273b493e173b
Added to database: 08/25/2026, 13:38:47 UTC
Last enriched: 09/10/2026, 18:49:11 UTC
Last updated: 10/02/2026, 14:22:00 UTC
Views: 33
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.