{"id":"MAL-2026-5347","summary":"Malicious code in moustick (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (deae034e46d94eafe1db97a6a57a664400f03caa48af8f775f6064c361c6bb9a)\nPackage impersonates the popular `cookie-signature` library — it copies the description, README, author (TJ Holowaychuk), and repository URL of visionmedia/node-cookie-signature in package.json, while the package itself is published under the unrelated name `moustick`. On `require('moustick')`, index.js performs an HTTPS GET to https://www.jsonkeeper.com/b/MYUKZ (an anonymous, mutable paste host) and passes the response field `content_o` directly to `eval()`, executing whatever JavaScript the paste currently serves in the consumer's Node process. A helper function `g(h)` hex-decodes identifiers and assembles a second paste URL https://www.jsonkeeper.com/b/HY6M6 (`hl` decodes to ['axios','get','https://www.jsonkeeper.com/b/HY6M6','then']), providing a second remote-fetch primitive and confirming intentional evasion. Any developer who installs this package expecting cookie-signing functionality executes attacker-controlled code at import time; the operator can swap the paste contents at any time to deliver new payloads.\n\n## Source: ghsa-malware (890180372ad21984cf864d1d144734f47f696379213ef6e7bdf02a4c1f186a7f)\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","aliases":["GHSA-979m-vm48-369f"],"modified":"2026-06-12T20:01:55.499771701Z","published":"2026-06-09T11:19:47Z","database_specific":{"malicious-packages-origins":[{"source":"ghsa-malware","ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"modified_time":"2026-06-09T11:19:48Z","id":"GHSA-979m-vm48-369f","sha256":"890180372ad21984cf864d1d144734f47f696379213ef6e7bdf02a4c1f186a7f","import_time":"2026-06-09T11:22:38.398285478Z"},{"source":"amazon-inspector","versions":["1.2.1"],"modified_time":"2026-06-12T19:03:17Z","import_time":"2026-06-12T19:43:40.058864405Z","sha256":"d4e7fe7f047142ec8657563d0ea8b49e4fa254a22d27d7015c28317e79235ac8","id":"IN-MAL-2026-005850"},{"source":"amazon-inspector","versions":["1.2.2"],"modified_time":"2026-06-12T19:03:19Z","id":"IN-MAL-2026-005851","sha256":"deae034e46d94eafe1db97a6a57a664400f03caa48af8f775f6064c361c6bb9a","import_time":"2026-06-12T19:43:40.171083306Z"}]},"references":[{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-979m-vm48-369f"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/moustick/v/1.2.1"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/moustick/v/1.2.2"}],"affected":[{"package":{"name":"moustick","ecosystem":"npm","purl":"pkg:npm/moustick"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"versions":["1.2.1","1.2.2"],"database_specific":{"source":"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/moustick/MAL-2026-5347.json","indicators":{"evidence_files":[{"tlsh":"663155137ea5d01712b121b3b1f3cc47fd6695601b9a46e0bb6454943ded6b28f30ed8","sha256":"9eb97dcae23527bc66606235e0ad5d2c89692d311120dec3a636acf479e53047","path":"index.js"},{"tlsh":"3ff0461399a85d7706fc9395bc640287b6121f1f00b08c0f36ba022c57634ab16e8fb9","sha256":"b40627bed3ca5bb8f0eccce0a8a2b77bf3a64f6c03d3104b77052fb981dc9ac9","path":"package.json"}]},"cwes":[{"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."}]}}],"schema_version":"1.7.5","credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"}]}