CVE-2026-12072: Path Traversal in NLTK NKJPCorpusReader
CVE-2026-12072 is a path traversal vulnerability in the Python Natural Language Toolkit (NLTK) NKJPCorpusReader. Attacker-controlled values passed through the fileids argument of public read methods can escape the corpus root and access arbitrary files, bypassing nltk.pathsec sandbox protections even when ENFORCE=True. The header() method can directly disclose out-of-root file contents; other affected methods can also open and read files outside the corpus root. The vulnerability is rated High, with a CVSS v3.0 score of 7.5, and is fixed in NLTK 3.10.0.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation can disclose files outside the intended corpus directory that are readable by the application process, potentially exposing sensitive host or application data. The vulnerability-specific CVSS vector indicates high confidentiality impact, with no integrity or availability impact.
Mitigation
If you can’t patch tonight, do this now.
Do not pass attacker-controlled values to NKJPCorpusReader fileids. Restrict fileids to a strict allowlist of known corpus entries and enforce canonical path containment within the corpus root before use. In multi-tenant or web deployments, disable untrusted access to affected reader operations until patched. Do not rely on nltk.pathsec.ENFORCE=True to prevent exploitation.
Remediation
Patch, then assume compromise.
Upgrade NLTK and its related packages to version 3.10.0 or later. For VMware Tanzu Greenplum deployments, version 7.8.4 is identified as containing a fix for this CVE; apply the applicable vendor component updates.
Exploits
No public exploits tracked yet. Mallory keeps watching.
References
Frequently asked questions
- Is CVE-2026-12072 exploited in the wild?
- As of Nov 7, 2026, Mallory has no reports of CVE-2026-12072 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2026-12072?
- As of Nov 7, 2026, Mallory has found no public exploit for CVE-2026-12072.
- Is there a patch for CVE-2026-12072?
- Upgrade NLTK and its related packages to version 3.10.0 or later. For VMware Tanzu Greenplum deployments, version 7.8.4 is identified as containing a fix for this CVE; apply the applicable vendor component updates.
Recent activity
2 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.