CVE-2026-59870

js-yaml is a JavaScript YAML parser and dumper. Prior to 3.15.1, 4.3.1, and 5.2.1, YAML11_SCHEMA support for the !!omap tag in src/tag/sequence/omap.ts uses omapTag.addItem() to perform a linear duplicate-key scan on every insertion, causing O(n^2) CPU consumption when yaml.load() parses a crafted ordered-map document. In v3 and v4, !!omap is active and exploitable by default. v5 doesn't use !!omap by default, and the chances of activating it are very low.This issue is fixed in 3.15.1, 4.3.1, and 5.2.1.
Configurations

Configuration 1 (hide)

cpe:2.3:a:nodeca:js-yaml:*:*:*:*:*:node.js:*:*

History

25 Oct 2026, 20:10

Type Values Removed Values Added
Summary
  • (es) js-yaml es un analizador y volcador YAML de JavaScript. Versiones anteriores a la 3.15.1, 4.3.1 y 5.2.1, el soporte de YAML11_SCHEMA para la etiqueta !!omap en src/tag/sequence/omap.ts utiliza omapTag.addItem() para realizar un escaneo lineal de claves duplicadas en cada inserción, lo que provoca un consumo de CPU de O(n^2) cuando yaml.load() analiza un documento de mapa ordenado manipulado. En las versiones 3 y 4, !!omap está activo y es explotable por defecto. La versión 5 no utiliza !!omap por defecto, y las posibilidades de activarlo son muy bajas. Este problema se ha solucionado en la 3.15.1, 4.3.1 y 5.2.1.

06 Oct 2026, 16:17

Type Values Removed Values Added
References
  • () https://github.com/nodeca/js-yaml/commit/22a8071ef032117bc6249c330b240ac3aa2d3ded -
  • () https://github.com/nodeca/js-yaml/commit/c3cc4b0bb9ddb9af2dd9b61e0d56f5ce7983cd4a -
  • () https://github.com/nodeca/js-yaml/releases/tag/3.15.1 -
  • () https://github.com/nodeca/js-yaml/releases/tag/4.3.1 -
CVSS v2 : unknown
v3 : 5.3
v2 : unknown
v3 : 7.5
Summary (en) js-yaml is a JavaScript YAML parser and dumper. From 5.0.0 before 5.2.1, YAML11_SCHEMA support for the !!omap tag in src/tag/sequence/omap.ts uses omapTag.addItem() to perform a linear duplicate-key scan on every insertion, causing O(n^2) CPU consumption when yaml.load() parses a crafted ordered-map document. This issue is fixed in version 5.2.1. (en) js-yaml is a JavaScript YAML parser and dumper. Prior to 3.15.1, 4.3.1, and 5.2.1, YAML11_SCHEMA support for the !!omap tag in src/tag/sequence/omap.ts uses omapTag.addItem() to perform a linear duplicate-key scan on every insertion, causing O(n^2) CPU consumption when yaml.load() parses a crafted ordered-map document. In v3 and v4, !!omap is active and exploitable by default. v5 doesn't use !!omap by default, and the chances of activating it are very low.This issue is fixed in 3.15.1, 4.3.1, and 5.2.1.

Information

Published : 2026-07-08 16:16

Updated : 2026-10-25 20:10


NVD link : CVE-2026-59870

Mitre link : CVE-2026-59870

CVE.ORG link : CVE-2026-59870


JSON object : View

Products Affected

nodeca

  • js-yaml
CWE
CWE-407

Inefficient Algorithmic Complexity

CWE-770

Allocation of Resources Without Limits or Throttling