{"id":"MAL-2026-13695","revision":null,"records":[{"revision":"2ce11ffd9a6e41888137765e1d30ed56","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-13695","aliases":[],"title":"Malicious code in hex-encode-utils (npm)","description":"hex-encode-utils is a purpose-built npm trojan that masquerades as a zero-dependency hex encoding/decoding utility (published by the npm account `devroolx` under the repo github.com/stdlib-utils/hex-encode-utils). It is a multi-stage downloader/loader that runs automatically on install via a `postinstall` hook (`node runtime.js`).\n\nruntime.js first gates execution to real developer machines: it only proceeds if the user home directory contains a Desktop, Documents, or Downloads folder, and caches a timestamp at `~/.cache/hex-encode-utils/.runtime_check` to run at most once every 24 hours (sandbox/CI evasion and low-noise persistence). It then exfiltrates host reconnaissance (hostname, username, platform and architecture, Node.js version, OS release, package version, and timestamp) via an HTTPS POST to `/report` on the attacker-controlled Cloudflare Worker `steel-mere-4155.ricardorichp.workers.dev`.\n\nIt next downloads an AES-256-GCM encrypted blob from `/e` on the same host, decrypts it with a key derived as the SHA-256 of a hardcoded seed string that is disguised as a Bitcoin \"BIP-0174 PSBT version 2 signing specification for hardware wallets\" reference (indicating cryptocurrency-wallet targeting), and validates that the decrypted payload is Python source containing a `TelemetrySender` class. It locates a Python interpreter (python3/python and version-specific fallbacks), writes the decrypted payload to `~/.cache/hex-encode-utils/modules/runtime.py`, builds an `exec_runtime.py` wrapper that invokes `TelemetrySender.send(TelemetrySender.load())`, and spawns it as a detached, output-suppressed background Python process (`detached: true`, `stdio: 'ignore'`, `.unref()`). All C2 traffic disables TLS certificate validation (`rejectUnauthorized: false`).\n\nThe second-stage Python payload is fetched at runtime from attacker infrastructure and was not available for static analysis; based on the wallet/PSBT-signing themed key seed it most likely targets cryptocurrency wallet material. Any host that installed this package should be treated as compromised: remove `~/.cache/hex-encode-utils`, hunt for the spawned Python process, and rotate any wallet keys and secrets reachable from the affected machine.\n\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (999c0a7bda643ce11c335436392aac35c2eca53dc92225dd86cbc01cc9015f8c)\nOn npm install, scripts/compat.js runs as a postinstall hook and fetches an AES-256-GCM-encrypted blob over HTTPS from two hardcoded Cloudflare Workers hosts (steel-mere-4155.ricardorichp.workers.dev, cold-peak-7969.0x0gnx0.workers.dev) with TLS verification disabled (rejectUnauthorized: false), decrypts it with a hardcoded key derived from a 'BIP-0174' decoy string, writes the plaintext to ~/.cache/hex-encode-utils/modules/exec_runtime.py, and spawns a detached, stdio-ignored Python process to execute it. Before dropping the payload the script POSTs an install beacon to /r on the same Workers host carrying the installer's hostname (os.hostname()), username (os.userInfo()), platform/arch (os.platform()), Node version, and package version, formatted as an HTML Telegram message with chat_id 6087129674 for relay to a Telegram bot. Execution is gated by sandbox-evasion checks that abort in CI/container environments (CI, GITHUB_ACTIONS, DOCKER_CONTAINER, KUBERNETES_SERVICE_HOST) and require Desktop/Documents/Downloads directories under $HOME to confirm a developer workstation. Comments frame the code as a next.js/nuxt-style compatibility shim. The package's stated purpose (hex encode/decode) has no legitimate need for postinstall network I/O, encrypted-payload fetch, Python execution, or host reconnaissance to a Telegram relay.\n","state":0,"publishedAt":"2026-08-10T00:00:00+00:00","modifiedAt":"2026-08-11T03:04:45.4705443+00:00","affected":[{"ecosystem":"npm","name":"hex-encode-utils","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"}]}],"versions":["1.0.5","1.0.1","1.0.2","1.0.3","1.0.0","1.0.4"],"rawVersionEvidence":null}],"metrics":[],"references":["https://www.npmjs.com/package/hex-encode-utils/v/1.0.5","https://www.npmjs.com/package/hex-encode-utils/v/1.0.1","https://www.npmjs.com/package/hex-encode-utils/v/1.0.2","https://www.npmjs.com/package/hex-encode-utils/v/1.0.3","https://www.npmjs.com/package/hex-encode-utils/v/1.0.0","https://www.npmjs.com/package/hex-encode-utils/v/1.0.4","https://www.npmjs.com/package/hex-encode-utils","https://github.com/stdlib-utils/hex-encode-utils"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-13695","license":"OSV · upstream source license applies","key":"osv:MAL-2026-13695","identifiers":["MAL-2026-13695"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-22T08:27:09.0681741+00:00","complete":true,"records":1790,"lastAttemptAt":"2026-11-22T08:27:09.0681741+00:00","lastSuccessAt":"2026-11-22T08:27:09.2557762+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:09.2557818+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-a00cc431548e20f01f2da20f449eca4a9c3c2d80f0a99ee8150099224d339982-f8f118ca14c96f9541b27c4930f7a085141e0585c47b3ddd38c161dc443d994d","complete":true,"records":430439,"lastAttemptAt":"2026-11-22T08:25:28.0283875+00:00","lastSuccessAt":"2026-11-22T07:25:32.2976981+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:25:28.0283875+00:00","snapshotPublishedAt":"2026-11-22T07:22:46+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-17c79b54caa14ee590fc017071ee6d27","complete":false,"records":13927,"lastAttemptAt":"2026-11-22T08:38:23.357033+00:00","lastSuccessAt":"2026-11-22T08:38:23.354+00:00","error":"130 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-22T08:38:23.354+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13690,"expectedIdentifiers":13975,"failedIdentifiers":130},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-22T08:27:09.0681741+00:00","complete":true,"records":1131,"lastAttemptAt":"2026-11-22T08:27:09.0681741+00:00","lastSuccessAt":"2026-11-22T08:27:09.2568806+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:09.2568808+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-5a886cb4a9644cc8aafce1b10d9f4e8f","complete":true,"records":13939,"lastAttemptAt":"2026-11-22T08:27:34.3747626+00:00","lastSuccessAt":"2026-11-22T08:27:34.371+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:34.371+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13975,"expectedIdentifiers":13975,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-e5345bb505029da8292989aaa8236ee0c21dd40080e465858702ec2ecb4dcefd","complete":true,"records":9989,"lastAttemptAt":"2026-11-22T08:27:09.0032058+00:00","lastSuccessAt":"2026-11-21T19:16:03.0413179+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:09.0032058+00:00","snapshotPublishedAt":"2026-11-21T18:18:24+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-6ba2352decd0c95d34a1b50f642582aa34659ce946f552488f0a5cea4e0cc09a","complete":true,"records":2020,"lastAttemptAt":"2026-11-22T08:25:28.0907107+00:00","lastSuccessAt":"2026-11-20T15:46:15.4249619+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:25:28.0907107+00:00","snapshotPublishedAt":"2026-11-20T14:48:20+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-67ea94df7f6b2100258b087b14035af283f000b6aefe39f55e9f2795f912fde8","complete":true,"records":3209,"lastAttemptAt":"2026-11-22T08:27:09.0218188+00:00","lastSuccessAt":"2026-11-21T19:16:06.9994675+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:09.0218188+00:00","snapshotPublishedAt":"2026-11-21T18:18:24+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-93f8bde17692d302a32a561f6a40a941db24e5e5c3d8083eda975620fb7a4483","complete":true,"records":232857,"lastAttemptAt":"2026-11-22T08:27:08.8747776+00:00","lastSuccessAt":"2026-11-22T08:27:07.8116265+00:00","error":null,"lastVerifiedAt":"2026-11-22T08:27:08.8747776+00:00","snapshotPublishedAt":"2026-11-22T07:33:11+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}