{"id":"MAL-2026-10060","revision":"3b7fef2316824988b7994879e0999944","records":[{"revision":"3b7fef2316824988b7994879e0999944","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"MAL-2026-10060","aliases":[],"title":"Malicious code in cookie-parser-js (npm)","description":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (c6c2bd7c1b5b363e72753401f6edebf816965a625227e6523210e4620ce9bb8a)\ncookie-parser-js impersonates the widely used cookie-parser package: it copies TJ Holowaychuk / Doug Wilson author metadata, the description, the README (which self-identifies as cookie-parser-ease), and the expressjs repository slug. package.json declares an undocumented runtime dependency `cookie-js-ease` pinned to the mutable tag `latest`, and index.js does `var Cookies = require('cookie-js-ease'); Cookies.set(\"\", \"\", {expires: 0})` inside the exported cookieParser factory. The Cookies.set call passes empty key/value with expires:0 — a functional no-op whose only effect is to force load and execute the transitive dependency when a consumer requires('cookie-parser-js') and invokes the middleware. `cookie-js-ease` is not a known cookie library and appears fabricated to serve as the payload carrier: because it is pinned to `latest`, its author (controlled by the same actor) can push arbitrary code at any time, giving them code execution inside any consumer application that loads this middleware. The name-similarity to cookie-parser (a top-download express middleware) plus the borrowed identity of its real maintainers is a deliberate confusion attack targeting developers who mistype the package name.\n","state":0,"publishedAt":"2026-07-09T16:19:27+00:00","modifiedAt":"2026-07-10T17:17:01.9018273+00:00","affected":[{"ecosystem":"npm","name":"cookie-parser-js","ranges":[],"versions":["1.4.8","1.4.9","1.5.0","1.0.8","1.5.3","1.5.2","1.5.1"],"rawVersionEvidence":null}],"metrics":[],"references":["https://www.npmjs.com/package/cookie-parser-js/v/1.4.8","https://www.npmjs.com/package/cookie-parser-js/v/1.4.9","https://www.npmjs.com/package/cookie-parser-js/v/1.5.0","https://www.npmjs.com/package/cookie-parser-js/v/1.0.8","https://www.npmjs.com/package/cookie-parser-js/v/1.5.3","https://www.npmjs.com/package/cookie-parser-js/v/1.5.2","https://www.npmjs.com/package/cookie-parser-js/v/1.5.1"],"sourceUrl":"https://osv.dev/vulnerability/MAL-2026-10060","license":"OSV · upstream source license applies","key":"osv:MAL-2026-10060","identifiers":["MAL-2026-10060"]},"retained":false,"historicalAffected":[]}],"coverage":[]}