CVE-2026-79676

NLTK before 3.10.3 Path Traversal via Symlink Bypass

Published Aug 25, 2026 CVSS 4.0 · 8.2 High EPSS < 1% KEV · Not listed
Description
NLTK versions before 3.10.3 contain a path traversal vulnerability in corpus readers that reopen root-derived paths using built-in open() instead of nltk.pathsec.open(), allowing symlinks to escape trusted roots. Attackers who stage symlinked corpus files under a trusted data root can disclose outside-root content through normal corpus reader methods like channels(), domains(), and synonyms().

Analysis

AI-generated

Technical impact

NLTK versions before 3.10.3 contain an implementation error where corpus reader functions open files using the built‑in open() call rather than the safer nltk.pathsec.open(). Because of this, a malicious user can create a symbolic link that points outside the intended corpus directory. The reader then follows the link and reads arbitrary files located beyond the trusted root. This leads to the disclosure of sensitive data stored on the filesystem. The weakness is a classic path traversal flaw classified as CWE‑22.

Affected Systems

The vulnerability affects the Python library NLTK. Versions earlier than 3.10.3 are vulnerable; the fix is delivered in 3.10.3 and subsequent releases.

Risk and Exploitability

Due to the path‑traversal entry point, the CVSS score is 8.2, indicating a high impact if the attacker can place symlinked corpus files under a trusted root. The EPSS score is not available, and the vulnerability is not listed in the CISA KEV catalog. Exploitation requires the attacker to have a way to influence the data files that NLTK processes, which could arise from an application that loads user‑supplied corpora. If this condition is met, the attack can result in unauthorized disclosure of files that lie outside the intended corpus directory.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade NLTK to 3.10.3 or newer.
  • If upgrading is not immediately possible, ensure that corpus readers invoke nltk.pathsec.open() instead of the default open() to enforce path restrictions.
  • Validate and sanitize all input file paths before passing them to NLTK corpus readers, rejecting paths that resolve outside the designated data root.

Generated by OpenCVE AI on August 25, 2026 at 17:03 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-p4rw-rvv2-7xwr NLTK: Corpus readers follow symlinks outside trusted roots despite pathsec enforcement
History
Type Values Removed Values Added
Metrics ssvc

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

Type Values Removed Values Added
Description NLTK versions before 3.10.3 contain a path traversal vulnerability in corpus readers that reopen root-derived paths using built-in open() instead of nltk.pathsec.open(), allowing symlinks to escape trusted roots. Attackers who stage symlinked corpus files under a trusted data root can disclose outside-root content through normal corpus reader methods like channels(), domains(), and synonyms().
Title NLTK before 3.10.3 Path Traversal via Symlink Bypass
First Time appeared Nltk
Nltk nltk
Weaknesses CWE-22
CPEs cpe:2.3:a:nltk:nltk:*:*:*:*:*:*:*:*
Vendors & Products Nltk
Nltk nltk
References
Metrics cvssV3_1

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

cvssV4_0

{'score': 8.2, 'vector': 'CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Sources

Status
PUBLISHED
Assigner
VulnCheck
Published
Updated
Aug 25, 2026, 4:15 PM
Reserved
Aug 25, 2026, 11:10 AM
Status
Analyzed
Published
Aug 25, 2026, 4:17 PM
Modified
Aug 31, 2026, 7:06 PM
Severity
Moderate
Public date
Aug 25, 2026, 3:16 PM