目标达成 感谢每一位支持者 — 我们达成了 100% 目标!

目标: 1000 元 · 已筹: 1359 元

100%
← 返回恶意软件包
npm active

defi-threat-scanner

MAL-2026-4205
2026-05-26 05:55:02
OpenSSF Malicious Packages
该软件包被识别为恶意包。建议隔离受影响环境,并排查凭据泄露和异常网络连接。

Summary

Malicious code in defi-threat-scanner (npm)

凭据/密钥窃取远程访问后门安装阶段执行文件/数据外传
AI 分析整理qwen3.6
基于上游报告生成,请以下方原始证据为准。
公开使用量数据
统计周期
last-week
下载量
2
数据源
npmjs.org
下载量只代表仓库活动度,不等于已被入侵的安装数量。
受影响版本
EcosystemPackageVersion
npmdefi-threat-scanner*
npmdefi-threat-scanner2.1.1
npmdefi-threat-scanner2.1.2
npmdefi-threat-scanner2.1.3
npmdefi-threat-scanner3.1.0
npmdefi-threat-scanner3.1.1
npmdefi-threat-scanner3.1.2
npmdefi-threat-scanner3.1.3
npmdefi-threat-scanner3.2.0
npmdefi-threat-scanner3.2.1
npmdefi-threat-scanner3.2.3
npmdefi-threat-scanner3.2.5
npmdefi-threat-scanner3.2.6
npmdefi-threat-scanner3.2.7
npmdefi-threat-scanner3.2.8
恶意行为说明OpenSSF OSV
上游来源证据
展开原始 OSV JSON
{"modified":"2026-05-26T05:55:02Z","published":"2026-05-21T00:00:00Z","schema_version":"1.7.4","id":"MAL-2026-4205","aliases":["GHSA-q896-rx3q-5794"],"summary":"Malicious code in defi-threat-scanner (npm)","details":"A coordinated supply-chain attack comprising 10 npm packages published by maintainer `ddjidd5640` (1623682356@qq.com) within a 48-hour window (2026-05-19T03:55Z – 2026-05-21T04:31Z). All packages masquerade as legitimate Web3/DeFi developer security tools (MCP servers) while silently exfiltrating credentials, wallet keys, shell history, SSH keys, and environment variables on install and on every MCP tool invocation. The `postinstall` hook fetches a dynamic C2 webhook URL from `https://ddjidd564.github.io/defi-security-best-practices/config.json` (hardcoded fallback: `https://webhook.site/8d334534-1c63-4f4f-a0d7-95c446c8b233`). At runtime, `scanner.js` performs a recursive credential sweep on every MCP tool call targeting cryptocurrency wallets (`~/.ethereum`, `~/.bitcoin`, `~/.solana`), SSH keys, dotfiles, and environment variables. MCP tool handlers in `index.js` are named to solicit private key material directly from the user or AI agent (e.g., `verify_key_format`: “Private key or key material to validate”).\n\n`defi-threat-scanner` presents itself as a DeFi threat scanning MCP server. No clean prior version is known; version 2.1.2 carries the malicious `postinstall` hook and `scanner.js` payload from first publication.\n\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (ccb13e9abcc10395505678ea78773ed11d916fd9d63796012e10b34a280f1521)\nPackage presents as a DeFi security/MCP scanner but on `npm install` the postinstall hook executes an inline Node script that reads up to 200 bytes from ~/.ssh, ~/.ethereum, ~/.bitcoin, ~/.env, ~/.bash_history, ~/.zsh_history, and ~/.git-credentials, packages them with hostname/user/cwd, fetches a dynamic webhook URL from https://ddjidd564.github.io/defi-security-best-practices/config.json, and POSTs the bundle there. scanner.js exposes `_activeScan` which recursively walks crypto-wallet directories (~/.ethereum, ~/.bitcoin, ~/.solana, %APPDATA%, ~/Library/Application Support) and matches files such as keystore, wallet.json, wallet.dat, seed.txt, metamask, phantom, rabby, trust-wallet, coinbase against private-key (`0x[a-fA-F0-9]{64}`) and BIP-39 mnemonic regexes, then exfiltrates matches plus ~/.npmrc, ~/.gitconfig, ~/.git-credentials, and any process.env entry whose key contains key/secret/token/password/private/mnemonic/wallet/seed. index.js additionally beacons hostname, user, homedir, and boolean flags for PRIVATE_KEY/MNEMONIC/WALLET_KEY env-var presence on every MCP tool invocation. The C2 endpoint is resolved at runtime from the GitHub Pages config (with a webhook.site fallback), letting the attacker rotate destinations without republishing. Cover-story branding (\"DeFi Security Alliance\") targets crypto developers specifically.\n\n## Source: ghsa-malware (9196c3bcee0c1a3df8d36c637bd8174d348ddec21c2267de43448d95ad46071a)\nAny 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.\n","affected":[{"package":{"ecosystem":"npm","name":"defi-threat-scanner"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"versions":["3.2.0","3.1.2","3.1.3","3.1.1","3.1.0","3.2.1","3.2.7","2.1.1","2.1.2","2.1.3","3.2.5","3.2.3","3.2.6","3.2.8"],"database_specific":{"cwes":[{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"}],"indicators":{"domains":["ddjidd564.github.io"],"evidence_files":[{"path":"package.json","sha256":"af346d294e352dee52df065e43c5d5237f010ead58077352a6b8039bcb2fb9a5","tlsh":"b93144e1d6e8d6b723c40ac999e103025757f803f640b8dcf359410e5f8c54b8a7959c"},{"path":"scanner.js","sha256":"8c4e135499f24280cc553d6c48b4ba479fb444571814311285ea8e841d8e24c5","tlsh":"6f8209e61afa613087c395a98f57a0096227f1537605ebc477dcc2286f8913853e3bec"}],"package_integrity":[{"filename":"defi-threat-scanner-3.2.0.tgz","hashes":{"sha1":"f2b60b78103dc83c315d5ec2731f4939cb242d7c","sha512_sri":"sha512-zvcAFQLawMiXAKl37AWacPD1G5kx3ylpBleZjMOUfr/yEZbcnOrJxBwEyerbYwkJ3hRU04UWGKNZIfiprmhtfA=="}}]}}}],"references":[{"type":"WEB","url":"https://x.com/safedepio/status/2057325717453697057"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-q896-rx3q-5794"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.0"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.1.3"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.1.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.7"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/2.1.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.5"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.1.0"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.6"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/2.1.2"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.1.2"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.3"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.8"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/3.2.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/defi-threat-scanner/v/2.1.3"}],"credits":[{"name":"Amazon Inspector","type":"FINDER","contact":["actran@amazon.com"]},{"name":"SafeDep","type":"FINDER","contact":["https://safedep.io"]}],"database_specific":{"malicious-packages-origins":[{"source":"ghsa-malware","sha256":"9196c3bcee0c1a3df8d36c637bd8174d348ddec21c2267de43448d95ad46071a","import_time":"2026-05-22T03:24:54.642485801Z","id":"GHSA-q896-rx3q-5794","modified_time":"2026-05-22T02:43:00Z","ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}]},{"source":"amazon-inspector","sha256":"ccb8922ffca4caa8f3b0ab76b88d6b92c3d365ce2cf69713530d001f5b4f158d","import_time":"2026-05-26T05:51:39.979684357Z","id":"IN-MAL-2026-003961","modified_time":"2026-05-21T17:59:54Z","versions":["3.2.0"]},{"source":"amazon-inspector","sha256":"d42eda5d29415939afa12cdd313aa475eef0e5c4104ce84fb58a1ff9758c78c8","import_time":"2026-05-26T05:51:34.762520579Z","id":"IN-MAL-2026-003915","modified_time":"2026-05-21T16:41:02Z","versions":["3.1.2"]},{"source":"amazon-inspector","sha256":"d77eecc2140f0b4c8a0770dbab541c1126c084cbe2f9a536258cb5016038a3e8","import_time":"2026-05-26T05:51:39.339462449Z","id":"IN-MAL-2026-003955","modified_time":"2026-05-21T17:59:34Z","versions":["3.2.0"]},{"source":"amazon-inspector","sha256":"e5cc46f591de0d7741e258f7e60650e8f7d3c3d6a271993e878a666d3bae3ba0","import_time":"2026-05-26T05:51:37.653656474Z","id":"IN-MAL-2026-003940","modified_time":"2026-05-21T17:23:32Z","versions":["3.1.3"]},{"source":"amazon-inspector","sha256":"e5fef366d140d9c9c7d2475c2e42da2dae1e61064983dc9255c0b8b8fcf87fb6","import_time":"2026-05-26T05:51:31.038583145Z","id":"IN-MAL-2026-003886","modified_time":"2026-05-21T16:19:23Z","versions":["3.1.1"]},{"source":"amazon-inspector","sha256":"1bfb0eabcb7c3d5e5a0d9f7a8b7d6b79c40843db96955132f682bf8df000c178","import_time":"2026-05-26T05:51:26.550452761Z","id":"IN-MAL-2026-003848","modified_time":"2026-05-21T14:08:22Z","versions":["3.1.0"]},{"source":"amazon-inspector","sha256":"21f51f39b55ee445a04dc15636bb691a18f2cb27c198d5024408ac71692b0472","import_time":"2026-05-26T05:51:40.778604487Z","id":"IN-MAL-2026-003969","modified_time":"2026-05-21T18:18:25Z","versions":["3.2.1"]},{"source":"amazon-inspector","sha256":"2f32c7d24bb2b9e411d3b2b0a757ce72d78832e82548a294f24b647d4b48f09a","import_time":"2026-05-26T05:51:37.754124501Z","id":"IN-MAL-2026-003941","modified_time":"2026-05-21T17:23:32Z","versions":["3.1.3"]},{"source":"amazon-inspector","sha256":"37439f85e80fc0d42427e42e581700b54f446354e9b23830888a30b05eb989a3","import_time":"2026-05-26T05:51:52.753710375Z","id":"IN-MAL-2026-004070","modified_time":"2026-05-21T23:00:30Z","versions":["3.2.7"]},{"source":"amazon-inspector","sha256":"20c12cd11478591979898e687894c3df8c93e8df43f693bd7b42b858309c2554","import_time":"2026-05-26T05:51:09.401011729Z","id":"IN-MAL-2026-003708","modified_time":"2026-05-21T02:54:05Z","versions":["2.1.1"]},{"source":"amazon-inspector","sha256":"47852eb343d3a58719d900a257850b0855f9612f2c7fe9e7dc5142c6959cb7b9","import_time":"2026-05-26T05:51:11.955244859Z","id":"IN-MAL-2026-003728","modified_time":"2026-05-21T04:32:46Z","versions":["2.1.2"]},{"source":"amazon-inspector","sha256":"537d9252f107fffa702eab36674e2f9e222c0a15b26e883d59ef1332e17a15bf","import_time":"2026-05-26T05:51:24.301487097Z","id":"IN-MAL-2026-003830","modified_time":"2026-05-21T13:45:38Z","versions":["2.1.3"]},{"source":"amazon-inspector","sha256":"6d6a11f20a166b437712d6face0973cd8bb8429d671ee2ec575004d6e6ba879e","import_time":"2026-05-26T05:51:49.424187787Z","id":"IN-MAL-2026-004040","modified_time":"2026-05-21T21:54:39Z","versions":["3.2.5"]},{"source":"amazon-inspector","sha256":"6e3a42d9c0571963308b7492689b22f81fee9cbc9ae1147b3762e265be494b87","import_time":"2026-05-26T05:51:26.453053642Z","id":"IN-MAL-2026-003847","modified_time":"2026-05-21T14:08:22Z","versions":["3.1.0"]},{"source":"amazon-inspector","sha256":"7485d96f5d9474d562c3312181ddedcef703769dcc41468ee6b0f65ed8f8cdd4","import_time":"2026-05-26T05:51:44.755638402Z","id":"IN-MAL-2026-004001","modified_time":"2026-05-21T19:28:31Z","versions":["3.2.3"]},{"source":"amazon-inspector","sha256":"be97b729fe124de16959d4cae0c9aacff70fc7358c387001b9206e6ab2052ef3","import_time":"2026-05-26T05:51:50.887983175Z","id":"IN-MAL-2026-004053","modified_time":"2026-05-21T22:34:07Z","versions":["3.2.6"]},{"source":"amazon-inspector","sha256":"ce824351517f5954c17e045bbf787dc7874cbdeeba119703090eb99c07f4cd53","import_time":"2026-05-26T05:51:11.813688466Z","id":"IN-MAL-2026-003727","modified_time":"2026-05-21T04:32:46Z","versions":["2.1.2"]},{"source":"amazon-inspector","sha256":"5c4703bd34b7a12c94eb99510b62a9a79c1c9be4d58a9169821df767eb434d0d","import_time":"2026-05-26T05:51:34.666304747Z","id":"IN-MAL-2026-003914","modified_time":"2026-05-21T16:41:02Z","versions":["3.1.2"]},{"source":"amazon-inspector","sha256":"d27335f16964c7f1a06c1dcd353d55ddc426badcda24850c8107b9ce36812ec2","import_time":"2026-05-26T05:51:44.6502673Z","id":"IN-MAL-2026-004000","modified_time":"2026-05-21T19:28:30Z","versions":["3.2.3"]},{"source":"amazon-inspector","sha256":"da0deb5c459974c0410abcff9ef97ae26a8db92d5ebebdd13bd2b28a9f5ef7af","import_time":"2026-05-26T05:51:31.142365567Z","id":"IN-MAL-2026-003887","modified_time":"2026-05-21T16:19:23Z","versions":["3.1.1"]},{"source":"amazon-inspector","sha256":"0e0272fba71a3e93dfaddba9ad2385a81bb2937dc92f4dd6835e9d19c9c6a8e2","import_time":"2026-05-26T05:51:54.34869151Z","id":"IN-MAL-2026-004084","modified_time":"2026-05-21T23:12:26Z","versions":["3.2.8"]},{"source":"amazon-inspector","sha256":"2ca7b078736e318e0a23ea31d93c0d73c33ab69c85318269974483e544bb86d7","import_time":"2026-05-26T05:51:40.686189677Z","id":"IN-MAL-2026-003968","modified_time":"2026-05-21T18:18:25Z","versions":["3.2.1"]},{"source":"amazon-inspector","sha256":"ccb13e9abcc10395505678ea78773ed11d916fd9d63796012e10b34a280f1521","import_time":"2026-05-26T05:51:24.165862043Z","id":"IN-MAL-2026-003829","modified_time":"2026-05-21T13:45:37Z","versions":["2.1.3"]}]}}

数据来源:OpenSSF Malicious Packages · Apache-2.0