CVE-2024-7631
Description
A flaw was found in the OpenShift Console, an endpoint for plugins to serve resources in multiple languages: /locales/resources.json. This endpoint's lng and ns parameters are used to construct a filepath in pkg/plugins/handlers unsafely.go#L112 Because of this unsafe filepath construction, an authenticated user can manipulate the path to retrieve any JSON files on the console's pod by using sequences of ../ and valid directory paths.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
A path traversal vulnerability in OpenShift Console's /locales/resources.json endpoint lets an authenticated user read arbitrary JSON files from the pod.
Vulnerability
The /locales/resources.json endpoint in the OpenShift Console (bridge) uses the lng and ns query parameters to build a file path when loading locale resource files. This filepath construction occurs in pkg/plugins/handlers/unsafely.go at line 112 and does not properly sanitize or validate sequences such as ../ [1][3]. Consequently, an attacker can inject path traversal payloads into these parameters to escape the intended locale directory.
Exploitation
An attacker must first authenticate to the OpenShift Console, as the endpoint requires a valid session. The only prerequisite is the ability to issue HTTP requests to the console—no special privileges are needed beyond authentication. By crafting requests with parameters like lng=../../etc/kubernetes&ns=somefile, an authenticated user can force the server to read any accessible JSON file on the pod’s filesystem [1][4]. The endpoint returns the JSON content directly in the response.
Impact
Successful exploitation allows the attacker to read arbitrary JSON files from the console’s container filesystem. This could expose sensitive configuration data, service account tokens, or other secrets stored as JSON files on the pod. The vulnerability is rated Medium (CVSS 4.3) because it requires authentication and only affects JSON files, limiting impact compared to arbitrary file reads of other formats or from other pods [1][3].
Mitigation
Red Hat has released patched versions of the OpenShift Console (version 6.0.7 and later) that properly validate and sanitize the lng and ns parameters [2][4]. Users should update to the latest console version available for their OpenShift release. No workaround is provided other than restricting network access to the console’s pod via network policies.
AI Insight generated on May 20, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
github.com/openshift/consoleGo | <= 6.0.6 | — |
Affected products
1Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
5News mentions
0No linked articles in our index yet.