# CVE-2024-2494: Libvirt: negative g\_new0 length can lead to unbounded memory allocation

- Priority: **Routine**
- Reason: Not severe (CVSS 6.2, local access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2024-03-21 · Modified: 2026-11-25
- Aliases: MGASA-2024-0114, SUSE-SU-2024:1078-1, SUSE-SU-2024:1083-1, SUSE-SU-2024:1100-1, RHSA-2024:3253, UBUNTU-CVE-2024-2494, DEBIAN-CVE-2024-2494, openSUSE-SU-2024:13796-1
- Record: https://cvemate.com/vulnerability/CVE-2024-2494 · JSON: https://cvemate.com/vulnerability/CVE-2024-2494/json

## Description

```text
A flaw was found in the RPC library APIs of libvirt. The RPC server deserialization code allocates memory for arrays before the non-negative length check is performed by the C API entry points. Passing a negative length to the g_new0 function results in a crash due to the negative length being treated as a huge positive number. This flaw allows a local, unprivileged user to perform a denial of service attack by causing the libvirt daemon to crash.
```

## Signals

- CVSS: 6.2 medium (v3.1, CVE.org) CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- EPSS: 0.39%, percentile 35.227%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 250)

- debian libvirt (Debian): \< 9.0.0-4+deb12u1 \| \< 10.2.0-1
- ubuntu libvirt (Ubuntu): \< 1.2.2-0ubuntu13.1.28+esm2 \| \< 1.3.1-1ubuntu10.31+esm1 \| \< 4.0.0-1ubuntu8.21+esm1 \| \< 6.0.0-0ubuntu8.19 \| \< 8.0.0-1ubuntu7.10 \| \< 10.0.0-2ubuntu8.1
- mageia libvirt (Mageia): \< 9.6.0-1.1.mga9
- opensuse libvirt&distro=openSUSE Leap Micro 5.3 (openSUSE): \< 8.0.0-150400.7.11.2
- opensuse libvirt&distro=openSUSE Leap Micro 5.4 (openSUSE): \< 8.0.0-150400.7.11.2
- opensuse libvirt&distro=openSUSE Tumbleweed (openSUSE): \< 10.1.0-2.1
- redhat hivex (Red Hat): \< 0:1.3.18-23.module+el8.9.0+18724+20190c23
- redhat hivex-debuginfo (Red Hat): \< 0:1.3.18-23.module+el8.9.0+18724+20190c23
- redhat hivex-debugsource (Red Hat): \< 0:1.3.18-23.module+el8.9.0+18724+20190c23
- redhat hivex-devel (Red Hat): \< 0:1.3.18-23.module+el8.9.0+18724+20190c23
- redhat libguestfs (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-appliance (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-bash-completion (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-debuginfo (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-debugsource (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-devel (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-gfs2 (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-gobject (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-gobject-debuginfo (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23
- redhat libguestfs-gobject-devel (Red Hat): \< 1:1.44.0-9.module+el8.9.0+18724+20190c23

## References (first 20 of 26)

- <https://access.redhat.com/errata/RHSA-2024:2560>
- <https://access.redhat.com/errata/RHSA-2024:3253>
- <https://access.redhat.com/security/cve/CVE-2024-2494>
- <https://bugzilla.redhat.com/show_bug.cgi?id=2270115>
- <https://lists.libvirt.org/archives/list/devel@lists.libvirt.org/thread/BKRQXPLPC6B7FLHJXSBQYW7HNDEBW6RJ/>
- <https://lists.debian.org/debian-lts-announce/2024/04/msg00000.html>
- <https://security.netapp.com/advisory/ntap-20240517-0009/>
- <https://advisories.mageia.org/MGASA-2024-0114.html>
- <https://bugs.mageia.org/show_bug.cgi?id=33047>
- <https://lwn.net/Articles/967956/>
- <https://www.suse.com/support/update/announcement/2024/suse-su-20241078-1/>
- <https://bugzilla.suse.com/1221815>
- <https://www.suse.com/security/cve/CVE-2024-2494>
- <https://www.suse.com/support/update/announcement/2024/suse-su-20241083-1/>
- <https://www.suse.com/support/update/announcement/2024/suse-su-20241100-1/>
- <https://bugzilla.suse.com/1221749>
- <https://access.redhat.com/security/updates/classification/#moderate>
- <https://security.access.redhat.com/data/csaf/v2/advisories/2024/rhsa-2024_3253.json>
- <https://www.cve.org/CVERecord?id=CVE-2024-2494>
- <https://nvd.nist.gov/vuln/detail/CVE-2024-2494>

---

Data as of 2026-12-05T04:11:30.825Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
