Read the docs

NLTK: Compile-time regex DoS via group-dense patterns bypasses match timeout

Priority HIGH 72CWE-1333Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
Low
Impact type
Denial of service
Confidentiality · integrity · availability
None · None · High
Fix status
Fixed

Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-1333.

Summary

NLTK from 3.10.0 before 3.10.4 is vulnerable to a compile-time regular expression denial of service (CWE-1333, CWE-400). TokenSearcher.findall and Text.findall accept caller-controlled regular expressions with many capturing groups, and from 3.10.3 nltk.redos.compile and RegexpTokenizer expose the same vector. The third-party regex engine compiles group-dense patterns at roughly quadratic cost before the match-time timeout starts, so a small unauthenticated request can exhaust CPU. CVSS 3.1 base score 7.5 (HIGH).

Written with Claude Haiku 5.5 from the sources below · 2026-11-20

Description from the CNA

NLTK (Natural Language Toolkit) is a suite of open source Python modules, data sets, and tutorials supporting research and development in Natural Language Processing. From 3.10.0 until 3.10.4, TokenSearcher.findall and Text.findall accept caller-controlled regular expressions with an unbounded number of capturing groups throughout the affected range. Starting in 3.10.3, nltk.redos.compile and RegexpTokenizer expose the same compile-time vector. The third-party regex engine compiles group-dense patterns with roughly quadratic cost before the match-time timeout begins, allowing a small unauthenticated request to exhaust CPU and deny service. This issue is fixed in version 3.10.4.

Why it matters now

Exploitation Proof of concept CISA SSVC · not in CISA KEV
EPSS 0.0063 44th percentileScored 2026-11-30
Fix Fixed nltk (nltk): 3.10.4nltk (PyPI): 3.10.4

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
Poc
Automatable
Yes
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
nltknltk3.10.0 to before 3.10.43.10.4Patch availableCNA
—nltk (PyPI)3.10.0 to before 3.10.43.10.4Patch availableGHSA-32p6-cwhc-8r78
  • nltk Vendornltk Affected 3.10.0 to before 3.10.4 Fixed in 3.10.4 Patch available CNA
  • nltk (PyPI) Vendor— Affected 3.10.0 to before 3.10.4 Fixed in 3.10.4 Patch available GHSA-32p6-cwhc-8r78

CPE names Threatist (inferred) · 1

Inferred from how NVD named this product before; not given by a source.

CPEVersionsRoleVendor
cpe:2.3:a:nltk:nltk:*:*:*:*:*:*:*:*——nltk
  • cpe:2.3:a:nltk:nltk:*:*:*:*:*:*:*:* Versions — — ·nltk

Remediation

Upgrade NLTK to version 3.10.4 on PyPI.

Written with Claude Haiku 5.5 from the sources below · 2026-11-20

  • Fix · CNA nltk (nltk) Fixed in 3.10.4
  • Fix · GHSA-32p6-cwhc-8r78 nltk (PyPI) Fixed in 3.10.4 Advisory →

Timeline

  1. 2026-11-19 Threatist record created from CVE-2026-129229
  2. 2026-11-20 Alias added: GHSA-32p6-cwhc-8r78
  3. 2026-11-20 Fix available: PyPI/[email protected] · GHSA-32p6-cwhc-8r78
  4. 2026-11-20 CVSS score added · GHSA-32p6-cwhc-8r78
  5. 2026-11-20 Weakness changed · GHSA-32p6-cwhc-8r78
  6. 2026-11-20 6 new references · GHSA-32p6-cwhc-8r78
  7. 2026-11-20 CISA SSVC decision points changed
  8. 2026-11-21 EPSS moved to the below the 50th percentile

References

  • TI-2026-95059 NLTK incomplete fix allows JVM sandbox bypass via launcher tokens CVSS 3.1CRITICAL 9.8
  • TI-2026-00629 Arbitrary Code Execution in NLTK StanfordSegmenter via Untrusted JAR Loading CVSS 3.0CRITICAL 10.0
  • TI-2025-12800 Zip Slip Vulnerability in nltk/nltk Leading to Remote Code Execution CVSS 3.0CRITICAL 10.0
  • TI-2026-55173 NLTK before 3.10.3 JVM Argument Injection via Per-Call Options CVSS 4.0CRITICAL 9.3
  • TI-2026-55155 NLTK before 3.10.3 Remote Code Execution via Unsafe Pickle Deserialization CVSS 4.0CRITICAL 9.3
  • TI-2026-91242 Symlink escape in NLTK YCOECorpusReader lets attackers read files CVSS 4.0HIGH 8.7
See all 77 →

Sources