Description
Speex (libspeex) through 1.2.1 contains an out-of-bounds write vulnerability in speex_bits_read_whole_bytes() in libspeex/bits.c that mishandles length truncation for non-owned SpeexBits buffers. Attackers can stream crafted Speex data into buffers set up with speex_bits_init_buffer() or speex_bits_set_bit_buffer() to corrupt heap or stack memory and crash applications.
Published: 2026-10-26
Score: 8.3 High
EPSS: < 1% Very Low
KEV: No
Impact: Out-of-bounds write leading to memory corruption
Action: Patch ASAP
AI Analysis

Impact

Speex (libspeex) through version 1.2.1 contains an out‑of‑bounds write in the function speex_bits_read_whole_bytes(). When the library incorrectly truncates the length for non‑owned SpeexBits buffers, an attacker can write past the end of a buffer. This corrupts heap or stack memory and can cause application crashes or, if an attacker controls the overwritten memory, remote code execution. Based on the description, it is inferred that remote code execution is possible if the attacker can control the overwritten memory. The problem is a classic instance of the CWE‑787 class where a library performs an insecure write beyond the boundary of allocated memory.

Affected Systems

The vulnerability affects the Speex codec library from Xiph.Org, specifically all releases up to and including 1.2.1. Applications that incorporate libspeex and use speex_bits_init_buffer() or speex_bits_set_bit_buffer() for non‑owned buffers are at risk.

Risk and Exploitability

The vulnerability has a CVSS score of 8.3, indicating high severity. No EPSS score is available, so the likelihood of exploitation is currently unknown. It is not listed in the CISA KEV catalog. Based on the description, it is inferred that attackers would need the ability to supply crafted Speex data to a vulnerable process, which can be done over a network stream or other input channel. The flaw can be triggered by an attacker who can influence the input stream, potentially leading to memory corruption and application crashes or privilege escalation if the attacker can control overwritten memory. Existing systems that stream Speex audio directly to libspeex without additional validation remain in scope.

Generated by OpenCVE AI on October 27, 2026 at 08:08 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Speex to a patched version (e.g., 1.2.2 or later) and rebuild any dependent applications to remove the vulnerability.
  • If an upgrade cannot be performed immediately, avoid using speex_bits_init_buffer() or speex_bits_set_bit_buffer() on data that originates from untrusted sources, and ensure buffers are properly owned and bounded before processing.
  • Implement defensive input validation by checking the length of incoming Speex data and verifying buffer bounds before feeding it to the library, or use an updated API that enforces bounds checking.

Generated by OpenCVE AI on October 27, 2026 at 08:08 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 27 Oct 2026 12:30:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

threat_severity

Moderate


Tue, 27 Oct 2026 04:30:00 +0000

Type Values Removed Values Added
Description Speex (libspeex) through 1.2.1 contains an out-of-bounds write vulnerability in speex_bits_read_whole_bytes() in libspeex/bits.c that mishandles length truncation for non-owned SpeexBits buffers. Attackers can stream crafted Speex data into buffers set up with speex_bits_init_buffer() or speex_bits_set_bit_buffer() to corrupt heap or stack memory and crash applications.
Title Speex through 1.2.1 Out-of-Bounds Write via speex_bits_read_whole_bytes
First Time appeared Xiph
Xiph speex
Weaknesses CWE-787
CPEs cpe:2.3:a:xiph:speex:*:*:*:*:*:*:*:*
Vendors & Products Xiph
Xiph speex
References
Metrics cvssV3_1

{'score': 6.5, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H'}

cvssV4_0

{'score': 8.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-10-26T21:52:40.782Z

Reserved: 2026-10-26T20:23:36.495Z

Link: CVE-2026-116741

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-26T22:16:58.530

Modified: 2026-10-26T22:16:58.530

Link: CVE-2026-116741

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-10-26T21:52:40Z

Links: CVE-2026-116741 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-27T08:15:15Z

Weaknesses