# New npm malware finds a way around install script defenses

DevFeed: [New npm malware finds a way around install script defenses](<https://devfeed.tech/articles/new-npm-malware-finds-a-way-around-install-script-defenses-55745.md>)

Original publisher: [Read original article](<https://www.infoworld.com/article/4224395/new-npm-malware-finds-a-way-around-install-script-defenses.html>)

Author: Shweta Sharma

Published: 2026-09-21T14:24:50Z

Content type: news

Language: en

Sources: [InfoWorld](<https://devfeed.tech/sources/infoworld.md>)

Topics: [software supply-chain attack](<https://devfeed.tech/topics/software-supply-chain-attack.md>), [npm](<https://devfeed.tech/topics/npm.md>), [Security](<https://devfeed.tech/topics/security.md>), [Malware](<https://devfeed.tech/topics/malware.md>), [C2](<https://devfeed.tech/topics/c2.md>), [Node.js](<https://devfeed.tech/topics/node-js.md>), [Blockchain](<https://devfeed.tech/topics/blockchain.md>), [Ethereum](<https://devfeed.tech/topics/ethereum.md>), [smart contract](<https://devfeed.tech/topics/smart-contract.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [blockchain](<https://devfeed.tech/tags/blockchain.md>), [c2](<https://devfeed.tech/tags/c2.md>), [code-security](<https://devfeed.tech/tags/code-security.md>), [code-security-cybercrime-libraries-and-frameworks-malware-security-software-development](<https://devfeed.tech/tags/code-security-cybercrime-libraries-and-frameworks-malware-security-software-development.md>), [command-and-control](<https://devfeed.tech/tags/command-and-control.md>), [cybercrime](<https://devfeed.tech/tags/cybercrime.md>), [ethereum](<https://devfeed.tech/tags/ethereum.md>), [libraries-and-frameworks](<https://devfeed.tech/tags/libraries-and-frameworks.md>), [malicious-javascript](<https://devfeed.tech/tags/malicious-javascript.md>), [malware](<https://devfeed.tech/tags/malware.md>), [node-js](<https://devfeed.tech/tags/node-js.md>), [npm](<https://devfeed.tech/tags/npm.md>), [npm-malware](<https://devfeed.tech/tags/npm-malware.md>), [payload](<https://devfeed.tech/tags/payload.md>), [process](<https://devfeed.tech/tags/process.md>), [security](<https://devfeed.tech/tags/security.md>), [smart-contract](<https://devfeed.tech/tags/smart-contract.md>), [software](<https://devfeed.tech/tags/software.md>), [software-development](<https://devfeed.tech/tags/software-development.md>), [supply-chain-attacks](<https://devfeed.tech/tags/supply-chain-attacks.md>)

## AI overview

Security researchers warn that the malicious npm package indexed-btree impersonated sorted-btree and delivered malware through normal runtime code instead of install scripts. The package fingerprinted hosts, exfiltrated data through Slack and Telegram, and used an Ethereum smart contract to manage command and control and encrypted payload retrieval.

## Source excerpt

Blocking suspicious install scripts may no longer be enough to mitigate threats from malicious JavaScript dependencies used in software supply-chain attacks. Security researchers at Checkmarx are warning of attackers using a malicious package called "indexed-btree" to impersonate the legitimate sorted-btree library, to spread malware hidden in the package's normal runtime code. The campaign abandons the preinstall and postinstall scripts common in recent attacks, instead using a core package function to deliver its payload. Checkmarx said the malicious package was downloaded nearly 2 million times per week before it was flagged and removed from the registry on September 3, 2026. This was roughly 11 weeks after the first malicious version went live, according to an independent analysis by Blogspan author Alexander Baumgärtner. The discovery comes after npm introduced tighter controls around lifecycle scripts in June. Blockchain C2 combined with Slack/Telegram data theft The malicious script was embedded directly into a runtime method "BTree.prototype.set", instead of an install hook in the package's package.json. When the method receives a particular key value, the code launches an obfuscated first-stage loader as a detached Node.js process. Once launched, the loader fingerprints the host, collecting information including the operating system architecture, hostname, CPU, memory and uptime. The data is then exfiltrated using hardcoded Slack channel and Telegram chats. The attackers hid the command-and-control (C2) server address in a smart contract on the Sepolia Ethereum testnet blockchain. "The contract exposes getter and setter functions that the malware polls instead of requesting a plain domain," Checkmarx researchers said. "This technique is more resilient to domain / IP takedown than traditional C2 approaches, since it uses the smart contract as a pointer to a new address whenever the old one gets taken down. Further in the chain, the malware creates cryptograp