Inefficient Algorithmic Complexity Affecting js-yaml package, versions >=3.0.0 <3.15.0>=4.0.0 <4.3.0


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.37% (30th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-JS-JSYAML-17900054
  • published9 Jul 2026
  • disclosed8 Jul 2026
  • creditMazze LeCzzare Frazer

Introduced: 8 Jul 2026

NewCVE-2026-59869  (opens in a new tab)
CWE-407  (opens in a new tab)

How to fix?

Upgrade js-yaml to version 3.15.0, 4.3.0 or higher.

Overview

js-yaml is a human-friendly data serialization language.

Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity in merge key (<<) handling during YAML parsing, where each mapping in a chain re-enumerates the keys inherited from the previous mapping. An attacker can exhaust CPU and cause denial of service by supplying a document with N chained merge mappings, which forces roughly O(N^2) work for O(N) input. Exploitation requires the application to parse untrusted YAML with the default or YAML11 schema, under which merge keys are resolved.

CVSS Base Scores

version 4.0
version 3.1