CVE-2024-26654
ALSA: sh: aica: reorder cleanup operations to avoid UAF bugs
Check your servers for CVE-2024-26654
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2024-26654 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
In the Linux kernel, the following vulnerability has been resolved:
ALSA: sh: aica: reorder cleanup operations to avoid UAF bugs
The dreamcastcard->timer could schedule the spu_dma_work and the spu_dma_work could also arm the dreamcastcard->timer.
When the snd_pcm_substream is closing, the aica_channel will be deallocated. But it could still be dereferenced in the worker thread. The reason is that del_timer() will return directly regardless of whether the timer handler is running or not and the worker could be rescheduled in the timer handler. As a result, the UAF bug will happen. The racy situation is shown below:
(Thread 1) | (Thread 2) snd_aicapcm_pcm_close() | ... | run_spu_dma() //worker | mod_timer() flush_work() | del_timer() | aica_period_elapsed() //timer kfree(dreamcastcard->channel) | schedule_work() | run_spu_dma() //worker ... | dreamcastcard->channel-> //USE
In order to mitigate this bug and other possible corner cases, call mod_timer() conditionally in run_spu_dma(), then implement PCM sync_stop op to cancel both the timer and worker. The sync_stop op will be called from PCM core appropriately when needed.
Severity (CVSS)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- local: the attacker needs local access, or a user has to open a prepared file
- Attack complexity
- low: an attack works without special conditions
- Privileges required
- low: the attacker needs an ordinary user account
- User interaction
- none: nobody has to click or open anything
- Scope
- unchanged: the damage stays inside the vulnerable component
- Impact
- confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)
Exploitation
EPSS 0.26%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 18.8% of all scored CVEs. Scores of 1 Dec 2026.
The assessment of CISA (SSVC, 10 Sep 2024):
- Exploitation
- none: CISA did not find evidence of exploitation or a public proof of concept
- Automatable
- no: each attack takes manual steps
- Technical impact
- partial: limited control or limited data
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before eeb2a2ca0b8de7e1c66afaf719529154e7dc60b2 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 4206ad65a0ee76920041a755bd3c17c6ba59bba2 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before aa39e6878f61f50892ee2dd9d2176f72020be845 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 8c990221681688da34295d6d76cc2f5b963e83f5 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 9d66ae0e7bb78b54e1e0525456c6b54e1d132046 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 61d4787692c1fccdc268ffa7a891f9c149f50901 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before e955e8a7f38a856fc6534ba4e6bffd4d5cc80ac3 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 3c907bf56905de7d27b329afaf59c2fb35d17b04 affected from 198de43d758ca2700e2b52b49c0b189b4931466c, before 051e0840ffa8ab25554d6b14b62c9ab9e4901457
Other versions: unaffected
|
| Linux |
affected 2.6.23 unaffected before 2.6.23 unaffected from 4.19.312 up to and including 4.19.* unaffected from 5.4.274 up to and including 5.4.* unaffected from 5.10.215 up to and including 5.10.* unaffected from 5.15.154 up to and including 5.15.* unaffected from 6.1.84 up to and including 6.1.* unaffected from 6.6.24 up to and including 6.6.* unaffected from 6.7.12 up to and including 6.7.* unaffected from 6.8.3 up to and including 6.8.* unaffected 6.9 and later
Other versions: affected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2024-26654 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2024-26654
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2024-26654
trivy image --scanners vuln IMAGE | grep CVE-2024-26654
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/eeb2a2ca0b8de7e1c66afaf719529154e7dc60b2 git.kernel.org
- https://git.kernel.org/stable/c/4206ad65a0ee76920041a755bd3c17c6ba59bba2 git.kernel.org
- https://git.kernel.org/stable/c/aa39e6878f61f50892ee2dd9d2176f72020be845 git.kernel.org
- https://git.kernel.org/stable/c/8c990221681688da34295d6d76cc2f5b963e83f5 git.kernel.org
- https://git.kernel.org/stable/c/9d66ae0e7bb78b54e1e0525456c6b54e1d132046 git.kernel.org
- https://git.kernel.org/stable/c/61d4787692c1fccdc268ffa7a891f9c149f50901 git.kernel.org
- https://git.kernel.org/stable/c/e955e8a7f38a856fc6534ba4e6bffd4d5cc80ac3 git.kernel.org
- https://git.kernel.org/stable/c/3c907bf56905de7d27b329afaf59c2fb35d17b04 git.kernel.org
- https://git.kernel.org/stable/c/051e0840ffa8ab25554d6b14b62c9ab9e4901457 git.kernel.org
- https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html lists.debian.org
Source: the record CVE-2024-26654 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse