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
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • 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-23652

CVE-2024-23652: Mobyproject BuildKit Path Traversal Flaw

CVE-2024-23652 is a path traversal vulnerability in Mobyproject BuildKit that allows attackers to delete host files via malicious RUN --mount commands. This article covers technical details, affected versions, and mitigations.

Published: January 28, 2026

CVE-2024-23652 Overview

CVE-2024-23652 is a critical path traversal vulnerability in BuildKit, the modern toolkit for converting source code to build artifacts used by Docker and other container build systems. A malicious BuildKit frontend or Dockerfile using the RUN --mount directive can exploit the empty file cleanup mechanism to delete arbitrary files on the host system outside of the container boundary.

Critical Impact

This vulnerability enables container escape scenarios where an attacker can delete arbitrary files on the host system by exploiting the mountpoint cleanup feature, potentially leading to denial of service or system compromise.

Affected Products

  • Mobyproject BuildKit versions prior to v0.12.5

Discovery Timeline

  • 2024-01-31 - CVE-2024-23652 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2024-23652

Vulnerability Analysis

This vulnerability falls under CWE-22 (Path Traversal), which allows attackers to access or manipulate files outside of intended directory boundaries. The flaw exists in BuildKit's handling of the RUN --mount feature, specifically in the cleanup mechanism responsible for removing empty files created as mountpoints during the build process.

When BuildKit processes a RUN --mount instruction in a Dockerfile, it creates temporary mountpoints within the container filesystem. After the build step completes, BuildKit performs cleanup operations to remove these empty placeholder files. However, insufficient path validation in this cleanup routine allows a maliciously crafted frontend or Dockerfile to specify paths that escape the container boundary.

An attacker who can supply a malicious Dockerfile or BuildKit frontend can craft RUN --mount directives with specially constructed paths containing traversal sequences. When the cleanup routine processes these paths, it follows the traversal and deletes files on the host system instead of within the container context.

Root Cause

The root cause is insufficient path validation in BuildKit's mountpoint cleanup mechanism. The cleanup routine fails to properly canonicalize and validate file paths before performing deletion operations, allowing path traversal sequences to escape the intended container filesystem scope.

Attack Vector

This vulnerability is exploitable over the network without requiring authentication or user interaction. The attack vector requires the victim to build a malicious Dockerfile or use an untrusted BuildKit frontend. Organizations that accept and build untrusted Dockerfiles, such as CI/CD systems processing external contributions, are particularly at risk.

The attack scenario involves:

  1. An attacker crafts a malicious Dockerfile containing RUN --mount directives with path traversal sequences
  2. A victim system builds the malicious Dockerfile using vulnerable BuildKit
  3. During the cleanup phase, BuildKit follows the traversal path and deletes files on the host system
  4. Depending on the targeted files, this can lead to denial of service, privilege escalation, or further system compromise

Detection Methods for CVE-2024-23652

Indicators of Compromise

  • Unexpected file deletions on systems running BuildKit build operations
  • Dockerfiles or BuildKit frontends containing suspicious RUN --mount directives with traversal patterns (e.g., ../ sequences)
  • Anomalous file system activity during container build processes
  • Build logs showing unusual mount paths or cleanup operations

Detection Strategies

  • Monitor BuildKit build logs for RUN --mount directives containing path traversal sequences such as ../ or absolute paths outside container scope
  • Implement file integrity monitoring on critical host system files that could be targeted for deletion
  • Audit incoming Dockerfiles for suspicious mount configurations before building
  • Deploy container security tools that can analyze Dockerfile contents for potentially malicious instructions

Monitoring Recommendations

  • Enable detailed BuildKit logging and forward logs to SIEM for analysis
  • Configure alerts for file deletion events on host systems during active build operations
  • Implement baseline monitoring for critical system files and directories
  • Monitor for BuildKit frontend downloads from untrusted sources

How to Mitigate CVE-2024-23652

Immediate Actions Required

  • Upgrade BuildKit to version v0.12.5 or later immediately
  • Audit all Dockerfiles in your environment for suspicious RUN --mount usage
  • Restrict access to build systems to prevent execution of untrusted Dockerfiles
  • Implement Dockerfile scanning in CI/CD pipelines to detect potentially malicious instructions

Patch Information

The BuildKit team has released version v0.12.5 which addresses this vulnerability. The fix includes proper path validation in the mountpoint cleanup mechanism to prevent traversal outside container boundaries.

Upgrade to the patched version using the appropriate method for your environment:

  • GitHub Release v0.12.5 - Official release with security fix
  • GitHub Pull Request Discussion - Technical details of the fix
  • GitHub Security Advisory GHSA-4v98-7qmw-rqr8 - Full security advisory

Workarounds

  • Avoid using BuildKit frontends from untrusted sources
  • Do not build Dockerfiles containing RUN --mount features from untrusted sources
  • Implement strict access controls on build systems to prevent execution of arbitrary Dockerfiles
  • Consider running BuildKit in isolated environments with limited host filesystem access until patching is complete
bash
# Verify BuildKit version to ensure patched version is installed
buildctl --version
# Expected output should show v0.12.5 or later

# For Docker users, verify buildx version which includes BuildKit
docker buildx version

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

  • Vulnerability Details
  • TypePath Traversal

  • Vendor/TechMobyproject

  • SeverityCRITICAL

  • CVSS Score9.1

  • EPSS Probability4.86%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-22
  • Vendor Resources
  • GitHub Pull Request Discussion

  • GitHub Release v0.12.5

  • GitHub Security Advisory GHSA-4v98-7qmw-rqr8
  • Related CVEs
  • CVE-2026-33747: Mobyproject Buildkit Path Traversal Flaw

  • CVE-2024-23651: Moby BuildKit Race Condition 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