kaniko has tar archive path traversal in build context extraction allows writing files outside destination directory

Summary

CVECVE-2026-28406
StatePUBLISHED
AssignerGitHub_M
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-02-27 22:16:23 UTC
Updated2026-06-30 03:18:01 UTC
Descriptionkaniko is a tool to build container images from a Dockerfile, inside a container or Kubernetes cluster. Starting in version 1.25.4 and prior to version 1.25.10, kaniko unpacks build context archives using `filepath.Join(dest, cleanedName)` without enforcing that the final path stays within `dest`. A tar entry like `../outside.txt` escapes the extraction root and writes files outside the destination directory. In environments with registry authentication, this can be chained with docker credential helpers to achieve code execution within the executor process. Version 1.25.10 uses securejoin for path resolution in tar extraction.

Risk And Classification

Primary CVSS: v3.1 8.5 HIGH from ADP

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L

EPSS: 0.006130000 probability, percentile 0.449630000 (date 2026-07-02)

Problem Types: CWE-22 | CWE-22 CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') | CWE-22 Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')


VersionSourceTypeScoreSeverityVector
3.1ADPCVSS8.5HIGHCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L
3.1[email protected]Secondary8.2HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L
3.10b0ca135-0b70-47e7-9f44-1890c2a1c46cSecondary8.5HIGHCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L
3.1CNADECLARED8.2HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:L

CVSS v3.1 Breakdown

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Changed
Confidentiality
None
Integrity
High
Availability
Low

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:L

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Application Chainguard Kaniko All All All All

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA Chainguard-forks Kaniko affected >= 1.25.4, < 1.25.10 Not specified
ADP Red Hat OpenShift Serverless Not specified Not specified

References

ReferenceSourceLinkTags
security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-28406.json 0b0ca135-0b70-47e7-9f44-1890c2a1c46c security.access.redhat.com
bugzilla.redhat.com/show_bug.cgi 0b0ca135-0b70-47e7-9f44-1890c2a1c46c bugzilla.redhat.com
github.com/chainguard-forks/kaniko/commit/a370e4b1f66e6e842b685c8f70ed50... [email protected] github.com Patch
github.com/chainguard-forks/kaniko/security/advisories/GHSA-6rxq-q92g-4rmf [email protected] github.com Patch, Vendor Advisory
access.redhat.com/security/cve/CVE-2026-28406 0b0ca135-0b70-47e7-9f44-1890c2a1c46c access.redhat.com
github.com/chainguard-forks/kaniko/pull/326 [email protected] github.com Issue Tracking, Patch
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Additional Advisory Data

SourceTimeEvent
ADP2026-02-27T22:02:23.464ZReported to Red Hat.
ADP2026-02-27T21:20:52.764ZMade public.
© CVE.report 2026 |

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report