OpenSSF/OSV advisory MAL-2025-190657 confirms this npm version as malicious. src/utils.js — reached via the package main src/index.js — contains an obfuscator.io IIFE that runs at module load. Alongside the legitimate helpers (getInfo, getTitle, toSnakeCase, toCamelCase), the file ships a rotated string array (_0x2d89), a custom lowercase-first base64 decoder (_0x1dd2), and a ~4KB opaque literal that decodes at runtime to further JavaScript. The top-level main() then invokes...
Source
OpenSSF Malicious Packages via OSV
Summary
Malicious code in @asyncapi/generator-helpers (npm)
Details
src/utils.js — reached via the package main src/index.js — contains an obfuscator.io IIFE that runs at module load. Alongside the legitimate helpers (getInfo, getTitle, toSnakeCase, toCamelCase), the file ships a rotated string array (_0x2d89), a custom lowercase-first base64 decoder (_0x1dd2), and a ~4KB opaque literal that decodes at runtime to further JavaScript. The top-level main() then invokes child_process.spawn on the Node runtime with '-e' and the decoded string, using {detached: true, stdio: 'ignore', windowsHide: true} so the child process is disowned and hidden. Because this fires unconditionally on require('@asyncapi/generator-helpers'), any consumer or generator template that loads this version executes attacker-controlled JavaScript in a detached Node process on the host. The behavior — obfuscator.io string-array plus custom-base64 blob reconstructed into node -e arguments — is not consistent with the package's documented purpose as an AsyncAPI generator helper library and matches a trojanized-release supply-chain compromise.
## Source: ghsa-malware (6c55b498d8766225c87bc5781438ffe36f84333b8bb731069bb0bac726cb6b3e) Any 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.
## Source: google-open-source-security (eaf9598bd0d64189828293050c590d3885311537cef7b91153a0df8cef9489f4) This package was compromised by the Sha1-Hulud: The Second Coming NPM worm. The malicious payload steals tokens and credentials and publishes them to GitHub. The worm will propogate itself to NPM packages the user owns and establish persistence is a GitHub action. The package may also destroy the user's home directory.
Decision reason
One or more suspicious static signals were detected.