Skip to content
OpenAdvisories
Medium · 4.8 CVE-2019-11251 EUVD-2021-0974GHSA-6qfg-8799-r575GO-2022-0802

kubectl cp allows symlink directory traversal

Published Feb 3, 2020 · Updated Aug 4, 2024 · Assigned by kubernetes

Description

The Kubernetes kubectl cp command in versions 1.1-1.12, and versions prior to 1.13.11, 1.14.7, and 1.15.4 allows a combination of two symlinks provided by tar output of a malicious container to place a file outside of the destination directory specified in the kubectl cp invocation. This could be used to allow an attacker to place a nefarious file using a symlink, outside of the destination tree.

Affected products

VendorProductAffectedFixed
Kubernetes Kubernetes prior to 1.13.11, prior to 1.14.7, prior to 1.15.4, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 1.10, 1.11, 1.12 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Red Hat OpenShift 4 openshift +3 4.1.21-201910220952.git.0.493dbf6.el7 RHSA-2019:3266
Red Hat OpenShift 3 atomic-openshift +13 3.9.102-1.git.0.6411f52.el7 RHSA-2019:3905, RHSA-2019:3811
Red Hat OpenShift 3 atomic-openshift-hyperkube +1 3.11.154-1.git.0.7a097ad.el7 RHSA-2019:3905
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed govulncheck-vulndb 0.0.20250807T150727-1.1 openSUSE-SU-2025:15424-1

Oracle Linux

ReleasePackageFixed inAdvisory
Oracle Linux 7 kubeadm +2 1.12.10-1.0.10.el7 ELSA-2019-4816
Oracle Linux 7 kubeadm-ha-setup 0.0.2-1.0.68.el7 ELSA-2019-4816
Oracle Linux 7 kubeadm-upgrade 0.0.1-1.0.27.el7 ELSA-2019-4816

Affected packages

EcosystemPackageAffectedFixedRecord
Go k8s.io/kubernetes >= 1.13.10, < 1.13.11 1.13.11 GHSA-6qfg-8799-r575
Go k8s.io/kubernetes >= 1.14.6, < 1.14.7 1.14.7 GHSA-6qfg-8799-r575
Go k8s.io/kubernetes >= 1.15.3, < 1.16.0 1.16.0 GHSA-6qfg-8799-r575
Go k8s.io/kubernetes >= 1.13.10, < 1.13.11 · >= 1.14.6, < 1.14.7 · >= 1.15.3, < 1.16.0 1.13.11, 1.14.7, 1.16.0 GO-2022-0802

Advisories 6

References