Description
NLTK (Natural Language Toolkit) is a suite of open source Python modules, data sets, and tutorials supporting research and development in Natural Language Processing. In versions 3.9.3 and prior, the NLTK downloader does not validate the `subdir` and `id` attributes when processing remote XML index files. Attackers can control a remote XML index server to provide malicious values containing path traversal sequences (such as `../`), which can lead to arbitrary directory creation, arbitrary file creation, and arbitrary file overwrite. Commit 89fe2ec2c6bae6e2e7a46dad65cc34231976ed8a patches the issue.
Published: 2026-03-20
Score: 8.1 High
EPSS: < 1% Very Low
KEV: No
Impact: Arbitrary File Overwrite via Path Traversal
Action: Immediate Patch
AI Analysis

Impact

The NLTK downloader fails to validate the subdir and id fields in remote XML index files, allowing an attacker to supply path traversal sequences such as ../. When a user downloads corpus data, these sequences can create arbitrary directories, create arbitrary files, or overwrite existing files. The result can be malicious code execution or data corruption, reflecting a classic improper restriction of operations within a file system flaw (CWE‑22).

Affected Systems

Any installation of NLTK version 3.9.3 or earlier that uses the downloader feature to fetch corpora from remote XML indices is affected. The issue exists across all platforms where Python applications invoke the NLTK downloader to obtain data sets.

Risk and Exploitability

The vulnerability carries a CVSS score of 8.1, indicating high severity, but the EPSS score is below 1%, suggesting a low likelihood of exploitation in the wild. It is not listed in the CISA KEV catalog. Based on the description, it is inferred that the attack vector is remote: an adversary must host a malicious XML index server and a victim must trigger the NLTK downloader to retrieve data from that server, which enables the path traversal and file overwrite capability.

Generated by OpenCVE AI on March 23, 2026 at 20:52 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade NLTK to a version newer than 3.9.3 that includes commit 89fe2ec2c6bae6e2e7a46dad65cc34231976ed8a.
  • If an upgrade is not immediately possible, limit the downloader to trusted source URLs or disable the downloader feature entirely to prevent processing of external XML indices.
  • After applying a patch, verify that the filesystem has not been altered by checking for unauthorized files or changes in directories.

Generated by OpenCVE AI on March 23, 2026 at 20:52 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-469j-vmhf-r6v7 NLTK has a Downloader Path Traversal Vulnerability (AFO) - Arbitrary File Overwrite
History

Mon, 23 Mar 2026 19:30:00 +0000

Type Values Removed Values Added
CPEs cpe:2.3:a:nltk:nltk:*:*:*:*:*:*:*:*

Mon, 23 Mar 2026 17:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Mon, 23 Mar 2026 12:15:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

threat_severity

Important


Mon, 23 Mar 2026 10:00:00 +0000

Type Values Removed Values Added
First Time appeared Nltk
Nltk nltk
Vendors & Products Nltk
Nltk nltk

Fri, 20 Mar 2026 23:00:00 +0000

Type Values Removed Values Added
Description NLTK (Natural Language Toolkit) is a suite of open source Python modules, data sets, and tutorials supporting research and development in Natural Language Processing. In versions 3.9.3 and prior, the NLTK downloader does not validate the `subdir` and `id` attributes when processing remote XML index files. Attackers can control a remote XML index server to provide malicious values containing path traversal sequences (such as `../`), which can lead to arbitrary directory creation, arbitrary file creation, and arbitrary file overwrite. Commit 89fe2ec2c6bae6e2e7a46dad65cc34231976ed8a patches the issue.
Title NLTK has a Downloader Path Traversal Vulnerability (AFO) - Arbitrary File Overwrite
Weaknesses CWE-22
References
Metrics cvssV3_1

{'score': 8.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:H'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-03-23T16:46:42.554Z

Reserved: 2026-03-18T02:42:27.508Z

Link: CVE-2026-33236

cve-icon Vulnrichment

Updated: 2026-03-23T16:46:38.279Z

cve-icon NVD

Status : Analyzed

Published: 2026-03-20T23:16:47.007

Modified: 2026-03-23T19:15:37.720

Link: CVE-2026-33236

cve-icon Redhat

Severity : Important

Publid Date: 2026-03-20T22:47:10Z

Links: CVE-2026-33236 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-03-25T14:34:06Z

Weaknesses