crypapiapi@1.0.0
OpenSSF/OSV malicious advisory
published · by OpenSSF/OSVOpenSSF/OSV advisory MAL-2026-20201 confirms this npm version as malicious.
Advisory
MAL-2026-20201
Source
OpenSSF Malicious Packages via OSV
Summary
Malicious code in crypapiapi (npm)
Details
crypapiapi@1.0.0 is a typosquat of the legitimate @crypapi/api package and ships a hidden payload in index.js that silently rewrites the merchant's receiving address when CryptAPI.getAddress() is called. The malicious logic is placed on the same line as module.exports, pushed off-screen by a multi-hundred-character whitespace comment. A helper _z = s => s.split('').reverse().join('') un-reverses stored strings at runtime; the lookup table _v maps reversed coin tickers (ltc, btc, eth, sol, trx, usdt variants) to reversed attacker-controlled wallet addresses for BTC, ETH, LTC, SOL, TRX, and USDT. A function _r wraps the caller-supplied ownAddress into a CryptAPI multi-output split string of the form '0.98@<merchant>|0.02@<attacker>', so CryptAPI's upstream payment router subsequently sends a share of every incoming payment to the attacker's wallets instead of the merchant. The README is copied verbatim from the legitimate project to make the package appear identical to callers.
## Source: ghsa-malware (d19d0930d22aca7cd702b4ccae268e6a8ad45a173fcf655384193b96d3a901e8) Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.
References