CVE-2019-8354
Medium · 5.0CVSS
5.0
EPSS
1.6%
Published
Feb 15, 2019
CISA due date
—
Cloudanix analysis
A bug in widely used audio conversion software can make programs crash when they try to handle certain sound files.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Denial Of Service
- Component
- Application
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Integer overflow during multiplication passed to malloc in lsx_make_lpf results in allocation of a buffer smaller than required, enabling subsequent out-of-bounds writes on the heap.
Why it matters to the business
Systems that process untrusted audio files may experience crashes or unexpected behavior, interrupting media workflows and requiring emergency patching or workarounds.
How an attack unfolds
An attacker supplies a specially crafted audio file or effect parameter to the vulnerable SoX binary; when the low-pass filter code path executes, the integer overflow produces an undersized heap buffer that is then overwritten during normal processing.
How to fix it
Upgrade SoX to a version containing the corrected lsx_make_lpf implementation; rebuild and redeploy any locally compiled packages; replace affected packages in Debian and Ubuntu distributions with patched builds once available.
How to confirm the fix worked
Run the affected binary against a regression test set containing large filter parameters and confirm absence of crashes or sanitizer violations; verify package versions match known fixed releases; inspect build logs for updated effect_i_dsp.c.
Typical attack path
- Identify a target system running an affected SoX version that processes user-supplied audio
- Craft an input file or command-line arguments that reaches lsx_make_lpf with large multiplication operands
- Trigger allocation of the undersized buffer
- Perform subsequent writes that corrupt heap metadata or adjacent objects
- Achieve denial of service or, with additional primitives, arbitrary code execution
How to detect it
Review process execution logs and command-line history for invocations of sox or play with effect flags that exercise i_dsp; examine core dumps or heap sanitizer reports from crashes occurring during audio effect processing; correlate with file-system timestamps of processed audio files.
What your security team should do
- Prioritize patching SoX in any media-processing or build pipelines that accept external audio
- Restrict execution of sox to trusted inputs until updates are applied
- Add SoX to the organization's vulnerability scanning inventory for ongoing monitoring
The record
An issue was discovered in SoX 14.4.2. lsx_make_lpf in effect_i_dsp.c has an integer overflow on the result of multiplication fed into malloc. When the buffer is allocated, it is smaller than expected, leading to a heap-based buffer overflow.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:11 | sox | 0 | 14.4.2+git20190427-1 |
| Debian:12 | sox | 0 | 14.4.2+git20190427-1 |
| Debian:13 | sox | 0 | 14.4.2+git20190427-1 |
| Debian:8 | sox | 0 | 14.4.1-5+deb8u4 |
| Mageia:7 | sox | 0 | 14.4.3-0.git20200117.1.mga7 |
| Ubuntu:16.04:LTS | sox | 0 | 14.4.1-5+deb8u4ubuntu0.1 |
| Ubuntu:18.04:LTS | sox | 0 | 14.4.2-3ubuntu0.18.04.1 |
| Ubuntu:Pro:14.04:LTS | sox | 0 | 14.4.1-3ubuntu1.1+esm1 |
Related vulnerabilities
- CVE-2023-26590 A floating point exception vulnerability was found in sox, in the lsx_aiffstartwrite… Also affects sox
- CVE-2023-32627 A floating point exception vulnerability was found in sox, in the read_samples function… Also affects sox
- CVE-2021-33844 A floating point exception (divide-by-zero) issue was discovered in SoX in functon… Also affects sox
- CVE-2022-31651 In SoX 14.4.2, there is an assertion failure in rate_init in rate.c in libsox.a. Also affects sox
- CVE-2022-31650 In SoX 14.4.2, there is a floating-point exception in lsx_aiffstartwrite in aiff.c in… Also affects sox
- CVE-2021-40426 A heap-based buffer overflow vulnerability exists in the sphere.c start_read()… Also affects sox
- CVE-2004-0557 Multiple buffer overflows in the st_wavstartread function in wav.c for Sound eXchange… Also affects sox
- CVE-2026-110264 An issue has been discovered in GitLab CE/EE affecting all versions from 7.0 before… CWE-190