{
    "data_version": "4.0",
    "data_type": "CVE",
    "data_format": "MITRE",
    "CVE_data_meta": {
        "ID": "CVE-2024-7387",
        "ASSIGNER": "secalert@redhat.com",
        "STATE": "PUBLIC"
    },
    "description": {
        "description_data": [
            {
                "lang": "eng",
                "value": "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 \u201cDocker\u201d 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."
            }
        ]
    },
    "problemtype": {
        "problemtype_data": [
            {
                "description": [
                    {
                        "lang": "eng",
                        "value": "Execution with Unnecessary Privileges",
                        "cweId": "CWE-250"
                    }
                ]
            }
        ]
    },
    "affects": {
        "vendor": {
            "vendor_data": [
                {
                    "vendor_name": "Red Hat",
                    "product": {
                        "product_data": [
                            {
                                "product_name": "Red Hat OpenShift Container Platform 4.12",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "not down converted",
                                            "x_cve_json_5_version_data": {
                                                "versions": [
                                                    {
                                                        "version": "v4.12.0-202409121032.p1.g609473f.assembly.stream.el8",
                                                        "lessThan": "*",
                                                        "versionType": "rpm",
                                                        "status": "unaffected"
                                                    }
                                                ],
                                                "defaultStatus": "affected"
                                            }
                                        }
                                    ]
                                }
                            },
                            {
                                "product_name": "Red Hat OpenShift Container Platform 4.13",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "not down converted",
                                            "x_cve_json_5_version_data": {
                                                "versions": [
                                                    {
                                                        "version": "v4.13.0-202409120505.p1.g2c7e99d.assembly.stream.el8",
                                                        "lessThan": "*",
                                                        "versionType": "rpm",
                                                        "status": "unaffected"
                                                    }
                                                ],
                                                "defaultStatus": "affected"
                                            }
                                        }
                                    ]
                                }
                            },
                            {
                                "product_name": "Red Hat OpenShift Container Platform 4.14",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "not down converted",
                                            "x_cve_json_5_version_data": {
                                                "versions": [
                                                    {
                                                        "version": "v4.14.0-202409111409.p1.g52565ca.assembly.stream.el8",
                                                        "lessThan": "*",
                                                        "versionType": "rpm",
                                                        "status": "unaffected"
                                                    }
                                                ],
                                                "defaultStatus": "affected"
                                            }
                                        }
                                    ]
                                }
                            },
                            {
                                "product_name": "Red Hat OpenShift Container Platform 4.15",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "not down converted",
                                            "x_cve_json_5_version_data": {
                                                "versions": [
                                                    {
                                                        "version": "v4.15.0-202409101936.p1.ge7749a3.assembly.stream.el8",
                                                        "lessThan": "*",
                                                        "versionType": "rpm",
                                                        "status": "unaffected"
                                                    }
                                                ],
                                                "defaultStatus": "affected"
                                            }
                                        }
                                    ]
                                }
                            },
                            {
                                "product_name": "Red Hat OpenShift Container Platform 4.16",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "not down converted",
                                            "x_cve_json_5_version_data": {
                                                "versions": [
                                                    {
                                                        "version": "v4.16.0-202409101737.p1.gfee4b58.assembly.stream.el9",
                                                        "lessThan": "*",
                                                        "versionType": "rpm",
                                                        "status": "unaffected"
                                                    }
                                                ],
                                                "defaultStatus": "affected"
                                            }
                                        }
                                    ]
                                }
                            }
                        ]
                    }
                }
            ]
        }
    },
    "references": {
        "reference_data": [
            {
                "url": "https://access.redhat.com/errata/RHSA-2024:6685",
                "refsource": "MISC",
                "name": "https://access.redhat.com/errata/RHSA-2024:6685"
            },
            {
                "url": "https://access.redhat.com/errata/RHSA-2024:6687",
                "refsource": "MISC",
                "name": "https://access.redhat.com/errata/RHSA-2024:6687"
            },
            {
                "url": "https://access.redhat.com/errata/RHSA-2024:6689",
                "refsource": "MISC",
                "name": "https://access.redhat.com/errata/RHSA-2024:6689"
            },
            {
                "url": "https://access.redhat.com/errata/RHSA-2024:6691",
                "refsource": "MISC",
                "name": "https://access.redhat.com/errata/RHSA-2024:6691"
            },
            {
                "url": "https://access.redhat.com/errata/RHSA-2024:6705",
                "refsource": "MISC",
                "name": "https://access.redhat.com/errata/RHSA-2024:6705"
            },
            {
                "url": "https://access.redhat.com/security/cve/CVE-2024-7387",
                "refsource": "MISC",
                "name": "https://access.redhat.com/security/cve/CVE-2024-7387"
            },
            {
                "url": "https://bugzilla.redhat.com/show_bug.cgi?id=2302259",
                "refsource": "MISC",
                "name": "https://bugzilla.redhat.com/show_bug.cgi?id=2302259"
            },
            {
                "url": "https://stuxxn.github.io/advisory/2024/10/02/openshift-build-docker-priv-esc.html",
                "refsource": "MISC",
                "name": "https://stuxxn.github.io/advisory/2024/10/02/openshift-build-docker-priv-esc.html"
            }
        ]
    },
    "work_around": [
        {
            "lang": "en",
            "value": "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.\n\nhttps://docs.openshift.com/container-platform/4.16/cicd/builds/securing-builds-by-strategy.html"
        }
    ],
    "credits": [
        {
            "lang": "en",
            "value": "Red Hat would like to thank Armin Stock for reporting this issue."
        }
    ],
    "impact": {
        "cvss": [
            {
                "attackComplexity": "LOW",
                "attackVector": "NETWORK",
                "availabilityImpact": "HIGH",
                "baseScore": 9.1,
                "baseSeverity": "CRITICAL",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "HIGH",
                "scope": "CHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H",
                "version": "3.1"
            }
        ]
    }
}