Wiz Agents & Workflows are here

CVE-2024-39705
Python vulnerability analysis and mitigation

Overview

NLTK (Natural Language Toolkit) through version 3.8.1 contains a critical remote code execution vulnerability when using the integrated data package download functionality. The vulnerability affects situations where untrusted packages contain pickled Python code, specifically impacting packages such as 'averaged_perceptron_tagger' and 'punkt'. This security issue was initially discovered and reported on May 19, 2024, and was subsequently assigned CVE-2024-39705 (GitHub Issue).

Technical details

The vulnerability stems from NLTK's use of Python's pickle module for deserializing data packages. When downloading and using certain NLTK data packages that contain pickled Python code, the application automatically deserializes this content without proper validation. This process can lead to arbitrary code execution if the package source is compromised. The vulnerability has received a CVSS v3.1 base score of 9.8 (CRITICAL), with a vector string of CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H, indicating its severe nature (NVD).

Impact

The vulnerability allows a man-in-the-middle attacker or an attacker with control over the NLTK data index to force users to download malicious versions of data packages. When these packages are unpickled during normal NLTK operations, they can execute arbitrary code on the target system. This affects any code that downloads and uses vulnerable data packages such as 'averaged_perceptron_tagger' and 'punkt' (GitHub Issue).

Mitigation and workarounds

Users should upgrade to versions newer than 3.8.1 when available. Until then, users should exercise caution when downloading NLTK data packages, especially in environments where the download source could be compromised. Organizations should consider implementing network security controls to ensure the integrity of downloaded NLTK packages (NVD).

Additional resources


SourceThis report was generated using AI

Related Python vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-33641HIGH7.8
  • PythonPython
  • glances
NoNoApr 02, 2026
CVE-2026-34591HIGH7.1
  • PythonPython
  • poetry
NoYesApr 02, 2026
CVE-2026-33533HIGH7.1
  • PythonPython
  • glances
NoNoApr 02, 2026
CVE-2026-34730MEDIUM5.5
  • PythonPython
  • copier
NoYesApr 02, 2026
CVE-2026-34726MEDIUM4.4
  • PythonPython
  • copier
NoYesApr 02, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management