Skip to main content

NLTK CVE-2026-126304

| EUVDEUVD-2026-125216 HIGH
Improper Link Resolution Before File Access (CWE-59)
8.7
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Deliver attacker-controlled YCOE corpus into an allowlisted data root
  2. Delivery
    Plant psd/pos entries as directory symlinks
  3. Exploit
    YCOECorpusReader.join() returns pointer after lexical-only check
  4. Execution
    CorpusReader.__init__ validates without required_root, accepts escaped target
  5. Persist
    Nested sub-reader root now points outside corpus root
  6. Impact
    parsed_sents()/tagged_words() return out-of-root file content

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Symlink resolution safety
Exploitation Conditions

Requires a POSIX host (directory symlinks), pathsec.ENFORCE=True (the default in affected 3.10.0-3.10.3 releases), and attacker control over the directory contents of a YCOE corpus that the victim application loads under an allowlisted NLTK data root - specifically the ability to plant the corpus's 'psd' and 'pos' entries as directory symlinks pointing at another in-sandbox location. The victim must then invoke YCOECorpusReader methods such as parsed_sents(), tagged_words(), tagged_sents(), or words(). Limiting factors: disclosure is read-only and strictly bounded to the allowed NLTK data sandbox (a symlink whose target resolves outside every allowed root is rejected at construction with PermissionError, so this is not arbitrary-filesystem read); there is no integrity or availability impact; and the attacker must successfully deliver or plant a malicious corpus that the victim loads. On 3.9.4, ENFORCE defaults to False, so the per-corpus-root control this report concerns is not active by default there.

Impact

The input CVSS 4.0 base score of 8.7 (AV:N/AC:L/AT:N/PR:N/UI:N/VC:H) frames this as a high-severity, network, unauthenticated information-disclosure flaw, but the detailed GHSA evidence shows the practical risk is materially narrower than that vector implies. Exploitation is not opportunistic remote access: it requires the attacker to control the directory contents of a YCOE corpus that a victim application actually loads under pathsec.ENFORCE=True on a POSIX host, and the disclosure is bounded to the allowed NLTK data sandbox (a symlink resolving outside every allowed root is rejected at construction with PermissionError), so this is cross-corpus-root read, not arbitrary-filesystem read. There is no EPSS score and no CISA KEV listing in the input, so there is no evidence of active or widespread exploitation; the vuln.today Decision label is this_week, not act_now or emergency. A working proof-of-concept is embedded in the GHSA advisory (output shows 'ESCAPE CONFIRMED'), which raises reproducibility, but PoC availability is distinct from in-the-wild exploitation. Net: a genuine, VulnCheck-reported disclosure bug worth remediating on a this-week cadence, but the AV:N/PR:N/UI:N vector overstates real exposure because it omits the precondition that the victim must load an attacker-controlled corpus; the real risk concentrates in multi-tenant or automated-corpus-ingestion deployments. Note also a data conflict: top-level metadata says a patch is available / fixed in 3.10.4, while the GHSA advisory body states the reader is 'not fixed' - this should be verified with the vendor before relying on an upgrade.

Exploit ScenarioDerived

In a multi-tenant or automated-ingestion NLTK deployment, an attacker supplies a YCOE corpus whose 'psd' and 'pos' entries are directory symlinks pointing at another directory inside the allowed NLTK data root (for example another tenant's corpus or the shared system temp directory). When the victim application constructs YCOECorpusReader on that corpus and calls parsed_sents() or tagged_words(), it returns file content from outside the corpus root but inside the sandbox, yielding read-only cross-corpus-root disclosure. A working PoC demonstrating the escape against published PyPI sdists (3.10.0 and 3.10.3) is included in the GHSA advisory; with AV:N/AC:L the mechanics are simple once the attacker can place a corpus the victim loads.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 13, 2026

Cross-corpus information disclosure in NLTK's YCOECorpusReader (3.10.0 through 3.10.3) lets an attacker who controls a YCOE corpus's directory contents plant 'psd' or 'pos' directory symlinks so that parsed_sents(), tagged_words(), tagged_sents() and words() return file content from outside the YCOE corpus root. The escape is read-only and bounded to the allowed NLTK data sandbox - a symlink whose target resolves outside every allowed root is rejected at construction with PermissionError - but on shared or multi-tenant ingestion hosts the reachable scope includes other corpora under the shared data path and the shared system temporary directory, which is an allowed root by default. A public proof-of-concept reproduction against the published 3.10.0 and 3.10.3 sdists accompanies the GHSA advisory; no CISA KEV listing or confirmed active exploitation was provided. The vendor's CVSS 4.0 base of 8.7 describes an unauthenticated network flaw, whereas the assessed vector requires user interaction in that the victim application must load the attacker-supplied corpus and invoke the reader, and a fix is shipped in 3.10.4.

RemediationAI

Upgrade nltk to 3.10.4, the vendor-released fix, per the GHSA advisory at https://github.com/nltk/nltk/security/advisories/GHSA-qg35-44qx-7vrr. If the upgrade cannot be applied immediately, the effective compensating control is to treat YCOE corpora as untrusted input at the filesystem level: before constructing YCOECorpusReader, reject any corpus whose 'psd' or 'pos' entries are symlinks or whose realpath escapes the corpus root (for example by comparing os.path.realpath against the corpus root as the advisory's recommended validate_path(..., required_root=self.root) check would), since the reader itself performs no such resolution at construction and a real-directory negative control stays contained; the trade-off is that legitimate corpora distributed with symlinked layout components will be refused and must be materialized as real directories. Additionally, avoid loading downloaded, shared or otherwise attacker-influenced YCOE corpora entirely, and, where the deployment allows it, narrow nltk.data.path so the shared system temporary directory is not an allowed root - accepting that this is a default allowed root many workloads rely on and that rebinding it can break corpus and resource lookups that resolve through temp paths. Note that on 3.9.4 the pathsec per-corpus-root enforcement is off by default, so enabling ENFORCE there does not by itself close this nested-reader gap; the patched reader in 3.10.4 remains the complete fix.

Affected VersionsENISA

nltk 3.10.0 <3.10.4

Affected Packages

pypi nltk fix: 3.10.4

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

NLTK 3.10.x ships pathsec, a containment layer intended to confine each corpus reader to its own corpus root (validate_path(..., required_root=...) at read time) on top of a global sandbox check against nltk.data.path; ENFORCE defaults to True in this line (3.9.4 ships ENFORCE=False, so that per-root control is not active there by default). This is a CWE-59 link-following defect in the construction of nested sub-readers. YCOECorpusReader.__init__ derives two nested reader roots from self.root.join("psd") and self.root.join("pos"); FileSystemPathPointer.join() in nltk/data.py performs only a lexical containment test (relative to an os.path.abspath root, using normpath and a prefix comparison) and never calls resolve(), so a directory symlink named psd or pos satisfies the check. CorpusReader.__init__ then validates the resulting sub-reader root by calling validate_path without required_root, which skips the scoped per-corpus-root layer and runs only the global sandbox layer; that layer resolves the symlink, finds the target inside an allowed root, and accepts the sub-reader with its root anchored at the escaped location. Because the read-time guard validate_path(path, required_root=self._root) and find_corpus_fileids' realpath/commonpath descent check both operate against the sub-reader's own already-escaped root, no later check re-anchors the read to the YCOE corpus root. The trigger requires a POSIX host (directory symlinks), ENFORCE at its default True, and attacker control of the corpus directory contents; the advisory states no fix commit touching nltk/corpus/reader/ycoe.py existed at review time and recommends validating each nested root against the parent corpus root.

Know when Nltk gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 8.7 HIGH
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
vuln.today AI 6.5 MEDIUM

Exploitation hinges on the victim loading an attacker-controlled corpus (UI:R); disclosure is read-only and bounded to the NLTK data sandbox, so C:H with I:N and A:N.

3.1 AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Nov 13, 2026 - 10:02 EUVD
CVE Published
Nov 13, 2026 - 09:36 cve.org
HIGH 8.7

DescriptionCVE.org

NLTK from 3.10.0 before 3.10.4 contains a symlink escape vulnerability in YCOECorpusReader that allows attackers to read files outside the corpus root by planting psd or pos directory symlinks. Attackers controlling a YCOE corpus can make parsed_sents() and tagged_words() return file content from other corpora or temporary files within the NLTK data sandbox.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 6 pypi packages depend on nltk (6 direct, 0 indirect)

Ecosystem-wide dependent count for version 3.10.0.

Technical POC Analysis

CWE-59 (Improper Link Resolution Before File Access).

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

A high-severity vulnerability in NLTK versions 3.10.0 through 3.10.3 allows an attacker to read files outside a corpus root by planting symbolic links in YCOE corpus data. Organizations using NLTK for natural language processing on shared or multi-tenant hosts are affected, where an attacker could potentially access other corpora or temporary files. Leadership should prioritize patching because the flaw enables information disclosure and a public proof-of-concept exists, increasing the risk of exploitation.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.5%
Top 55% exploitable
Prevalence
High
NLTK is a very widely used Python NLP library; YCOE attack path is niche
Threat Intel
1
1 sources
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
High

Priority Score

45
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Nltk

View all
CVE-2026-79657 CRITICAL POC
9.3 Aug 25

Arbitrary code execution in the Natural Language Toolkit (NLTK) before 3.10.3 allows attackers to bypass the library's p

CVE-2026-78683 CRITICAL POC
9.4 Aug 25

Arbitrary code execution in NLTK (Natural Language Toolkit) through 3.9.4 allows attackers to run Python code when a vic

CVE-2025-14009 HIGH POC
8.8 Feb 18

Arbitrary code execution in the NLTK (Natural Language Toolkit) Python library affects all versions through its data dow

CVE-2026-63312 HIGH POC
8.7 Aug 22

StreamBackedCorpusView in NLTK before 3.10.0 allows arbitrary local file reads by calling Python's builtins.open() direc

CVE-2026-62384 HIGH POC
8.7 Aug 22

Symlink-based path traversal in NLTK's FramenetCorpusReader before version 3.10.2 permits attackers with write access to

CVE-2026-126297 HIGH POC
8.7 Nov 13

CPU exhaustion in NLTK's ConllCorpusReader.srl_instances() lets an attacker who supplies a crafted CoNLL SRL corpus pin

CVE-2026-126298 HIGH POC
8.7 Nov 13

CPU exhaustion in NLTK's Tree.chomsky_normal_form() right-factor binarization affects NLTK through 3.10.3 and lets remot

CVE-2026-126299 HIGH POC
8.7 Nov 13

Quadratic CPU exhaustion in NLTK's CCG lexicon parser (nltk.ccg.lexicon.fromstring, also re-exported as nltk.ccg.chart.f

CVE-2026-126303 HIGH POC
8.7 Nov 13

Denial of service in NLTK before 3.10.4 allows remote attackers to pin a CPU core and exhaust bounded worker pools by ca

CVE-2026-66393 HIGH POC
8.7 Aug 22

Unbounded recursion in NLTK's JSONTaggedDecoder.decode_obj() (nltk/jsontags.py) allows unauthenticated remote attackers

CVE-2026-62388 HIGH POC
8.7 Aug 22

Path traversal and pickle deserialization protections in NLTK before 3.10.0 are effectively disabled by default - pathse

CVE-2026-78681 HIGH POC
8.7 Aug 25

XML Entity Expansion (Billion Laughs) in NLTK before 3.10.3 allows unauthenticated remote attackers to cause denial of s

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy