CVE-2025-6052 Glib: integer overflow in g_string_maybe_expand() leading to potential buffer overflow in glib gstring

Low 3.7 Published Updated

An integer overflow in GLib's GString memory management can lead to buffer overflows, causing crashes or potential code execution.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2025-6052?

CVE-2025-6052 is a low-severity vulnerability in Red Hat Enterprise Linux 10, published on 13 Jun 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

A flaw was found in how GLib’s GString manages memory when adding data to strings. If a string is already very large, combining it with more input can cause a hidden overflow in the size calculation. This makes the system think it has enough memory when it doesn’t. As a result, data may be written past the end of the allocated memory, leading to crashes or memory corruption.

Weakness: CWE-190

Which versions are affected by CVE-2025-6052?

3 open source packages ship an affected version, including java, java-min and jre. It affects 1 product.

PackageAffectedFixed in
java BitnamiAll versions1.8.0, 8.0.481
java-min BitnamiAll versions1.8.0, 8.0.481
jre BitnamiAll versions1.8.0, 8.0.481
Linux distribution packages (2)
glib2 SUSE:Linux Micro 6.1All versions2.78.6-slfo.1.1_4.1
glib2 openSUSE:TumbleweedAll versions2.84.3-1.1

Products include Gnome Glib.

How do I fix CVE-2025-6052?

Upgrade java to a fixed version for your release line: 1.8.0 or 8.0.481.

Is CVE-2025-6052 being exploited?

There is no known exploitation of CVE-2025-6052 in the wild and no public exploit code.

Sources

Also known as AZL-63912, BELL-CVE-2025-6052, BIT-java-2025-6052, BIT-java-min-2025-6052, BIT-jre-2025-6052, DEBIAN-CVE-2025-6052 and 12 more.

Is CVE-2025-6052 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free