Malicious code in cache-cleanup-module (npm)
The cache-cleanup-module npm package versions 2.5.0 and 2.6.0 contain malicious code that allows a remote operator to trigger recursive deletion of the entire current working directory on any system running the package. This occurs via a hardcoded third-party endpoint and static API key that, when returning allowed:true, causes the package's runOperation() function to delete all files and folders except the module file itself. The package's stated purpose of safe cache cleanup is not reflected in its behavior, posing a severe risk of data loss.
AI Analysis
Technical Summary
The cache-cleanup-module npm package (versions 2.5.0 and 2.6.0) exports a runOperation() function that queries a hardcoded third-party endpoint authenticated with a static API key. If the endpoint responds with allowed:true, the function recursively deletes every entry in the caller's current working directory or a supplied path using fs.rmSync and fs.unlinkSync, excluding only the module file. There is no filtering to restrict deletion to cache or build artifact paths, enabling the remote operator to wipe arbitrary directories on the victim's machine at will. This behavior is malicious and contradicts the package's claimed purpose.
Potential Impact
Any user or system invoking runOperation() in the affected versions risks complete deletion of the current working directory's contents, leading to potential loss of critical data and disruption of operations. The remote operator has unilateral control over when the destructive action occurs, making this a high-impact supply chain threat. There is no indication of active exploitation in the wild yet.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately cease using versions 2.5.0 and 2.6.0 of cache-cleanup-module. Remove the package from all projects and replace it with trusted alternatives. Monitor for any unauthorized deletions and restore data from backups if necessary. Patch status is not yet confirmed — check the vendor advisory or npm repository for updates.
Malicious code in cache-cleanup-module (npm)
Description
The cache-cleanup-module npm package versions 2.5.0 and 2.6.0 contain malicious code that allows a remote operator to trigger recursive deletion of the entire current working directory on any system running the package. This occurs via a hardcoded third-party endpoint and static API key that, when returning allowed:true, causes the package's runOperation() function to delete all files and folders except the module file itself. The package's stated purpose of safe cache cleanup is not reflected in its behavior, posing a severe risk of data loss.
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 cache-cleanup-module npm package (versions 2.5.0 and 2.6.0) exports a runOperation() function that queries a hardcoded third-party endpoint authenticated with a static API key. If the endpoint responds with allowed:true, the function recursively deletes every entry in the caller's current working directory or a supplied path using fs.rmSync and fs.unlinkSync, excluding only the module file. There is no filtering to restrict deletion to cache or build artifact paths, enabling the remote operator to wipe arbitrary directories on the victim's machine at will. This behavior is malicious and contradicts the package's claimed purpose.
Potential Impact
Any user or system invoking runOperation() in the affected versions risks complete deletion of the current working directory's contents, leading to potential loss of critical data and disruption of operations. The remote operator has unilateral control over when the destructive action occurs, making this a high-impact supply chain threat. There is no indication of active exploitation in the wild yet.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately cease using versions 2.5.0 and 2.6.0 of cache-cleanup-module. Remove the package from all projects and replace it with trusted alternatives. Monitor for any unauthorized deletions and restore data from backups if necessary. Patch status is not yet confirmed — check the vendor advisory or npm repository for updates.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-16078
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6aa15f72acd9273b496181c9
Added to database: 09/09/2026, 13:30:26 UTC
Last enriched: 09/09/2026, 13:54:30 UTC
Last updated: 09/09/2026, 18:35:12 UTC
Views: 4
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.