CVE-2024-23651: moby buildkit · Race Condition
Affects moby buildkitSource CVE Database V5
Not known to be exploited · CVSS 8.7 High : upgrade to 0.12.5 soon.
Data as of 25 Oct 2026, 19:02 UTC
- EPSS
- 0.9% chance of exploitation in 30 days – higher than 59% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 0.12.5
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:NExploitation evidence
Disclosed: evidence found.
CVE published 31 Jan 2024
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 2026-10-25.
What to do
Upgrade moby/buildkit to 0.12.5.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
GitHubmoby/buildkitpkg:github/moby/buildkitOther threats | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
1. Upgrade BuildKit to version 0.12.5 or later immediately to apply the official fix. 2. Implement strict controls on build inputs: only use trusted BuildKit frontends and avoid building Dockerfiles from untrusted or external sources, especially those that use cache mounts with --mount=type=cache,source=... options. 3. Enforce isolation policies in CI/CD pipelines to prevent concurrent builds from sharing cache mounts or other resources that could lead to race conditions. 4. Audit and monitor build logs and file system accesses during builds to detect anomalous behavior indicative of exploitation attempts. 5. Use container security tools to scan build environments for misconfigurations and enforce least privilege principles on build agents. 6. Educate developers and DevOps teams about the risks of race conditions in build processes and the importance of secure build configurations. 7. Consider implementing ephemeral build environments that are destroyed after each build to limit the persistence of any unauthorized access.
Description
BuildKit is a toolkit for converting source code to build artifacts in an efficient, expressive and repeatable manner. Two malicious build steps running in parallel sharing the same cache mounts with subpaths could cause a race condition that can lead to files from the host system being accessible to the build container. The issue has been fixed in v0.12.5. Workarounds include, avoiding using BuildKit frontend from an untrusted source or building an untrusted Dockerfile containing cache mounts with --mount=type=cache,source=... options.