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

目标: 1000 元 · 已筹: 1359 元

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

ts-rand-sdk

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

Summary

Malicious code in ts-rand-sdk (npm)

凭据/密钥窃取
AI 分析整理qwen3.6
基于上游报告生成,请以下方原始证据为准。
公开使用量数据
统计周期
last-week
下载量
—
数据源
npmjs.org
下载量只代表仓库活动度,不等于已被入侵的安装数量。
受影响版本
EcosystemPackageVersion
npmts-rand-sdk*
npmts-rand-sdk1.0.2
npmts-rand-sdk1.0.4
恶意行为说明OpenSSF OSV
上游来源证据
展开原始 OSV JSON
{"schema_version":"1.7.4","id":"MAL-2026-14193","published":"2026-08-19T00:04:55Z","modified":"2026-09-29T23:42:05.630011058Z","aliases":["GHSA-3p7v-9fcr-jcp8"],"summary":"Malicious code in ts-rand-sdk (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (7f3c43a89866228b5365b9e318da3ea953bb2c5b7da94136d887359e8e1f07a8)\nPackage presents itself as a random transactions SDK exposing a single API, getTransactions(count). Following that documented usage triggers a hidden loader: load_transaction_data reads database.js (framed as a product catalog), takes each record's `mark` field, base64-decodes it, applies a per-record byte shift keyed on `count % 256`, concatenates the fragments in id order, base64-decodes the result again, and passes the resulting JavaScript source into a Function constructor obtained indirectly via globalThis.constructor.constructor. The constructed function is invoked with Buffer, require, and process passed in, giving the decoded payload full Node.js capabilities (arbitrary filesystem, process, and network access) on the caller's machine. Sensitive identifiers (setTimeout, Function, Buffer, require, process, clearTimeout) are stored as fragments in a string array and reassembled at runtime via an index-mapping helper, and execution is deferred through setTimeout, both patterns serving only to hide the payload path from reviewers. The ~54KB of `mark` shards inside database.js are the concealed code body; the product-catalog framing is cover. The package's advertised functionality is a facade over a runtime code-execution loader.\n\n## Source: ghsa-malware (f1f9011f0abb7ca82ed6875b22587eeb4a46afca2285ce54ae90dc720bf9a53a)\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":{"name":"ts-rand-sdk","ecosystem":"npm"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"versions":["1.0.2","1.0.4"],"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"}],"indicators":{"evidence_files":[{"path":"index.js","sha256":"c0a1a7e54e1c759e62e48cfa835d79494163da3b37b30c1bd55c5875d9dd24f0","tlsh":"0ef10f6839f930248857b07c67eb9449612de0576e9a6ca87f4d83101f7d13ce1f6ba8"},{"path":"database.js","sha256":"2df9ecfb35f541cddca8430be72e3ccef0efe57f1aa3bd3acf21dc7e8df2114a","tlsh":"5a135136cb790c5ba1b84a6069f50a4af2c0472f13a16d877ef4d54c8fb1c5b805ae7b"}],"package_integrity":[{"filename":"ts-rand-sdk-1.0.2.tgz","hashes":{"sha1":"84a52526a8e0833538fe7e8223bd222932a19935","sha512_sri":"sha512-y9h8M6E5YRuP3s/SyQ+ys/Z8uzPHR6R7NqytAE1vw88Y2vtyBQCZ3dffJgsBIFfErjdXlE6SDsQ/xi6PRjM8eg=="}}]}}}],"references":[{"type":"PACKAGE","url":"https://www.npmjs.com/package/ts-rand-sdk/v/1.0.2"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-3p7v-9fcr-jcp8"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/ts-rand-sdk/v/1.0.4"}],"database_specific":{"malicious-packages-origins":[{"id":"IN-MAL-2026-018264","import_time":"2026-08-19T00:21:14.613516486Z","modified_time":"2026-08-19T00:04:55Z","sha256":"7f3c43a89866228b5365b9e318da3ea953bb2c5b7da94136d887359e8e1f07a8","source":"amazon-inspector","versions":["1.0.2"]},{"id":"GHSA-3p7v-9fcr-jcp8","import_time":"2026-09-29T18:33:19.271522143Z","modified_time":"2026-09-29T17:30:02Z","ranges":[{"events":[{"introduced":"0"}],"type":"SEMVER"}],"sha256":"f1f9011f0abb7ca82ed6875b22587eeb4a46afca2285ce54ae90dc720bf9a53a","source":"ghsa-malware"},{"id":"IN-MAL-2026-020696","import_time":"2026-09-29T23:39:24.325103335Z","modified_time":"2026-09-29T23:19:41Z","sha256":"456527029dedcfacab06318e10d2edd4173b4b107b5cd9d09fc96054a01150c8","source":"amazon-inspector","versions":["1.0.4"]}]},"credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"}]}

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