SB2026080753 - Multiple vulnerabilities in Natural Language Toolkit



SB2026080753 - Multiple vulnerabilities in Natural Language Toolkit

Published: August 7, 2026 Updated: November 22, 2026

Security Bulletin ID SB2026080753
CSH Severity
High
Patch available
YES
Number of vulnerabilities 17
Exploitation vector Remote access
Highest impact Code execution

Breakdown by Severity

High 18% Medium 76% Low 6%
  • Low
  • Medium
  • High
  • Critical

Description

This security bulletin contains information about 17 vulnerabilities.


1) Path traversal (CVE-ID: CVE-2026-63312)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in StreamBackedCorpusView when processing a user-controlled fileid path while pathsec.ENFORCE is enabled. A remote attacker can supply a crafted file path to disclose sensitive information.

XMLCorpusView and corpus reader subclasses that pass a raw string fileid to StreamBackedCorpusView are also affected.


2) Path traversal (CVE-ID: CVE-2026-12072)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to bypass NLTK's strict path sandbox and read parsed NKJP header content from outside the corpus root.

The vulnerability exists due to path traversal in NKJPCorpusReader when it resolves fileids without checking path containment and opens files without invoking sandbox validation. A remote attacker can influence an application's corpus file selection to retrieve out-of-root header content or cause other reader methods to open and read out-of-root files without returning their contents.


3) Path traversal (CVE-ID: CVE-2026-12074)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose parsed contents of readable XML files that match the expected structure and infer the existence or readability of other XML files outside the FrameNet corpus root.

The vulnerability exists due to path traversal in NLTK's FrameNet corpus reader when it opens XML paths without checking that they remain within the corpus root, bypassing the path sandbox even in strict mode. A remote attacker can supply a crafted frame name or provide a crafted corpus index processed by doc() or the lexical-unit loader to access out-of-root XML files.


4) Inefficient regular expression complexity (CVE-ID: CVE-2026-12061)

CWE-ID: CWE-1333 - Inefficient Regular Expression Complexity

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to cause a denial of service in applications that process untrusted review corpora with NLTK.

The vulnerability exists due to an unbounded greedy match in the ReviewsCorpusReader FEATURES regular expression, which can cause quadratic backtracking when scanning review lines for feature annotations. A remote attacker can supply a corpus containing a crafted review line to consume excessive CPU time and stall calls to reviews(), features(), or sents().


5) Server-Side Request Forgery (SSRF) (CVE-ID: CVE-2026-12075)

CWE-ID: CWE-918 - Server-Side Request Forgery (SSRF)

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:L/SI:N/SA:N]


The vulnerability allows a remote attacker to bypass the server-side request forgery filter even in ENFORCE mode and potentially read sensitive responses from internal HTTP services.

The vulnerability exists due to a gap between DNS validation and connection establishment in nltk.pathsec.urlopen when processing URLs for nltk.download or nltk.data.load. A remote attacker can supply a URL subject to DNS rebinding to induce a request to a restricted destination and read its response if the application returns it.


6) Inefficient regular expression complexity (CVE-ID: CVE-2026-80205)

CWE-ID: CWE-1333 - Inefficient Regular Expression Complexity

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N]


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

The vulnerability exists due to inefficient regular expression complexity in nltk.text.Text.findall() and nltk.text.TokenSearcher.findall() when processing user-supplied regular expressions. A remote attacker can send a specially crafted regular expression to cause a denial of service.

The issue is isolated to the nltk.text module and can result in indefinite CPU saturation through catastrophic backtracking in the Python re engine.


7) Deserialization of Untrusted Data (CVE-ID: CVE-2026-78683)

CWE-ID: CWE-502 - Deserialization of Untrusted Data

CVSSv4: 8.6 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to execute arbitrary code.

The vulnerability exists due to deserialization of untrusted data in TransitionParser.parse() when loading a user-supplied model file. A remote attacker can supply a specially crafted pickle file to execute arbitrary code.

User interaction is required to load the crafted model file.


8) Improper access control (CVE-ID: CVE-2026-65915)

CWE-ID: CWE-284 - Improper Access Control

CVSSv4: 7.1 [CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote user to disclose sensitive information.

The vulnerability exists due to improper access control in FileSystemPathPointer.open() in nltk/data.py when handling file:// URLs through nltk.data.load() or user-influenced paths. A remote user can supply a crafted file:// URL or path to read arbitrary files accessible to the process and disclose sensitive information.

Applications are exposed when users can influence the string passed to nltk.data.load() or nltk.data.find().


9) Path traversal (CVE-ID: N/A)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in nltk.data.load() and nltk.data.find() when processing user-supplied resource names containing percent-encoded traversal sequences. A remote attacker can supply a specially crafted resource name to disclose sensitive information.

This issue affects applications that pass user-controlled input to these functions, and percent-encoded sequences such as %2e%2e are decoded after path safety checks.


10) Server-Side Request Forgery (SSRF) (CVE-ID: CVE-2026-54296)

CWE-ID: CWE-918 - Server-Side Request Forgery (SSRF)

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:L/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to server-side request forgery in nltk.pathsec.urlopen when validating a hostname before urllib performs a separate connection-time DNS resolution. A remote attacker can supply a hostname with attacker-controlled DNS rebinding records to disclose sensitive information.

The issue defeats the documented ENFORCE mode and can expose responses from internal-only HTTP services, including loopback administrative interfaces and cloud metadata endpoints.


11) Server-Side Request Forgery (SSRF) (CVE-ID: CVE-2026-63311)

CWE-ID: CWE-918 - Server-Side Request Forgery (SSRF)

CVSSv4: 6.9 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to perform server-side request forgery.

The vulnerability exists due to improper control of outbound network requests in validate_network_url() in nltk/pathsec.py when handling URLs whose hostname resolution fails. A remote attacker can supply a crafted URL to perform server-side request forgery.

The issue is caused by a fail-open condition when DNS resolution returns an error and _resolve_hostname() returns an empty list, which can also enable bypass after DNS rebinding once the cache entry expires.


12) Insecure Default Initialization of Resource (CVE-ID: CVE-2026-62388)

CWE-ID: CWE-1188 - Insecure Default Initialization of Resource

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to initialization of a resource with an insecure default in the pathsec security module when processing security validation checks with ENFORCE disabled by default. A remote attacker can supply a crafted path or unsafe source to bypass security checks and disclose sensitive information.

The module emits RuntimeWarning messages instead of raising exceptions, so execution continues after a violation is detected.


13) Path traversal (CVE-ID: CVE-2026-62385)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.2 [CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in FramenetCorpusReader.frame_by_name, FramenetCorpusReader.doc, FramenetCorpusReader.lu, and NKJPCorpusReader.header when parsing caller-controlled selectors or trusted-looking index state into XML file paths. A remote attacker can supply crafted selectors, poisoned index state, or unsafe file identifiers to disclose sensitive information.

Exploitation requires the application to expose FrameNet or NKJP reader APIs and trust them to confine XML parsing to a corpus root.


14) Path traversal (CVE-ID: CVE-2026-54293)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in nltk.data.load() and related path handling in nltk/data.py when processing attacker-controlled nltk: resource URLs containing URL-encoded path separators or traversal segments. A remote attacker can supply a specially crafted resource identifier to disclose sensitive information.

The issue is caused by a decode-after-check flaw in which unsafe-path regex checks are performed before url2pathname() decodes percent-encoded sequences.


15) Path traversal (CVE-ID: CVE-2026-54294)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in NKJPCorpusReader when processing attacker-influenced fileids in public read methods. A remote attacker can supply crafted fileids containing directory traversal sequences to disclose sensitive information.

The issue bypasses the nltk.pathsec sandbox even when ENFORCE is set to true, and the header() method returns content from out-of-root files to the caller.


16) Path traversal (CVE-ID: CVE-2026-54292)

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N]


The vulnerability allows a remote attacker to disclose sensitive information.

The vulnerability exists due to path traversal in FramenetCorpusReader.frame() when processing a caller-supplied frame name. A remote attacker can supply a crafted frame name containing traversal sequences to disclose sensitive information.

The issue bypasses the nltk.pathsec sandbox even when ENFORCE=True. If the target is not frame-shaped XML, parsing errors can still reveal file existence or readability.


17) Inefficient regular expression complexity (CVE-ID: CVE-2026-54295)

CWE-ID: CWE-1333 - Inefficient Regular Expression Complexity

CVSSv4: 8.7 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N]


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

The vulnerability exists due to inefficient regular expression complexity in the ReviewsCorpusReader FEATURES regex when parsing a crafted bracket-less review line. A remote attacker can supply a specially crafted reviews corpus line to cause a denial of service.

A single crafted line can hang the reviews(), features(), and sents() processing paths.


Remediation

Install update from vendor's website.