Off-by-one error in GNOME GLib key file string list parser

Note: This data is for reference and cybersecurity research purposes only.CyStack advises users not to use this information for unlawful purposes.

What is CVE-2026-58014?

CVE-2026-58014 is a vulnerability classified as Off-by-one Error, affecting GLib (affected versions: < 2.88.1), Red Hat Enterprise Linux 10, Red Hat Enterprise Linux 10.0 Extended Update Support, and 35 more products. This vulnerability is rated High, with a CVSS score of 8.6. Public exploit code or evidence is available for this vulnerability, but that does not confirm exploitation in the wild.

Overview

Original source data

A flaw was found in GLib. An off-by-one error can occur in the g_key_file_get_locale_string_list function in the gkeyfile.c file when loading a key file with an empty value. This flaw can cause an out-of-bounds access of 1 byte or a denial of service when the out-of-bounds access crosses a page boundary.

Affected products and scope

GLib versions prior to the fixed release are affected. Red Hat has confirmed impact on its glib2 and mingw-glib2 packages across Red Hat Enterprise Linux 7 Extended Lifecycle Support, RHEL 8 (including baseos, crb, and multiple support channels), RHEL 9 (including appstream, baseos, crb, and SAP Solutions channels), RHEL 10, RHEL 10 EUS, and Red Hat OpenShift Container Platform 4.12 through 4.22. Cert Manager packages for OpenShift 1.17 on RHEL 9 are also listed as affected. Configurations that do not use the locale string list parsing path in GLib are not reachable.

Technical details

The flaw is an off-by-one error (CWE-193) in the function g_key_file_get_locale_string_list in the gkeyfile.c source file of GLib. When this function processes a key file entry whose locale-specific string list has an empty value, it computes a length that is one byte too long. The subsequent read therefore accesses one byte beyond the end of the allocated string buffer. The out-of-bounds access is a single byte. The outcome depends on memory layout: if the over-read lands within the same page, the process silently reads an irrelevant byte; if it crosses a page boundary into unmapped memory, the access triggers a segmentation fault and the process terminates.

Exploitability

The attack vector is network-based with low complexity. No privileges and no user interaction are required. A public exploit is available. In practice, exploitation requires the target to load a key file whose contents are controlled by the attacker, which means the service must accept key file data from an untrusted source (for example, a configuration file fetched from a remote endpoint, or a file written by an upstream service).

Technical impact

The primary impact is availability: a remote attacker can crash any process that loads a crafted key file via this code path. The secondary impact is a potential one-byte out-of-bounds read, which could leak a single byte of adjacent memory to the attacker if the process does not crash. The record does not describe a reliable information disclosure path, so the realistic impact is denial of service.

Business impact

Any service that parses untrusted key files using the affected GLib version can be crashed by an attacker who controls the file contents. Because GLib is a foundational library, the exposure is broad: desktop sessions, package managers, display servers, and container runtimes on affected Red Hat Enterprise Linux releases and OpenShift nodes all link against it. A crash in a critical system process can take down services, interrupt user sessions, or trigger failover in a cluster. The limited read of one byte beyond the buffer could, in principle, expose a small amount of adjacent memory, though the record does not confirm exploitable information disclosure. Organisations running affected RHEL or OpenShift releases should treat this as a patching priority.

Remediation

Apply the vendor-supplied patch to the glib2 package on affected systems. Red Hat has published errata for all affected RHEL and OpenShift releases. For OpenShift clusters, update the RHCOS image to the patched release. No workaround is described in the record; the fix is a single-line bounds correction in the parser.

Detection

Look for processes that have recently crashed with a segmentation fault in a context where they loaded a key file (GKeyFile format). Check system logs for unexpected process terminations in services that consume configuration in key file format. In container environments, review node logs for RHCOS or application pod crashes that coincide with key file parsing. If a service accepts key file contents from remote sources, inspect those sources for entries with empty locale string list values, which is the triggering condition.

Sources (94)
Learn more

Run an in-depth assessment with complete web risk management

CyStack VulnScan continuously discovers assets, validates vulnerabilities, and helps security teams prioritize remediation across the organization.