Skip to content

Full repo - compromised #1690

Closed
Closed

Description

@mahihyd9-hash

Key Findings

Install Hooks: preinstall script executes node setup.mjs - triggers on every npm install
Typosquatting: No - this IS the legitimate @cacheable/utils package
Malicious Code: Two heavily obfuscated files added in this version download and execute arbitrary binaries
Network Indicators: Downloads Bun binary from GitHub releases
Data Exfiltration: Math_Symbol.js contains eval() on dynamically constructed code and child_process access - enables arbitrary command execution

@cacheable/memory | score 85

2.2.0  →  2.2.1
[@cacheable/memory](https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.npmjs.com%2Fpackage%2F%40cacheable%2Fmemory&data=05%7C02%7Cmmandava%40microsoft.com%7C06f3cb7d496b4cde3c3608def214085e%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C639214365071224364%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=PDDPT5G1fk9TDw9uC80WzHUYlxGp5sVMrTzgHtoHyRg%3D&reserved=0) score 85 2.2.0 → 2.2.1

New 'preinstall' hook added in 2.2.1 that did not exist in 2.2.0 — executes 'node setup.mjs'; setup.mjs (30KB) is a heavily obfuscated dropper: imports child_process.execFileSync, fs, os, https, path; downloads a remote binary, chmod +x, executes it with Math_Symbol.js as argument, then unlinkSync to remove evidence; Math_Symbol.js (728KB) is an obfuscated payload containing eval, Function(), Buffer, fromCharCode/fromCodePoint — classic encoded-then-exec pattern; Neither setup.mjs nor Math_Symbol.js existed in the prior clean version 2.2.0; Tarball size jumped from 25KB (2.2.0) to 237KB (2.2.1) due to injected payload files; dist/index.cjs has only a trivial 1-line legitimate change — the attack is entirely in the two new files + hook injection
KEY FINDINGS (6)
• New 'preinstall' hook added in 2.2.1 that did not exist in 2.2.0 — executes 'node setup.mjs'
• setup.mjs (30KB) is a heavily obfuscated dropper: imports child_process.execFileSync, fs, os, https, path; downloads a remote binary, chmod +x, executes it with Math_Symbol.js as argument, then unlinkSync to remove evidence
• Math_Symbol.js (728KB) is an obfuscated payload containing eval, Function(), Buffer, fromCharCode/fromCodePoint — classic encoded-then-exec pattern
• Neither setup.mjs nor Math_Symbol.js existed in the prior clean version 2.2.0
• Tarball size jumped from 25KB (2.2.0) to 237KB (2.2.1) due to injected payload files
• dist/index.cjs has only a trivial 1-line legitimate change — the attack is entirely in the two new files + hook injection
INDICATORS OF COMPROMISE

Activity

  1. changed the title [-]cacheable/[email protected]. - compromised[/-] [+]Full repo - compromised[/+] on Aug 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions