Defensive Security & Blue Team SecurityWeek 3 weeks ago

Malicious B-tree NPM Package Accumulates Millions of Downloads

CN
CyberNew Threat Research Desk
• Original Reporting: SecurityWeek
CyberNew Threat Intel Assessment
Assessed Severity: MEDIUM
Impacted Surface
Enterprise Perimeter & Network Defense
Intelligence Sector
Defensive Security & Blue Team

Analyst Takeaway

"The NPM ecosystem has suffered another supply chain attack in which a malicious package has accumulated millions of downloads, Checkmarx reports. Still ongoing, the campaign has managed to bypass NPM’s recent protections by hiding a malicious trigger in the package’s JavaScript prototype code, rather than using an install script that could be detected by security solutions. Instead of targeting..."

Recommended Defense & Mitigation

  • Threat Monitoring: Ingest published IOCs into SIEM/EDR detection rules for continuous telemetry monitoring.
  • Security Awareness: Alert staff and maintain baseline endpoint hardening across endpoints.
Curated & Verified by CyberNew Threat Intelligence Desk Standard Defense Framework (NIST / MITRE ATT&CK)
Vulnerability

The NPM ecosystem has suffered another supply chain attack in which a malicious package has accumulated millions of downloads, Checkmarx reports.

Still ongoing, the campaign has managed to bypass NPM’s recent protections by hiding a malicious trigger in the package’s JavaScript prototype code, rather than using an install script that could be detected by security solutions.

Instead of targeting highly popular packages for fast propagation, and likely immediate detection, the threat actor built trust by creating a legitimate-looking GitHub repository.

The malicious package, indexed-btree, mimics the legitimate B-tree/indexing utility sorted-btree, and has reached 2 million weekly downloads before being detected, Checkmarx says.

To ensure the package’s popularity, the threat actor created a GitHub account and added seemingly legitimate commits to the indexed-btree repository.

“A GitHub repository is something that attackers don’t usually bother creating. This one is clever enough to not include the malicious code. Additionally, the presence of many commits can aid in making it look like a legit repository,” Checkmarx notes.

Advertisement. Scroll to continue reading.

The threat actor hid malicious code in the library’s main function, the BTree.prototype.set method, to trigger JavaScript code containing the malware’s first stage.

Written By Ionut Arghire

Source Verification & Original Intelligence

This threat report was reviewed by CyberNew analysts and cross-referenced with primary security disclosures from SecurityWeek.

Primary Advisory →