NLTK versions before 3.10.0 contain a logic bug in FileSystemPathPointer.open() where the sandbox validation check compares a normalized path against itself, making the security check permanently inert. Attackers can pass file:// URLs to nltk.data.load() to read arbitrary files accessible to the process user, including credentials and configuration files.
Fix
Patch, vendor advisory and mitigation references on NVD 2
- https://github.com/nltk/nltk/security/advisories/GHSA-72r2-7mfr-5xr9 Exploit, Vendor Advisory
- https://github.com/nltk/nltk/security/advisories/GHSA-72r2-7mfr-5xr9 Exploit, Vendor Advisory
Every line above is quoted from NVD, CISA, Microsoft, the vendor's own advisory or DISA; nothing is generated.
Change history 1
- First seenCVSS 7.1 · nltkNVD modified 2026-10-14 13:10
Affected (CPE criteria) 1
cpe:2.3:a:nltk:nltk:*:*:*:*:*:*:*:*
References 3
- https://github.com/nltk/nltk/security/advisories/GHSA-72r2-7mfr-5xr9 Exploit, Vendor Advisory
- https://www.vulncheck.com/advisories/nltk-before-arbitrary-file-read-via-filesystempathpointer Third Party Advisory
- https://github.com/nltk/nltk/security/advisories/GHSA-72r2-7mfr-5xr9 Exploit, Vendor Advisory