# CVE-2024-2961: Memory corruption in glibc

> A buffer overflow in glibc's iconv function allows attackers to crash applications or potentially execute code via crafted ISO-2022-CN-EXT strings.

- **Severity:** High 7.3 (`CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Local or same network only
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 17 Apr 2024
- **Updated:** 15 Oct 2026
- **Also known as:** ALSA-2024:2722, ALSA-2024:3269, BELL-CVE-2024-2961, CLSA-2024-1717691587, CLSA-2024-1718024371, CLSA-2024-1718790660, DEBIAN-CVE-2024-2961, DLA-3807-1, DSA-5673-1, GHSA-22q4-f5r6-3xqw, MGASA-2024-0147, MINI-3v8j-2v55-pr7r, MINI-xm63-x92f-g2m6, OESA-2024-1843, OESA-2024-1844, OESA-2024-1845, RHSA-2024:2722, RHSA-2024:3269, RLSA-2024:2722, RLSA-2024:3269, SUSE-SU-2024:1375-1, SUSE-SU-2024:1728-1, SUSE-SU-2024:1805-1, UBUNTU-CVE-2024-2961, USN-6737-1, USN-6737-2, openSUSE-SU-2024:13877-1

## What is CVE-2024-2961?

CVE-2024-2961 is a high-severity memory corruption vulnerability in Debian Debian Linux, published on 17 Apr 2024. It can only be exploited from the same machine or local network, with no action from the victim.

### Official description

The iconv() function in the GNU C Library versions 2.39 and older may overflow the output buffer passed to it by up to 4 bytes when converting strings to the ISO-2022-CN-EXT character set, which may be used to crash an application or overwrite a neighbouring variable.

Weakness: CWE-787 (Out-of-bounds Write)

## Which versions are affected by CVE-2024-2961?

It affects 13 products.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `compat-libpthread-nonshared` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `compat-libpthread-nonshared` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-all-langpacks` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-all-langpacks` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-benchtests` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-benchtests` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-common` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-common` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-devel` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-devel` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-doc` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-doc` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-gconv-extra` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-gconv-extra` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-headers` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-headers` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-aa` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-aa` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-af` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-af` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-agr` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-agr` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-ak` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-ak` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-am` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-am` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-an` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-an` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-anp` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-anp` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-ar` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-ar` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-as` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-as` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-ast` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-ast` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |
| `glibc-langpack-ayc` | AlmaLinux:8 | All versions | 2.28-236.el8_9.13 |
| `glibc-langpack-ayc` | AlmaLinux:8 | All versions | 2.28-251.el8_10.1 |

Products: Debian Debian Linux, Gnu Glibc, Netapp Active Iq Unified Manager, Netapp Hci Compute Node, Netapp Hci H300s Firmware, Netapp Hci H410c Firmware, Netapp Hci H410s Firmware, Netapp Hci H500s Firmware, Netapp Hci H610c Firmware, Netapp Hci H610s Firmware, Netapp Hci H615c Firmware, Netapp Hci H700s Firmware, Netapp Ontap Select Deploy Administration Utility.

## How do I fix CVE-2024-2961?

Apply the vendor's patch.

## Is CVE-2024-2961 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-2961 exists.

Public exploit code:

- Exploits for CNEXT (CVE-2024-2961), a buffer overflow in the glibc's iconv() (github_poc): https://github.com/ambionics/cnext-exploits
- CVE-2024–2961 Security Issue Mitigation Script (github_poc): https://github.com/rvzsec/CVE-2024-2961
- This script demonstrates a proof-of-concept (PoC) for exploiting a file read vulnerability in the iconv library, as detailed in Ambionics Security's blog https://www.ambionics.io/blog/iconv-cve-2024-2961-p1. (github_poc): https://github.com/kyotozx/CVE-2024-2961-Remote-File-Read
- CVE-2024-2961 Cnext RCE Exploit with Buddyforms 2.7.7 (github_poc): https://github.com/suce0155/CVE-2024-2961
- Quick mitigation script  (github_poc): https://github.com/mattaperkins/FIX-CVE-2024-2961
- https://github.com/kjdfklha/CVE-2024-2961_poc (github_poc): https://github.com/kjdfklha/CVE-2024-2961_poc

## Other vulnerabilities in Debian Debian Linux

- [CVE-2015-3306](https://insights.sbomify.com/CVE-2015-3306/): ProFTPD Improper Access Control (critical 10.0, exploited in the wild)
- [CVE-2025-49113](https://insights.sbomify.com/CVE-2025-49113/): RoundCube Webmail Deserialization of Untrusted Data (critical 9.9, exploited in the wild)
- [CVE-2026-24061](https://insights.sbomify.com/CVE-2026-24061/): GNU InetUtils Argument Injection (critical 9.8, exploited in the wild)
- [CVE-2025-39682](https://insights.sbomify.com/CVE-2025-39682/): Linux Kernel Improper Check for Unusual or Exceptional Conditions (critical 9.8, exploited in the wild)
- [CVE-2024-9680](https://insights.sbomify.com/CVE-2024-9680/): Mozilla Firefox Use-After-Free (critical 9.8, exploited in the wild)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-2961 and fix it if it is affected.

What it is: CVE-2024-2961 is a high-severity memory corruption vulnerability in Debian Debian Linux, published on 17 Apr 2024. It can only be exploited from the same machine or local network, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-2961 exists.

Affected product: Debian Debian Linux. No package-level version data is available, so check the vendor advisory linked from the reference page.

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2024-2961/ (Markdown: https://insights.sbomify.com/CVE-2024-2961/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2024-2961
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2024-2961
- OSV: https://osv.dev/vulnerability/CVE-2024-2961

---
From sbomify Insights: https://insights.sbomify.com/CVE-2024-2961/
Summaries are generated and may contain mistakes; the official description above is the record.
