Docker BuildKit Git URL Subdirectory Validation Vulnerability Allowing File Access Outside Repository

Vulnerability

A vulnerability in Docker BuildKit prior to version 0.28.1 allows insufficiently validated Git URL subdirectory components to access files outside the checked-out repository root. This issue is limited to files on the same mounted filesystem and only affects builds using Git URLs with a subpath component.

Impact

Exploitation of this vulnerability could lead to unauthorized access to files outside the intended Git repository context, potentially exposing sensitive information or files.

Remediation

Users can upgrade to Docker BuildKit version 0.28.1 or later to address this vulnerability. When using Git URLs with subdirectory components, ensure that the repository is trusted and that the subdirectory does not point to a symlink.

Added: Mar 27, 2026, 3:45 PM
Updated: Mar 27, 2026, 3:45 PM

Vulnerability Rating

Custom Algorithm
spread
6.6
impact
0.2
exploitability
3.8
remediation
7.9
relevance
4.8
threat
0.0
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.