The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2024-34062

CVE-2024-34062: Python tqdm Library RCE Vulnerability

CVE-2024-34062 is a remote code execution vulnerability in the Python tqdm progress bar library caused by unsafe eval usage in CLI arguments. This post covers the technical details, affected versions, and mitigation steps.

Updated: January 22, 2026

CVE-2024-34062 Overview

CVE-2024-34062 is a code injection vulnerability affecting tqdm, the popular open source progress bar library for Python and CLI applications. The vulnerability exists because any optional non-boolean CLI arguments (such as --delim, --buf-size, --manpath) are passed through Python's eval() function, allowing arbitrary code execution on the local system.

Critical Impact

Local attackers with access to the system can execute arbitrary Python code by crafting malicious CLI arguments, potentially leading to data theft, system compromise, or lateral movement within a network.

Affected Products

  • tqdm versions prior to 4.66.3
  • Python applications and scripts utilizing vulnerable tqdm CLI functionality
  • Systems where tqdm CLI commands are exposed to user-controlled input

Discovery Timeline

  • 2024-05-03 - CVE CVE-2024-34062 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2024-34062

Vulnerability Analysis

This vulnerability stems from unsafe use of Python's eval() function to process CLI argument values. When users provide non-boolean arguments to tqdm's command-line interface, the application constructs strings dynamically and passes them to eval() for type conversion. This design pattern creates a classic code injection vulnerability where an attacker can craft malicious input that executes arbitrary Python code.

The vulnerability is locally exploitable, meaning an attacker needs local access to the system or the ability to influence CLI arguments passed to tqdm. While this limits the attack surface compared to remote exploits, it remains dangerous in scenarios involving automated scripts, CI/CD pipelines, or multi-user systems where tqdm commands might process untrusted input.

Root Cause

The root cause is the use of Python's eval() function for type casting CLI argument values. The original implementation used eval(typ + '("' + val + '")') to convert string inputs to their intended types. This approach is inherently unsafe as eval() executes arbitrary Python expressions, and user-controlled input was being directly interpolated into the expression string without proper sanitization or validation.

CWE-74 (Improper Neutralization of Special Elements in Output Used by a Downstream Component) accurately classifies this vulnerability, as user input was not properly neutralized before being processed by the Python interpreter.

Attack Vector

The attack requires local access to execute tqdm CLI commands with crafted arguments. An attacker could exploit this by providing specially crafted values to vulnerable CLI options. For example, malicious payloads could be injected through options like --delim, --buf-size, or --manpath that would be evaluated as Python code rather than simple string or numeric values.

Attack scenarios include:

  • Local privilege escalation on multi-user systems
  • Exploitation via scripts that pass user-controlled data to tqdm CLI
  • Compromise of CI/CD pipelines using tqdm with external inputs
  • Supply chain attacks targeting build systems

The following patch shows how the vulnerability was remediated by removing the unsafe eval() call:

python
                 return cast(val, t)
             except TqdmTypeError:
                 pass
-        raise TqdmTypeError(val + ' : ' + typ)
+        raise TqdmTypeError(f"{val} : {typ}")

     # sys.stderr.write('\ndebug | `val:type`: `' + val + ':' + typ + '`.\n')
     if typ == 'bool':
         if (val == 'True') or (val == ''):
             return True
-        elif val == 'False':
+        if val == 'False':
             return False
-        else:
-            raise TqdmTypeError(val + ' : ' + typ)
-    try:
-        return eval(typ + '("' + val + '")')
-    except Exception:
-        if typ == 'chr':
-            return chr(ord(eval('"' + val + '"'))).encode()
-        else:
-            raise TqdmTypeError(val + ' : ' + typ)
+        raise TqdmTypeError(val + ' : ' + typ)
+    if typ == 'chr':
+        if len(val) == 1:
+            return val.encode()
+        if re.match(r"^\\\\\\w+$", val):
+            return eval(f'"{val}"').encode()
+        raise TqdmTypeError(f"{val} : {typ}")
+    if typ == 'str':

Source: GitHub Commit - Security Fix

Detection Methods for CVE-2024-34062

Indicators of Compromise

  • Unusual process spawning from Python scripts using tqdm
  • Suspicious command-line arguments containing Python expressions or special characters in tqdm commands
  • Unexpected network connections or file system activity originating from tqdm-related processes
  • Audit logs showing tqdm CLI invocations with encoded or obfuscated argument values

Detection Strategies

  • Monitor for tqdm CLI executions with arguments containing Python syntax elements such as __import__, exec, eval, or os.system
  • Implement application-level logging for tqdm CLI argument values in production environments
  • Use static analysis tools to identify scripts passing user-controlled input to tqdm CLI
  • Deploy runtime application self-protection (RASP) to detect and block code injection attempts

Monitoring Recommendations

  • Enable command-line auditing on systems where tqdm is used in automated workflows
  • Configure SIEM rules to alert on suspicious Python process behaviors following tqdm execution
  • Review CI/CD pipeline configurations for instances where external input may reach tqdm CLI commands
  • Perform regular dependency audits to ensure tqdm version 4.66.3 or later is deployed across all environments

How to Mitigate CVE-2024-34062

Immediate Actions Required

  • Upgrade tqdm to version 4.66.3 or later immediately across all environments
  • Audit scripts and applications to identify any usage of tqdm CLI with user-controlled input
  • Review CI/CD pipelines and automated workflows for vulnerable tqdm versions
  • Implement input validation for any system that passes external data to tqdm commands

Patch Information

The vulnerability has been addressed in tqdm release version 4.66.3. The fix replaces the unsafe eval() call with explicit type handling and proper input validation. Users should upgrade using pip:

bash
pip install --upgrade tqdm>=4.66.3

For additional details, refer to the GitHub Security Advisory GHSA-g7vv-2v7x-gj9p and the security patch commit.

Fedora users should check for updated packages via their distribution's package manager. Multiple Fedora Package Announcements have been issued regarding this vulnerability.

Workarounds

  • Avoid using tqdm CLI features with user-controlled or untrusted input until patched
  • Implement strict input validation and sanitization before passing any external data to tqdm commands
  • Consider containerizing applications using tqdm CLI to limit the impact of potential exploitation
  • Use Python API calls to tqdm instead of CLI invocations where possible, as the vulnerability is specific to CLI argument parsing
bash
# Verify tqdm version and upgrade if necessary
pip show tqdm | grep Version
pip install --upgrade "tqdm>=4.66.3"

# For system-wide installations
sudo pip install --upgrade "tqdm>=4.66.3"

# For virtual environments, ensure upgrade within the environment
source /path/to/venv/bin/activate
pip install --upgrade "tqdm>=4.66.3"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeRCE

  • Vendor/TechTqdm

  • SeverityMEDIUM

  • CVSS Score4.8

  • EPSS Probability0.08%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:L
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityLow
  • AvailabilityLow
  • CWE References
  • CWE-74
  • Technical References
  • GitHub Commit Update

  • GitHub Security Advisory

  • Fedora Package Announcement

  • Fedora Package Announcement

  • Fedora Package Announcement
  • Latest CVEs
  • CVE-2025-70797: LimeSurvey XSS Vulnerability

  • CVE-2025-30650: Juniper Junos OS Auth Bypass Vulnerability

  • CVE-2026-35471: Goshs Path Traversal Vulnerability

  • CVE-2026-35393: Goshs Path Traversal Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English