MAL-2026-13627Malicious code in @nestjs-passport/jwt (npm)
| 版本 | 状态 | 大小 | SHA-256 | 获取方式 |
|---|---|---|---|---|
1.0.4 | unavailable | — | — | — |
1.0.7 | archived | — | — | VIP 下载 |
| Ecosystem | Package | Version |
|---|---|---|
| npm | @nestjs-passport/jwt | 1.0.4 |
| npm | @nestjs-passport/jwt | 1.0.7 |
{"modified":"2026-08-07T18:24:51Z","published":"2026-08-07T18:02:58Z","schema_version":"1.7.4","id":"MAL-2026-13627","summary":"Malicious code in @nestjs-passport/jwt (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (0d3060c9289c475e223c1c00bc21a0f59f8aa5b18e31bfaee6e4d923eab0042f)\nPackage published under the @nestjs-passport scope, which resembles the official @nestjs/jwt and @nestjs/passport packages. The sole entrypoint files dist/index.cjs and dist/index.js each consist of a single-line JSFuck-encoded string (~2.3MB of permutations of!+[],!![], +[]) that is passed to new Function('jose', <opaque body>) and invoked at require/import time, executing hidden code in the installer's Node process every time the module is loaded. The advertised purpose is a minimal HS256 JWT helper — a task requiring only a few lines of jose calls — and the shipped TypeScript declarations expose obfuscated private field names such as _0x5f2e and _0x4b19, inconsistent with the declared tsup build tooling. The combination of scope-level typosquat, whole-module JSFuck obfuscation, and dynamic evaluation of the obfuscated body at import time is a concealment-and-execution vehicle: whatever behavior the payload performs runs inside the installer's process without any traced-readable code path.\n","affected":[{"package":{"ecosystem":"npm","name":"@nestjs-passport/jwt"},"versions":["1.0.7","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"}],"indicators":{"evidence_files":[{"path":"dist/index.cjs","sha256":"a2b64d639ffaaa3784eaf995d0ed16242280c47a4647fcd34e686dcf04769be6","tlsh":"a3b51c0ec013e7d5f9cb55ec3ce4ae9d9b0e1e0bbaa4c76c2b4ca6974759ef06484811"},{"path":"dist/index.d.ts","sha256":"65b212dab6b4946e63c2b0e76c1bf56558fad64f648d0eaed8c7ef11117e9b08","tlsh":"67f08141d8d607701c938653afda0dc6e89cf20a654cbdf9ffe280514ac340ad07156a"}],"package_integrity":[{"filename":"jwt-1.0.7.tgz","hashes":{"sha1":"848c0e11f4d19efe132d6eb356d8121202affc98","sha512_sri":"sha512-YbhPO2poNrFbEK0mWPHWiCsSYkf3Ys8Wr0dAQkx3qsMXq5i5Kr6yx2fulyJpgsPgY7fuY/BewNZSovHXie2lYg=="}}]}}}],"references":[{"type":"PACKAGE","url":"https://www.npmjs.com/package/@nestjs-passport/jwt/v/1.0.7"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/@nestjs-passport/jwt/v/1.0.4"}],"credits":[{"name":"Amazon Inspector","type":"FINDER","contact":["inspector-research@amazon.com"]}],"database_specific":{"malicious-packages-origins":[{"id":"IN-MAL-2026-017136","import_time":"2026-08-07T18:23:03.462193119Z","modified_time":"2026-08-07T18:03:10Z","sha256":"0d3060c9289c475e223c1c00bc21a0f59f8aa5b18e31bfaee6e4d923eab0042f","source":"amazon-inspector","versions":["1.0.7"]},{"id":"IN-MAL-2026-017135","import_time":"2026-08-07T18:23:03.426426772Z","modified_time":"2026-08-07T18:02:58Z","sha256":"3118e2d469f173e01de26e12dca51e96b8c8e2a9c0d90d1476c3472d08f82193","source":"amazon-inspector","versions":["1.0.4"]}]}}数据来源:OpenSSF Malicious Packages · Apache-2.0