{"id":"GHSA-p95v-992w-h6c3","revision":"4ec23f17785c4043abcd5e1cf1b07902","records":[{"revision":"4ec23f17785c4043abcd5e1cf1b07902","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-p95v-992w-h6c3","aliases":["CVE-2026-82404"],"title":"TOON: Prototype pollution when decoding untrusted TOON input","description":"### Summary\n\nDecoding attacker-controlled TOON containing a `__proto__`, `constructor`, or `prototype` key wrote through the object's prototype chain instead of creating an own property, polluting `Object.prototype` for the whole runtime. The `expandPaths: 'safe'` path (dotted keys such as `a.__proto__.x`) was the strongest vector; plain nested objects, tabular rows, and quoted keys were all affected. The encoder had a matching defect: it silently dropped own `__proto__` properties and could fire an inherited setter while normalizing.\n\n### Impact\n\nAny service that decodes untrusted TOON is affected. Prototype pollution can escalate to denial of service or, with a suitable downstream gadget, remote code execution.\n\n### Patches\n\nUpgrade to `@toon-format/toon@2.3.1`. Decoders now materialize `__proto__`/`constructor`/`prototype` as ordinary own data properties, matching `JSON.parse` semantics; the encoder preserves the same keys without invoking inherited accessors.\n\n### Workarounds\n\nNone. Upgrade is the only fix. Callers who cannot upgrade should reject input whose keys include `__proto__`, `constructor`, or `prototype` before decoding.\n\n### Port maintainers\n\nThe same bug shape can exist in any implementation that assigns decoded keys with `obj[key] = value`. Rust, Swift, Java, Python, and C# ports should audit their object-construction and path-expansion paths for the three prototype keys.","state":0,"publishedAt":"2026-09-03T19:52:08+00:00","modifiedAt":"2026-09-03T20:00:04.9330411+00:00","affected":[{"ecosystem":"npm","name":"@toon-format/toon","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"2.3.1"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/toon-format/toon/security/advisories/GHSA-p95v-992w-h6c3","https://nvd.nist.gov/vuln/detail/CVE-2026-82404","https://github.com/toon-format/toon/pull/316","https://github.com/toon-format/toon/commit/94a2b7560b2b5ed903a4d466a3bce8b13daa2660","https://github.com/toon-format/toon","https://github.com/toon-format/toon/releases/tag/v2.3.1"],"sourceUrl":"https://github.com/advisories/GHSA-p95v-992w-h6c3","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-p95v-992w-h6c3","identifiers":["GHSA-p95v-992w-h6c3","CVE-2026-82404"]},"retained":false,"historicalAffected":[]}],"coverage":[]}