Inefficient regular expression complexity in Natural Language Toolkit - #VU142776

 

Inefficient regular expression complexity in Natural Language Toolkit - #VU142776

Published: August 15, 2026


Vulnerability identifier: #VU142776
CSH Severity: Medium
CVSS v4: 8.2 [CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N]
CVE-ID: N/A
CWE-ID: CWE-1333
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to cause a denial of service.

The vulnerability exists due to inefficient regular expression complexity in the nltk tgrep module _tgrep_node_action() function when processing user-supplied regular expressions in /regex/ nodes. A remote attacker can send a specially crafted tgrep pattern to cause a denial of service.

Applications are affected when they expose the tgrep API to external input, including via tgrep_positions() or tgrep_compile().


Affected software

Natural Language Toolkit

Remediation

Install security update from vendor's website.

Natural Language Toolkit - update to 3.10.3

External References

Related Security Bulletins