Inefficient Algorithmic Complexity Affecting pyyaml package, versions [3.10,]


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.88% (61st 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-PYTHON-PYYAML-23352466
  • published3 Dec 2026
  • disclosed2 Dec 2026
  • creditZachariah Mithani

Introduced: 2 Dec 2026

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

How to fix?

A fix was pushed into the master branch but not yet published.

Overview

Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity in the construct_yaml_int function in lib/yaml/constructor.py. An attacker can exhaust CPU on the parsing thread by submitting to safe_load, SafeLoader, CSafeLoader, or FullLoader a YAML scalar matching the sexagesimal (base-60) integer pattern with many colon-separated groups, since the function's big-integer accumulation loop grows quadratically with the group count. No non-default configuration is required, since the vulnerable code path is reached through the loaders PyYAML itself documents as safe for untrusted input.

CVSS Base Scores

version 4.0
version 3.1