Skip to main content

CVE-2026-61534 — yayson: Prototype pollution in yayson — CVE Details

CRITICAL

yayson: Prototype pollution in Store/LegacyStore deserialization

Published September 11, 2026Updated September 11, 2026Source: OSV

What Should I Do?

Address in Next Maintenance Window

Low exploitation probability (0.84%). Schedule for your next planned update.

Does your project use an affected yayson version?

Paste your package-lock.json to check it for CVE-2026-61534 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.

Check my package-lock.json

Summary

Summary

Store/LegacyStore key internal lookup tables by the type, id, and relationship names from a JSON:API document. Because these were plain objects, a document with type: "__proto__" writes onto Object.prototype, polluting every object in the process.

Severity

Suggested CVSS v3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H (8.1). The guaranteed impact is process-wide DoS / logic corruption; escalation to authorization bypass or RCE is dependent on gadgets in the consuming application.

Affected / Patched

  • Affected: <= 4.2.0 (verified in 3.0.0 and 4.2.0; all 3.x and 4.x).
  • Patched: 4.3.0.

Details

type is a string value, untouched by JSON.parse, and is used directly as an object key:

if (!models[type]) models[type] = {}          // models["__proto__"] is Object.prototype → skipped
if (!models[type][id]) models[type][id] = model // → Object.prototype[id] = model

The attacker controls the polluted key (id) and value (the model, populated from attributes). Pollution persists for the process lifetime. The malicious type can also arrive via an included resource referenced by a relationship, bypassing any data.type allow-list. LegacyStore is additionally reachable when a configured types mapping resolves to "__proto__".

Proof of concept

const { Store } = require('yayson')()
new Store().sync({ data: { type: '__proto__', id: 'polluted', attributes: { x: 1 } } })
console.log(({}).polluted) // { x: 1, id: 'polluted' }  ← Object.prototype polluted

Workarounds

Reject documents whose type or relationship names are __proto__, constructor, or prototype, or run Node with --disable-proto=throw.

Fix

Null-prototype lookup tables, rejection of __proto__/constructor/prototype as document-derived member names, Object.keys() iteration, and null-prototype normalization of caller-supplied caches.

Advisory Timeline

  • First published September 11, 2026 (76 days ago).
  • Last revised September 11, 2026 — 0 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

npm
Update yayson to 4.3.0 or later
npm install yayson@4.3.0

After upgrading, scan your dependencies again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: npm (1).

PackageFixed In
yayson npm · Affected: All versions4.3.0

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

  • CWE-1321
    Prototype PollutionMITRE

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 9.1 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H

Frequently Asked Questions

What is CVE-2026-61534?
yayson: Prototype pollution in Store/LegacyStore deserialization. This vulnerability has been assigned a severity rating of CRITICAL (CVSS score: 9.1/10).
How do I check if my project is affected by CVE-2026-61534?
CVE-2026-61534 affects yayson. It has a 0.8% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-61534 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
9.1

Maximum impact if exploited, often with little effort or access required.

EPSS Score (30-day exploit probability)
0.84%
EPSS percentile: 55.2

This is an above-median EPSS score — 55.2% of tracked vulnerabilities score at or below it, putting its exploitation likelihood in the upper half of the tracked corpus.

Also Known As

GHSA-325j-mg25-8q58

Related CVEs

Check your own dependencies

Free, with no signup for up to 10 packages.

Check my package-lock.json