MAL-2026-10614Malicious code in postcss-selector-minify (npm)
| 版本 | 状态 | 大小 | SHA-256 | 获取方式 |
|---|---|---|---|---|
1.0.0 | unavailable | — | — | — |
2.0.0 | unavailable | — | — | — |
| Ecosystem | Package | Version |
|---|---|---|
| npm | postcss-selector-minify | * |
| npm | postcss-selector-minify | 1.0.0 |
| npm | postcss-selector-minify | 2.0.0 |
{"schema_version":"1.7.4","id":"MAL-2026-10614","published":"2026-07-14T20:18:29Z","modified":"2026-08-20T21:45:13.096110846Z","aliases":["GHSA-pjfj-gp2h-5692"],"summary":"Malicious code in postcss-selector-minify (npm)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (92fec62079856815ded46ba283769d3d3e0d20e08b6196b8698e08e2df6677ee)\nPackage is published as `postcss-selector-minify` (a word-order permutation of cssnano's widely used `postcss-minify-selectors`) and registers itself to PostCSS under the legitimate plugin's id `postcss-minify-selectors`, so consumers who mistype or misremember the cssnano plugin name receive a different publisher's package that self-identifies as the real one. On `require()`, the main entry performs a bare side-effect import of `layerd-unit-codec-parser/cjs-runner` (return value discarded) before any other work, and replaces the de-facto-standard `postcss-selector-parser` with `layerd-unit-codec-parser/selector-parser` (the standard parser is demoted to devDependencies). `layerd-unit-codec-parser` is an obscure package whose name has no relation to CSS or PostCSS; the `/cjs-runner` submodule path is shaped specifically to execute code on load. Installing this package silently pulls `layerd-unit-codec-parser` into the consumer's dependency tree and runs its `cjs-runner` module on every require of the wrapper.\n\n## Source: ghsa-malware (154dbe50ec546f28c72556086a952dcfd2e59a0f016d513b7bdd0e7e95602937)\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","affected":[{"package":{"name":"postcss-selector-minify","ecosystem":"npm"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}],"versions":["2.0.0","1.0.0"],"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"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"}],"indicators":{"evidence_files":[{"path":"src/index.js","sha256":"68505b605713084bb2138cac12e38447e40f6de25c558956449cf591706d7528","tlsh":"a50221dd165512314d7fbbfb9e965518ff2602eb220091d1b8ae42401f72a144366eff"}],"package_integrity":[{"filename":"postcss-selector-minify-2.0.0.tgz","hashes":{"sha1":"8335df7c9e774806f61602c8284a35795f195386","sha512_sri":"sha512-J5qvmnFs6yuF/otnXiGyu1Jmj8s6sEFrA07H4P+lMN9gN4E0oU5qtcdVPNgImZErIZhlsq70sDUir+jklHKmaw=="}}]}}}],"references":[{"type":"PACKAGE","url":"https://www.npmjs.com/package/postcss-selector-minify/v/2.0.0"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-pjfj-gp2h-5692"},{"type":"PACKAGE","url":"https://www.npmjs.com/package/postcss-selector-minify/v/1.0.0"}],"database_specific":{"malicious-packages-origins":[{"id":"IN-MAL-2026-010562","import_time":"2026-07-14T20:28:24.753368625Z","modified_time":"2026-07-14T20:18:29Z","sha256":"92fec62079856815ded46ba283769d3d3e0d20e08b6196b8698e08e2df6677ee","source":"amazon-inspector","versions":["2.0.0"]},{"id":"GHSA-pjfj-gp2h-5692","import_time":"2026-08-20T14:26:12.003846997Z","modified_time":"2026-08-20T13:57:30Z","ranges":[{"events":[{"introduced":"0"}],"type":"SEMVER"}],"sha256":"154dbe50ec546f28c72556086a952dcfd2e59a0f016d513b7bdd0e7e95602937","source":"ghsa-malware"},{"id":"IN-MAL-2026-018476","import_time":"2026-08-20T21:43:26.490936017Z","modified_time":"2026-08-20T21:16:20Z","sha256":"7d9be627bc0ae504389b558d7a6b4cc6b4c0564f35804ad31764d91c0b414dc7","source":"amazon-inspector","versions":["1.0.0"]}]},"credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"}]}数据来源:OpenSSF Malicious Packages · Apache-2.0