{"id":"UBUNTU-CVE-2026-46625","details":"JavaScript Cookie is a JavaScript API for handling cookies, client-side. Prior to version 3.0.7, js-cookie's internal assign() helper copies properties with for...in + plain assignment. When the source object is produced by JSON.parse, the JSON object's \"__proto__\" member is an own enumerable property, so the for…in enumerates it and the target[key] = source[key] write triggers the Object.prototype.__proto__ setter on the fresh target ({}). The result is a per-instance prototype hijack: Object.prototype itself is untouched, but the merged attributes object now inherits attacker-controlled keys. Because the consuming set() function then enumerates the merged object with another for...in, every key the attacker placed on the polluted prototype lands in the resulting Set-Cookie string as an attribute pair. The attacker can set domain=, secure=, samesite=, expires=, and path= on cookies whose attributes the developer thought were locked down. This issue has been patched in version 3.0.7.","modified":"2026-06-30T18:18:16.846246893Z","published":"2026-06-10T22:16:00Z","upstream":["CVE-2026-46625"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2026-46625"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2026-46625"},{"type":"REPORT","url":"https://github.com/js-cookie/js-cookie/commit/eb3c40e89731e99b8970faaf35ddad249c6c0020"},{"type":"REPORT","url":"https://github.com/js-cookie/js-cookie/releases/tag/v3.0.7"},{"type":"REPORT","url":"https://github.com/js-cookie/js-cookie/security/advisories/GHSA-qjx8-664m-686j"}],"affected":[{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.0-1"],"ecosystem_specific":{"binaries":[{"binary_name":"node-js-cookie","binary_version":"2.2.0-1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}},{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.0-2","2.2.1-1"],"ecosystem_specific":{"binaries":[{"binary_version":"2.2.1-1","binary_name":"node-js-cookie"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}},{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.1-1","2.2.1-2","3.0.1+~3.0.0-2"],"ecosystem_specific":{"binaries":[{"binary_version":"3.0.1+~3.0.0-2","binary_name":"node-js-cookie"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}},{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["3.0.1+~3.0.0-3"],"ecosystem_specific":{"binaries":[{"binary_name":"node-js-cookie","binary_version":"3.0.1+~3.0.0-3"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}},{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:25.10","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=questing"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["3.0.1+~3.0.0-3"],"ecosystem_specific":{"binaries":[{"binary_version":"3.0.1+~3.0.0-3","binary_name":"node-js-cookie"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}},{"package":{"name":"node-js-cookie","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/node-js-cookie?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["3.0.1+~3.0.0-3"],"ecosystem_specific":{"binaries":[{"binary_name":"node-js-cookie","binary_version":"3.0.1+~3.0.0-3"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-46625.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N"},{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N"},{"type":"Ubuntu","score":"medium"}]}