Skip to main content

NLTK EUVDEUVD-2026-130441

| CVE-2026-128135 HIGH
Improper Link Resolution Before File Access (CWE-59)
2026-11-19 security-advisories@github.com GHSA-wr3g-j6qj-xpgh
7.1
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

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

  1. Access
    Obtain local write access to shared NLTK data root
  2. Delivery
    Pre-plant in-root hardlink at predictable member path
  3. Exploit
    Point hardlink at outside-root victim file
  4. Execution
    Victim runs nltk.download() to install package
  5. Persist
    ZIP extraction truncates/overwrites file through hardlink
  6. Impact
    Outside-root file destroyed or replaced

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 LOCAL write access inside a shared or predictable NLTK data root (for example ~/nltk_data, a group-writable /usr/share/nltk_data, or a shared container volume), so standalone single-user installs are largely unaffected. The attacker must pre-plant an in-root hardlink at the exact archive member path a soon-to-be-installed package will write, and the victim must subsequently run nltk.download() or 'python -m nltk.downloader' to extract a .zip package into that root. Exploitation additionally requires EITHER that kernel hardlink protection (fs.protected_hardlinks) is disabled, OR that the chosen outside-root target is one the attacker is permitted to hardlink (owned, writable, or group-shared) - the demonstrated PoC succeeds even with fs.protected_hardlinks=1 when the target is attacker-owned. Affected NLTK versions are 3.9.4 through 3.10.3; updating to 3.10.4 is the fix. Limiting factors beyond raw CVSS: no remote vector (AV:L), a local account is needed (PR:L), and the shared/predictable-root and hardlink-permission preconditions substantially narrow real-world applicability.

Impact

This is a genuine but bounded issue, not a drop-everything emergency. CVSS 3.1 base score is 7.1 (High) with vector AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H, so the defining constraint is that exploitation is LOCAL (AV:L) and requires a local, low-privileged account (PR:L) - there is no remote attack surface. The impact is integrity/availability only (I:H/A:H, C:N): the primitive is arbitrary destruction/overwrite of a chosen out-of-root file, not data theft. vuln.today assigns a 'this_week' priority, consistent with a serious-but-not-critical local flaw. No EPSS probability was supplied and the CVE is NOT in CISA KEV, so there is no signal of active or widespread exploitation - appropriate given that a local-only bug is intrinsically unattractive to mass/automated exploitation. A working proof-of-concept with demonstrated output is published in the GHSA advisory, which raises practical risk on multi-user and shared-container systems above what EPSS/KEV absence alone would suggest. Signals are therefore consistent (moderate severity, local vector, PoC present, no active-exploitation evidence) rather than conflicting. Two data caveats: EPSS and full SSVC inputs are missing, so probability/automatability cannot be independently weighed; and the input Tags label this 'Information Disclosure' which contradicts the CVSS vector (C:N, I:H/A:H) - this is a file-overwrite/destruction bug, not disclosure.

Exploit ScenarioDerived

On a multi-user host or shared container, an unprivileged local user pre-plants an in-root hardlink at a predictable package member path inside a shared or group-writable NLTK data root (e.g. /usr/share/nltk_data) that points to a victim-owned file outside the root. When the victim later runs nltk.download() to install that package, the ZIP extraction opens and truncates the pre-existing hardlink, overwriting the outside-root file with attacker-influenced bytes. A proof-of-concept in the GHSA-wr3g-j6qj-xpgh advisory demonstrates this end to end (succeeding even with fs.protected_hardlinks=1 when the target is attacker-owned); the local vector (AV:L) and low privilege (PR:L) mean no remote access is involved.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
1 PoC candidate (unverified) Patch available 0.2% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Nov 19, 2026

ZIP package extraction in NLTK 3.9.4 through 3.10.3 can truncate and overwrite files outside the NLTK data root when a local attacker has pre-planted an in-root hardlink at the exact archive member path a pending package will write. The victim must then run nltk.download() or 'python -m nltk.downloader' to extract a .zip package into a shared or predictable data root such as ~/nltk_data or a group-writable /usr/share/nltk_data; kernel hardlink protection (fs.protected_hardlinks) does not defeat the demonstrated case where the outside target is attacker-owned or group-shared. Impact is integrity and availability only (C:N/I:H/A:H) on a file of the attacker's choosing, not remote code execution, and the trigger is limited to local attackers with write access inside the extraction root. The upstream advisory publishes a proof-of-concept script that the reporter states reproduces the overwrite on the 3.10.3 PyPI wheel; no CISA KEV listing or EPSS score was supplied in the source data.

RemediationAI

Vendor-released patch: upgrade to NLTK 3.10.4, which is the version the advisory lists as fixed and corresponds to the v3.10.4 release tag and the changes in nltk/nltk#3753 (commits 0e9898b7615b4ab3b023e868212316a489ece4f0 and cf12a5e6a439fe1d722acd53d4309911faaaaf78), which add a multiply-linked-target refusal on the extraction path. Until the upgrade is deployed, the exposure can be reduced by not extracting packages into shared, group-writable or otherwise attacker-writable data roots, and by keeping fs.protected_hardlinks enabled - but note that hardlink protection alone does not close the demonstrated case, because the advisory's PoC succeeds with fs.protected_hardlinks=1 when the outside target is one the planting actor owns, is allowed to write, or group-shares, so restricting local write access to the data root is the load-bearing compensating control. Full details and the proof-of-concept are in the GitHub advisory at https://github.com/nltk/nltk/security/advisories/GHSA-wr3g-j6qj-xpgh; affected sites should also monitor the data roots used for nltk.download() for unexpected multiply-linked files.

Affected VersionsENISA

nltk 3.9.4, < 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

The flaw is a link-following failure (CWE-59, with CWE-73 path-traversal-adjacent context) inside NLTK's purpose-built containment wrapper nltk.pathsec.ZipFile, which is driven by nltk.downloader. On released versions, ZipFile.extract validates member names through validate_zip_archive and _validate_member and then delegates to the standard library zipfile._extract_member, whose plain open(targetpath, 'wb') opens and truncates any pre-existing file at that path. Those guards rely on name checks plus Path.resolve()/os.path.realpath(), which follow symlinks (so a symlinked member is correctly refused with a Security Violation) but cannot reveal a hardlink, because a hardlink is an ordinary regular file with a legitimate in-root name and an in-root resolved path. A prior remediation for the related downloader weakness added st_nlink > 1 refusals to nltk.pathsec.open/_hardened_open and routed the downloader temporary-file write through that hardened opener, but the extraction write sink never received the fstat, so the containment boundary fails open for hardlinks. The install path does not wipe the destination before extraction (cleanup runs only on a STALE status and unlinks names rather than truncating the victim inode), so a planted hardlink survives to the write. The fix commit adds a multiply-linked-target refusal in nltk/downloader.py _unzip_iter and hardens nltk/pathsec.py _extract_member so the hardened walk engages for name-based extract()/extractall() calls instead of silently falling back to the stdlib extractor; the same commit also bounds index and package download sizes (CWE-400) and sanitizes terminal output. Note that O_NOFOLLOW and O_EXCL on the development branch do not close this vector, since O_NOFOLLOW guards only a symlink final component and neither performs the st_nlink fstat.

Know when Python 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 (github) PRIMARY 7.1 HIGH
AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
vuln.today AI 7.1 HIGH

Local attacker with a low-privileged account and write access to a shared data root (AV:L/PR:L); extraction truncates/overwrites a chosen outside-root file (I:H/A:H) but discloses nothing (C:N).

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

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Nov 19, 2026 - 19:34 EUVD
CVE Published
Nov 19, 2026 - 18:18 cve.org
HIGH 7.1

DescriptionCVE.org

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.9.4 to 3.10.3, NLTK ZIP package extraction can write through an existing in-root hardlink whose other link points outside the NLTK data root. A local attacker who can prepare the extraction target can cause a package member write to overwrite an out-of-root file, violating the pathsec containment boundary and affecting integrity and availability. This issues is fixed in version 3.10.4.

Blast Radius

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

Ecosystem-wide dependent count for version 3.9.4.

Technical POC Analysis

CWE-59 (Improper Link Resolution Before File Access) - with CWE-73 also tagged - in nltk.pathsec, reached through nltk.downloader.

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

Latest POC

1 PoC candidate from github (unverified)

Sign in to open the public PoC links collected for this CVE.

Executive ViewAI

Why It Matters

A high-severity file overwrite vulnerability in NLTK (versions 3.9.4 through 3.10.3) could allow a local attacker to corrupt or destroy arbitrary files on systems where users have write access to the NLTK data directory. This affects development teams and shared build environments using NLTK's package download functionality, potentially disrupting workflows and compromising data integrity. Leadership should prioritize remediation due to the broad use of NLTK and the ease of local exploitation.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: restrict write access to the NLTK data root to trusted users only; avoid shared or world-writable data directories; use file integrity monitoring to detect unexpected changes; consider application-level allowlisting of package sources.

Threat Intelligence Overview

EPSS Score
0.2%
Top 87% exploitable
Prevalence
High
very widely used Python NLP library across ML, research and data-science environments
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High

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 Yes
EPSS 0.2%
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
Poc
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

56
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +36
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

More in Python

View all
CVE-2025-24016 CRITICAL POC
9.9 Feb 10

Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t

CVE-2025-27520 CRITICAL POC
9.8 Apr 04

BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser

CVE-2025-2945 CRITICAL POC
9.9 Apr 03

pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi

CVE-2013-5093 MEDIUM POC
6.8 Sep 27

The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python

CVE-2025-32375 CRITICAL POC
9.8 Apr 09

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2024-21644 HIGH POC
7.5 Jan 08

pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.

CVE-2026-33017 CRITICAL POC
9.3 Mar 17

Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301

CVE-2017-9462 HIGH POC
8.8 Jun 06

In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse

CVE-2026-49869 CRITICAL POC
10.0 Jun 26

Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2024-21645 MEDIUM POC
5.3 Jan 08

pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne

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