{"id":"CVE-2024-7387","published":"2024-09-16T23:58:35Z","modified":"2026-08-11T14:55:10Z","title":"Openshift/builder: path traversal allows command injection in privileged buildcontainer using docker build strategy","vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.12","tier":"tail","description":{"text":"A flaw was found in openshift/builder. This vulnerability allows command injection via path traversal, where a malicious user can execute arbitrary commands on the OpenShift node running the builder container. When using the “Docker” strategy, executable files inside the privileged build container can be overridden using the `spec.source.secrets.secret.destinationDir` attribute of the `BuildConfig` definition. An attacker running code in a privileged container could escalate their permissions on the node running the container.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.1,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.02321,"percentile":0.83872,"provenance":"source"},"cwes":[{"id":"CWE-250","name":"Execution with Unnecessary Privileges"}],"references":[{"url":"https://access.redhat.com/errata/RHSA-2024:3718","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6122","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6685","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6687","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6689","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6691","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/errata/RHSA-2024:6705","tags":["vendor-advisory","x_refsource_REDHAT"]},{"url":"https://access.redhat.com/security/cve/CVE-2024-7387","tags":["vdb-entry","x_refsource_REDHAT"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2302259","tags":["issue-tracking","x_refsource_REDHAT"]},{"url":"https://github.com/openshift/builder/commit/0b62633adfa2836465202bc851885e078ec888d1","tags":[]},{"url":"https://stuxxn.github.io/advisory/2024/10/02/openshift-build-docker-priv-esc.html","tags":[]}],"priority":{"score":23.1,"factors":[{"name":"EPSS percentile","points":16.77},{"name":"CVSS severity","points":6.37}]},"vendorSlug":"red-hat","affectedVersions":[{"vendor":null,"product":null,"versions":["< 0b62633adfa2836465202bc851885e078ec888d1"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.12","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.13","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.14","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.15","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.16","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.17","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.18","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.18","versions":["all versions"]},{"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4.18","versions":["all versions"]}],"workarounds":{"items":["Cluster admins can follow the instructions in \"Securing Builds by Strategy\" to block use of the \"Docker\" build strategy on a cluster, or restrict the use to a set of highly trusted users, until the cluster is able to be upgraded. https://docs.openshift.com/container-platform/4.16/cicd/builds/securing-builds-by-strategy.html"],"from":"CVE.org CNA","provenance":"source"},"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2024-10-07T20:31:09.766421Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/openshift/builder","vulnerableRanges":["<=4.0.0","all versions"],"patched":[],"from":["GHSA-qqv8-ph7f-h3f7","GO-2024-3129"],"provenance":"source"}],"euvd":{"id":"EUVD-2024-2857","exploited":false,"provenance":"source"}}