[GHSA-p4gq-832x-fm9v] Natural Language Toolkit (NLTK): URL-Encoded Path Traversal in nltk.data.load() Allows Arbitrary Local File Read - #8081
Conversation
|
Hi there @ekaf! A community member has suggested an improvement to your security advisory. If approved, this change will affect the global advisory listed at github.com/advisories. It will not affect the version listed in your project repository. This change will be reviewed by our Security Curation Team. If you have thoughts or feedback, please share them in a comment here! If this PR has already been closed, you can start a new community contribution for this advisory |
There was a problem hiding this comment.
Pull request overview
Updates the OSV/GitHub-reviewed advisory for GHSA-p4gq-832x-fm9v / CVE-2026-54293 (nltk) by adjusting affected-version metadata to better express the vulnerable range and (attempt to) record a fixed version.
Changes:
- Updates the advisory’s
modifiedtimestamp. - Replaces
last_affectedwith afixedversion event in the affected range. - Adds
affected[].database_specific.last_known_affected_version_rangeto preserve the previously-known vulnerable boundary.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Hi there @ekaf! A community member has suggested an improvement to your security advisory. If approved, this change will affect the global advisory listed at github.com/advisories. It will not affect the version listed in your project repository. This change will be reviewed by our Security Curation Team. If you have thoughts or feedback, please share them in a comment here! If this PR has already been closed, you can start a new community contribution for this advisory |
|
Hi @ekaf! Thank you so much for contributing to the GitHub Advisory Database. This database is free, open, and accessible to all, and it's people like you who make it great. Thanks for choosing to help others. We hope you send in more contributions in the future! |
Updates
Comments
This vulnerability (CVE‑2026‑54293) is a decode‑after‑check path traversal in nltk.data.load(), where percent‑encoded %2f, %2e, etc., bypass the unsafe‑path regex before url2pathname() decodes them into active filesystem paths. The primary fix is PR #3575, which URL‑decodes the resource name and re‑applies the safety checks to block encoded traversal and absolute‑path smuggling. This is reinforced by defense‑in‑depth measures: PRs #3467, #3479, and #3480 (merged in v3.9.3) block traversal in CorpusReader.open(), sandbox filesystem pointers, and protect protocol‑less references, while NLTK v3.10.0‑rc1 (released 2026‑06‑12) defaults pathsec.ENFORCE = True, making centralised path validation mandatory. Upgrade to v3.10.0‑rc1 or later to be fully protected.