CVE-2026-126299

NLTK: Quadratic-time CPU denial of service in CCG lexicon parser (fromstring) on wide bracket bodies and operator chains

High published · updated · also known as GHSA-89P3-FCCH-88PH

8.7
CVSS score out of 10 · NVD (vulncheck.com)

Description

NLTK before 3.10.4 contains a denial of service vulnerability in the CCG lexicon parser fromstring that allows remote attackers to exhaust CPU by supplying wide inputs. Attackers can submit lexicon text with long flat bracket bodies or operator chains, triggering quadratic string re-slicing in matchBrackets and augParseCategory that blocks worker threads.

Affected products and versions

Product / packageEcosystem / vendorVersionsFixed inSource
nltk pip <= 3.10.33.10.4 GitHub

References