{"id":"GHSA-3h97-jj75-q7j4","revision":null,"records":[{"revision":"7686f37999cc4d1cbdee9d9d579e792f","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-6578","aliases":["GHSA-3h97-jj75-q7j4"],"title":"Malicious code in layerd-unit-codec-parser (npm)","description":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (ca65bb450fc2f4d4596fbcc2ddd81af358c2d02f94d965b18e532d8afa62ef5f)\nThe package presents itself as a CSS selector parser (src/selector-parser.js re-exports postcss-selector-parser; keywords postcss/selector/parser/css), but its main module also exposes run / runDefaultDecodedFunction / finalFinalDecodeAndRun. src/config/defaults.js ships an ~10KB opaque AES-GCM ciphertext (DEFAULT_FINAL_ENCODED_TEXT) alongside a hardcoded passphrase (\"default-dev-passphrase\"); src/aes/aes-gcm.js uses base64 Buffer decoding and scrypt to derive the key, decrypts the blob, and src/pipeline/custom-codec-pipeline.js invokes the plaintext as code through new Function(\"require\", runnable)(require), granting the smuggled bytes full Node require/process capabilities. The package's own runtime/lib.min.js calls require(\"../src\").run(), and package.json scripts (start, decode, test:cjs) plus a root cjs-runner.js funnel into the same decrypt-and-execute path. None of this is documented in the README, which describes only selector parsing and encode/decode helpers. A consumer who installs the package and runs the advertised npm start / decode scripts, or who imports and calls run(), executes the hidden payload. The combination of an opaque encrypted executable shipped in the tarball, a hardcoded key that makes the ciphertext functionally equivalent to shipping the code while evading source review, and an undocumented entry point that invokes it with full Node capabilities is a backdoor pattern. The postcss-selector-parser API mimicry increases the chance of the hidden run() path being reached.\n\n## Source: ghsa-malware (a528d47bc1d6d0ca165042a753200e57a91c67c67fc9bf9e50cfe081af638b42)\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","state":0,"publishedAt":"2026-06-29T06:35:34+00:00","modifiedAt":"2026-08-20T14:30:11.5386128+00:00","affected":[{"ecosystem":"npm","name":"layerd-unit-codec-parser","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"}]}],"versions":["1.0.0","2.0.0"],"rawVersionEvidence":null}],"metrics":[],"references":["https://www.npmjs.com/package/layerd-unit-codec-parser/v/1.0.0","https://www.npmjs.com/package/layerd-unit-codec-parser/v/2.0.0","https://github.com/advisories/GHSA-3h97-jj75-q7j4"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-6578","license":"OSV · upstream source license applies","key":"osv:MAL-2026-6578","identifiers":["MAL-2026-6578","GHSA-3h97-jj75-q7j4"]},"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-21T09:15:53.1283904+00:00","complete":true,"records":1790,"lastAttemptAt":"2026-11-21T09:15:53.1283904+00:00","lastSuccessAt":"2026-11-21T09:15:55.1581724+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:55.1583016+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-1d6c61c44cf3e269b6d60ed2fe0a3aa1f7e55445c7f170f16f2fa063bbf73db3-c983a67c9b146e0ed54ad4ad327c43072450c18d277efb7db13e1676ef7da731","complete":true,"records":430094,"lastAttemptAt":"2026-11-21T09:15:50.0218069+00:00","lastSuccessAt":"2026-11-21T08:46:06.1827376+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:50.0218069+00:00","snapshotPublishedAt":"2026-11-21T08:34:05+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-22854723220448e889c4a9b58c8eaa0f","complete":false,"records":13919,"lastAttemptAt":"2026-11-21T09:16:48.3148498+00:00","lastSuccessAt":"2026-11-21T09:16:48.31+00:00","error":"83 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-21T09:16:48.31+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13884,"expectedIdentifiers":13967,"failedIdentifiers":83},{"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-21T09:15:53.1283904+00:00","complete":true,"records":1131,"lastAttemptAt":"2026-11-21T09:15:53.1283904+00:00","lastSuccessAt":"2026-11-21T09:15:55.1893992+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:55.1893997+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-425238ad85424e458b64cb1752d2502a","complete":true,"records":13931,"lastAttemptAt":"2026-11-21T09:15:56.4355725+00:00","lastSuccessAt":"2026-11-21T07:46:08.274+00:00","error":null,"lastVerifiedAt":"2026-11-21T07:46:08.274+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13967,"expectedIdentifiers":13967,"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-99c78bee98bf8a60587f33f568944b12d3afe17ecc41437c57b47e2204cce04d","complete":true,"records":9989,"lastAttemptAt":"2026-11-21T09:15:52.9016108+00:00","lastSuccessAt":"2026-11-21T00:54:34.963487+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:52.9016108+00:00","snapshotPublishedAt":"2026-11-21T00:03:07+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-21T09:15:50.1890807+00:00","lastSuccessAt":"2026-11-20T15:46:15.4249619+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:50.1890807+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-2c09f95d48acb57436aa1dd2f0eec6f651dce8d1621b6978554be0f0b129faa4","complete":true,"records":3209,"lastAttemptAt":"2026-11-21T09:15:53.0154978+00:00","lastSuccessAt":"2026-11-20T23:48:55.8565941+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:53.0154978+00:00","snapshotPublishedAt":"2026-11-20T23:48:16+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-14439d295cda6d6706536c3efcb7f193a982609cf031218db7fa9ef26fdcc725","complete":true,"records":232850,"lastAttemptAt":"2026-11-21T09:15:50.3367421+00:00","lastSuccessAt":"2026-11-21T03:47:49.8245357+00:00","error":null,"lastVerifiedAt":"2026-11-21T09:15:50.3367421+00:00","snapshotPublishedAt":"2026-11-21T03:33:18+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}