Bug 2528395 - CVE-2025-71408 python-nltk: NLTK: Arbitrary Code Execution via Eval Injection in Collocations Module [fedora-all]
Summary: CVE-2025-71408 python-nltk: NLTK: Arbitrary Code Execution via Eval Injection...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: python-nltk
Version: rawhide
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
Assignee: José Matos
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: {"flaws": ["edbfe6ef-c5fc-49ac-bdd0-9...
Depends On:
Blocks: CVE-2025-71408
TreeView+ depends on / blocked
 
Reported: 2026-09-04 04:29 UTC by Ganesh
Modified: 2026-09-04 04:29 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Ganesh 2026-09-04 04:29:08 UTC
Disclaimer: Community trackers are created by Red Hat Product Security team on a best effort basis. Package maintainers are required to ascertain if the flaw indeed affects their package, before starting the update process.

NLTK (Natural Language Toolkit) before version 3.9.3 contains an eval injection vulnerability in the nltk.collocations module that allows an attacker who controls command-line arguments to execute arbitrary Python code. When collocations.py is invoked directly, the __main__ block passes command-line arguments directly to eval() as suffixes of BigramAssocMeasures without allowlist validation or sanitization, enabling an attacker to supply a Python expression that escapes the intended attribute lookup and executes arbitrary code including OS commands via the os module.


Note You need to log in before you can comment on or make changes to this bug.