REDHAT-BUG-2452271: Medium severity Moby BuildKit vulnerability
BuildKit is a toolkit for converting source code to build artifacts in an efficient, expressive and repeatable manner. Prior to version 0.28.1, insufficient validation of Git URL fragment subdir components may allow access to files outside the checked-out Git repository root. Possible access is limited to files on the same mounted filesystem. The issue has been fixed in version v0.28.1 The issue affects only builds that use Git URLs with a subpath component. As a workaround, avoid building Dockerfiles from untrusted sources or using the subdir component from an untrusted Git repository where the subdir component could point to a symlink.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in v0.28.1 - Compensating control
As a workaround, avoid building Dockerfiles from untrusted sources and avoid using the subdir component from an untrusted Git repository where the subdir component could point to a symlink.
Event History
Frequently Asked Questions
What is the severity of REDHAT-BUG-2452271?
The severity of REDHAT-BUG-2452271 is classified as medium.
How do I fix REDHAT-BUG-2452271?
To remediate REDHAT-BUG-2452271, upgrade to Moby BuildKit version 0.28.1 or later.
What does REDHAT-BUG-2452271 involve?
REDHAT-BUG-2452271 involves insufficient validation of Git URL fragment subdir components, allowing potential unauthorized file access.
What versions are affected by REDHAT-BUG-2452271?
Versions prior to 0.28.1 of Moby BuildKit are affected by REDHAT-BUG-2452271.
Can REDHAT-BUG-2452271 allow access to sensitive files?
Yes, REDHAT-BUG-2452271 may allow access to files outside the checked-out Git repository root.