# CVE-2026-81879: radare2 heap out-of-bounds read in ELF PN_XNUM handling

Source: https://junglewise.ai/threats/cve-2026-81879-radare2-is-a-unix-like-reverse-engineering-framework-and-command  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-09-22. Updated: 2026-09-26  
License: CC BY 4.0 with a link back

CVE-2026-81879 · Severity: medium · CVSS 5.5 · Published 2026-09-22

radare2 is a reverse engineering framework used to analyze binary files and malware. When processing a specially crafted ELF executable file, a mismatch between the reported and actual program header count causes the parser to read far beyond allocated memory, triggering a crash. An attacker can craft a malicious ELF file to deny service to analysts and security tools using radare2.

Technologies: [Radare2](https://junglewise.ai/threats/technologies/radare2), [Radareorg Radare2](https://junglewise.ai/threats/technologies/radareorg-radare2). Vendors: [Radare](https://junglewise.ai/threats/vendors/radare), [Radareorg](https://junglewise.ai/threats/vendors/radareorg).

## Quick answers

**Is CVE-2026-81879 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-81879 being exploited in the wild.

**How severe is CVE-2026-81879?** Medium severity, with a CVSS score of 5.5, published 22 September 2026.

**Which products and versions are affected?** Radareorg Radare2 prior to 6.2.0.

**Is there a fix for CVE-2026-81879?** A patch was published on 2026-07-06: Fix commit 9449b07 merged to master Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-81879 attacked?** It is attacked with local access, in a software library.

**Am I affected by CVE-2026-81879?** Check whether you run Radare2 or Radareorg Radare2 at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

The vulnerability occurs in the ELF parser's handling of PN_XNUM (0xffff sentinel) program header counts. When e_phnum is set to 0xffff, the parser reads the true count from shdr[0].sh_info and allocates a buffer for that smaller count, but fails to update e_phnum itself. Consuming loops then iterate 0xffff times over the small allocation, causing heap out-of-bounds reads up to ~3.6 MB. The issue is triggered by opening a crafted ELF file and affects multiple parsing functions that iterate over program headers.

## Affected products

- radareorg radare2 prior to 6.2.0

## Timeline

- 2026-09-22: disclosed
- 2026-07-06: patched: Fix commit 9449b07 merged to master

## References

- [https://github.com/radareorg/radare2/commit/9449b07579c19b6b187c1a0918fbec2cef1a036e](https://github.com/radareorg/radare2/commit/9449b07579c19b6b187c1a0918fbec2cef1a036e)
- [https://github.com/radareorg/radare2/issues/26223](https://github.com/radareorg/radare2/issues/26223)

## Related threats

- [radare2 command execution via crafted binary format](https://junglewise.ai/threats/cve-2026-108387-radare2-is-a-unix-like-reverse-engineering-framework-and-command)
- [radare2 sandbox policy enforcement bypass in HTTP handler](https://junglewise.ai/threats/cve-2026-112077-a-vulnerability-was-detected-in-radareorg-radare2-6-2-0-6-2-2)
- [radare2 unbounded allocation in dmp64 parser](https://junglewise.ai/threats/cve-2026-81886-radare2-is-a-unix-like-reverse-engineering-framework-and-command)
- [radare2 infinite loop in NE relocation parser](https://junglewise.ai/threats/cve-2026-81885-radare2-is-a-unix-like-reverse-engineering-framework-and-command)
- [radare2 is a UNIX-like reverse engineering framework and command-line toolset. Prior to 6.2.0, radare2's binary…](https://junglewise.ai/threats/cve-2026-81882-radare2-is-a-unix-like-reverse-engineering-framework-and-command)
