rewindex

RewindexCVEs

CVE-2026-46625: JavaScript Cookie: Per-instance prototype hijack in assign() enables cookie-attribute injection

High · CVSS 7.5 (CVSS 3.1)EPSS 0.92%, 60th percentilePublished Updated Assigner: GitHub_M

Description

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.

Vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N · CWE-1321

Tracked companies

BitbucketConfluenceJira

Mapped from the CVE’s affected-product data, NVD CPE matches, vendor advisories or package feeds. A mapping means the vendor’s software is named, not that its hosted service was exposed.

Status incidents that name it

No tracked status incident names this CVE.

Affected vendors and products

js-cookie: js-cookieRed Hat: Cryostat 4 on RHEL 9Red Hat: OpenShift LightspeedRed Hat: Red Hat 3scale API Management Platform 2Red Hat: Red Hat Advanced Cluster Security for Kubernetes 4.10Red Hat: Red Hat Ansible Automation Platform 2Red Hat: Red Hat Ansible Automation Platform 2.1Red Hat: Red Hat Ansible Automation Platform 2.2Red Hat: Red Hat Ansible Automation Platform 2.7Red Hat: Red Hat Developer Hub 1.10Red Hat: Red Hat Developer Hub 1.9Red Hat: Red Hat Discovery 2Red Hat: Red Hat Enterprise Linux 10Red Hat: Red Hat Enterprise Linux 8Red Hat: Red Hat Enterprise Linux 9Red Hat: Red Hat JBoss Enterprise Application Platform 7Red Hat: Red Hat JBoss Enterprise Application Platform 8Red Hat: Red Hat JBoss Enterprise Application Platform Expansion PackRed Hat: Red Hat OpenShift AI 3.4Red Hat: Red Hat OpenShift AI (RHOAI)Red Hat: Red Hat OpenShift Container Platform 4Red Hat: Red Hat OpenShift Service Mesh 3.3

References

All CVEsMarkdownJSON