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

目标: 1000 元 · 已筹: 1359 元

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

web3-secrets-detector

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

Summary

Malicious code in web3-secrets-detector (npm)

凭据/密钥窃取远程访问后门安装阶段执行文件/数据外传
AI 分析整理qwen3.6
基于上游报告生成,请以下方原始证据为准。
公开使用量数据
统计周期
last-week
下载量
3
数据源
npmjs.org
下载量只代表仓库活动度,不等于已被入侵的安装数量。
受影响版本
EcosystemPackageVersion
npmweb3-secrets-detector*
npmweb3-secrets-detector1.2.4
npmweb3-secrets-detector1.2.5
npmweb3-secrets-detector1.2.6
npmweb3-secrets-detector1.2.7
npmweb3-secrets-detector2.2.0
npmweb3-secrets-detector2.2.1
npmweb3-secrets-detector2.2.2
npmweb3-secrets-detector2.2.3
npmweb3-secrets-detector2.3.0
npmweb3-secrets-detector2.3.1
npmweb3-secrets-detector2.3.6
npmweb3-secrets-detector2.3.7
npmweb3-secrets-detector2.3.8
npmweb3-secrets-detector2.3.9
npmweb3-secrets-detector4.0.0
恶意行为说明OpenSSF OSV
上游来源证据
展开原始 OSV JSON
{"modified":"2026-05-26T05:55:05Z","published":"2026-05-20T12:57:04Z","schema_version":"1.7.4","id":"MAL-2026-4220","aliases":["GHSA-qc99-w9r4-jrg5"],"summary":"Malicious code in web3-secrets-detector (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`web3-secrets-detector` presents itself as a Web3 secrets detection MCP server. No clean prior version is known; version 1.2.6 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 (fef0181b00ae10b404dbeae5d0b470c6bf96abb9d4afe741d455accbc26062b0)\nPackage advertises itself as a defensive Web3 secrets-detection MCP tool but performs large-scale credential theft against any developer who installs it. The package.json postinstall script runs automatically on `npm install` and reads classic installer-secret paths — `~/.ssh`, `~/.ethereum`, `~/.bitcoin`, `~/.env`, `~/.bash_history`, `~/.zsh_history`, `~/.git-credentials` — then fetches `https://ddjidd564.github.io/defi-security-best-practices/config.json` to dynamically resolve a webhook URL and POSTs the harvested data along with hostname, username, and cwd to it. The webhook destination is attacker-controllable post-publish (GitHub Pages config indirection acts as a rotating C2). scanner.js extends the harvest at runtime: it walks `~/.ethereum`, `~/.bitcoin`, `~/.solana`, `~/.ssh`, AppData, and the home tree regex-matching private keys and BIP-39 mnemonics; reads `~/.env`, `~/.npmrc`, `~/.gitconfig`, `~/.git-credentials`; scrapes `process.env` for any variable matching key/secret/token/password/private/mnemonic/wallet/seed; runs `whoami`; and POSTs everything to the same dynamic webhook (the constant is literally named `EXFIL_DIRS`). The MCP tools/call handler in index.js silently relays every invocation's tool name, arguments, `git remote -v` output, $SHELL, and $PATH to the webhook before returning hardcoded fake scan results (always 89 files, `scripts/deploy.js` line 42) regardless of input. The package targets Web3 developers — a victim population likely to have hot wallets and keystores on disk.\n\n## Source: ghsa-malware (de510789d1cc60f144c8d004cb19c17bc1e882ea8bd17d9d0b97b829491aaf55)\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":"web3-secrets-detector"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"versions":["1.2.4","1.2.6","1.2.7","2.3.8","1.2.5","2.2.0","2.3.0","2.2.2","2.3.1","2.2.1","2.2.3","4.0.0","2.3.7","2.3.6","2.3.9"],"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"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"}],"indicators":{"domains":["ddjidd564.github.io","webhook.site"],"evidence_files":[{"path":"index.js","sha256":"4a13ef3d19d220ee53329d5d2061d315b623a3d264f7e36d5264c7602a561786","tlsh":"1e8168d258f8e82a8a93a062750f63911739c10b2d256c71bbdd63341f4d59ddbf1bc8"},{"path":"package.json","sha256":"4b7225ce04ed5148f3b2669eb453bbe46939f634e9cdf31b9456dd8ee94ef34c","tlsh":"2c019c06e824fd3343ee5196b491348a52288c474d243c0c37d6565ccf9e46b92fc2dd"}],"package_integrity":[{"filename":"web3-secrets-detector-1.2.4.tgz","hashes":{"sha1":"12f5528ea253a47fc29d4cbc4acca096ef2194b9","sha512_sri":"sha512-N4z7wRDW9+Xjs6eje1VR6s4zy7RFCJfz87h9OJYhPBTez2vUSZTtOGeS9JKNKUbRqbPG3Z37mdVFHHi0TX/sBA=="}}]}}}],"references":[{"type":"WEB","url":"https://x.com/safedepio/status/2057325717453697057"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-qc99-w9r4-jrg5"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/1.2.4"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/1.2.7"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.8"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/1.2.5"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.0"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.2.2"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.2.0"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.2.3"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/4.0.0"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/1.2.6"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.7"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.2.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.6"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/web3-secrets-detector/v/2.3.9"}],"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":"de510789d1cc60f144c8d004cb19c17bc1e882ea8bd17d9d0b97b829491aaf55","import_time":"2026-05-22T03:24:54.644174359Z","id":"GHSA-qc99-w9r4-jrg5","modified_time":"2026-05-22T02:43:01Z","ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}]},{"source":"amazon-inspector","sha256":"c3da5f79f828fdcbcf41e4c3e7cd1d25c4711fb478f3a1b724d0a197c11aa89f","import_time":"2026-05-26T05:50:48.245551904Z","id":"IN-MAL-2026-003531","modified_time":"2026-05-20T12:57:04Z","versions":["1.2.4"]},{"source":"amazon-inspector","sha256":"463a51bd0a184e874d43379d8d7ed4fb2421288f3c1ceecd9cc7cd37e7d68904","import_time":"2026-05-26T05:51:12.969465109Z","id":"IN-MAL-2026-003736","modified_time":"2026-05-21T04:32:58Z","versions":["1.2.6"]},{"source":"amazon-inspector","sha256":"49c3c946c1895676ea21fb7b2193b2db1939c367f38b6c763782e1d840c618ee","import_time":"2026-05-26T05:51:24.865598644Z","id":"IN-MAL-2026-003835","modified_time":"2026-05-21T13:46:08Z","versions":["1.2.7"]},{"source":"amazon-inspector","sha256":"4a7d385644b44d55a9d2421c9d771afc5b0988b58701d81c18bdde8c30215f62","import_time":"2026-05-26T05:51:52.844068222Z","id":"IN-MAL-2026-004071","modified_time":"2026-05-21T23:00:31Z","versions":["2.3.8"]},{"source":"amazon-inspector","sha256":"5a670dc740163ed4bad6bfaf86e5a2a2ecdbdc3df990781dbe12123022d918bc","import_time":"2026-05-26T05:51:09.881954484Z","id":"IN-MAL-2026-003712","modified_time":"2026-05-21T02:54:51Z","versions":["1.2.5"]},{"source":"amazon-inspector","sha256":"bb425fc62318bdc8741c4148c2c46e1294f562ba4063cfdeda801b3140f592bc","import_time":"2026-05-26T05:51:27.265854727Z","id":"IN-MAL-2026-003854","modified_time":"2026-05-21T14:08:37Z","versions":["2.2.0"]},{"source":"amazon-inspector","sha256":"cbc9a274e0cacfb1beea0ffc698751ee58ec8ac3514180a085cd654aa0024815","import_time":"2026-05-26T05:51:38.88759259Z","id":"IN-MAL-2026-003951","modified_time":"2026-05-21T17:59:29Z","versions":["2.3.0"]},{"source":"amazon-inspector","sha256":"df7b69a7d8d197e4be8070e6a2c9c05054b1e671c67c35a4f978fdeee48c6337","import_time":"2026-05-26T05:51:35.309703369Z","id":"IN-MAL-2026-003920","modified_time":"2026-05-21T16:41:20Z","versions":["2.2.2"]},{"source":"amazon-inspector","sha256":"e2d462ad826f50fc898ab004f612473302695868f3ca016920055d52019f580c","import_time":"2026-05-26T05:51:42.762434428Z","id":"IN-MAL-2026-003986","modified_time":"2026-05-21T18:18:36Z","versions":["2.3.1"]},{"source":"amazon-inspector","sha256":"09059449e7b640b2e66c4a5a6838c23db8df77ec167daef09f2c129749ea5b85","import_time":"2026-05-26T05:51:39.768005705Z","id":"IN-MAL-2026-003959","modified_time":"2026-05-21T17:59:49Z","versions":["2.3.0"]},{"source":"amazon-inspector","sha256":"3aa84505937f7820e53a5a0fec2e9f7b09225a2a70db7cd68be8564b0a06fd75","import_time":"2026-05-26T05:51:42.883313223Z","id":"IN-MAL-2026-003987","modified_time":"2026-05-21T18:18:37Z","versions":["2.3.1"]},{"source":"amazon-inspector","sha256":"68636f88ca12ecc80ccc5975e91f3dd348ec500396f6e32b72d585705a961c17","import_time":"2026-05-26T05:51:32.481115494Z","id":"IN-MAL-2026-003899","modified_time":"2026-05-21T16:19:56Z","versions":["2.2.1"]},{"source":"amazon-inspector","sha256":"878c1916216bf80300fb0264b3155d64febe2ce0cddc29292c47752c25d62b6f","import_time":"2026-05-26T05:51:27.142707259Z","id":"IN-MAL-2026-003853","modified_time":"2026-05-21T14:08:36Z","versions":["2.2.0"]},{"source":"amazon-inspector","sha256":"a2b2773041bb0703a8e93514add2d76f295d64ef17d394b264f4c3cbf987034e","import_time":"2026-05-26T05:51:38.095485458Z","id":"IN-MAL-2026-003944","modified_time":"2026-05-21T17:23:38Z","versions":["2.2.3"]},{"source":"amazon-inspector","sha256":"f99789908929ace4007dfc627f36e8f2966be94c3ffcc83a8e5caa6cd32d2bfb","import_time":"2026-05-26T05:51:54.980338493Z","id":"IN-MAL-2026-004089","modified_time":"2026-05-21T23:32:29Z","versions":["4.0.0"]},{"source":"amazon-inspector","sha256":"fef0181b00ae10b404dbeae5d0b470c6bf96abb9d4afe741d455accbc26062b0","import_time":"2026-05-26T05:51:12.851321095Z","id":"IN-MAL-2026-003735","modified_time":"2026-05-21T04:32:57Z","versions":["1.2.6"]},{"source":"amazon-inspector","sha256":"52b43f1bc7b16c6f12dd17204aed9bb7eeb83077ad5418ed5b9f40054f975088","import_time":"2026-05-26T05:51:51.454826602Z","id":"IN-MAL-2026-004058","modified_time":"2026-05-21T22:48:34Z","versions":["2.3.7"]},{"source":"amazon-inspector","sha256":"5d92015daabecaa348fd614f87d2ab9066ccf0be6d28646ad756b66c0ec92afe","import_time":"2026-05-26T05:51:32.374555721Z","id":"IN-MAL-2026-003898","modified_time":"2026-05-21T16:19:56Z","versions":["2.2.1"]},{"source":"amazon-inspector","sha256":"9ff8d0c26a623c13aa5982464366d5d2c8e77470d45401bbbfcfdfbf3662072b","import_time":"2026-05-26T05:51:35.411299162Z","id":"IN-MAL-2026-003921","modified_time":"2026-05-21T16:41:20Z","versions":["2.2.2"]},{"source":"amazon-inspector","sha256":"bd1636a2b7221cb7fc61f7eff2676f06b30d6202e771cfcc71bfaddfe853f322","import_time":"2026-05-26T05:51:38.21125812Z","id":"IN-MAL-2026-003945","modified_time":"2026-05-21T17:23:39Z","versions":["2.2.3"]},{"source":"amazon-inspector","sha256":"e9bac3419d1ec5ebccc7c5d60b1f77e75a8e070b12b949afa8766c984dd7002c","import_time":"2026-05-26T05:51:50.284829324Z","id":"IN-MAL-2026-004047","modified_time":"2026-05-21T22:32:31Z","versions":["2.3.6"]},{"source":"amazon-inspector","sha256":"f167e9e0cb4300d1d2b350b1bad82f98ff58709380f552aa80e76cac5a4f93d8","import_time":"2026-05-26T05:51:24.971088052Z","id":"IN-MAL-2026-003836","modified_time":"2026-05-21T13:46:08Z","versions":["1.2.7"]},{"source":"amazon-inspector","sha256":"a72ee1c4a6a70206792b2e96e690564ec7968432eb0cc32007bf95bf1ec44cda","import_time":"2026-05-26T05:51:53.670050283Z","id":"IN-MAL-2026-004078","modified_time":"2026-05-21T23:12:20Z","versions":["2.3.9"]}]}}

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