CVE-2022-49493
ASoC: rt5645: Fix errorenous cleanup order
Check your servers for CVE-2022-49493
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-2022-49493 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:
ASoC: rt5645: Fix errorenous cleanup order
There is a logic error when removing rt5645 device as the function rt5645_i2c_remove() first cancel the &rt5645->jack_detect_work and delete the &rt5645->btn_check_timer latter. However, since the timer handler rt5645_btn_check_callback() will re-queue the jack_detect_work, this cleanup order is buggy.
That is, once the del_timer_sync in rt5645_i2c_remove is concurrently run with the rt5645_btn_check_callback, the canceled jack_detect_work will be rescheduled again, leading to possible use-after-free.
This patch fix the issue by placing the del_timer_sync function before the cancel_delayed_work_sync.
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.27%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 20.3% of all scored CVEs. Scores of 1 Dec 2026.
The assessment of CISA (SSVC, 27 Feb 2025):
- Exploitation
- none: CISA did not find evidence of exploitation or a public proof of concept
- Automatable
- no: each attack takes manual steps
- Technical impact
- total: full control of the component or of its data
Weakness
- CWE-416 Use After Free
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 236d29c5857f02e0a53fdf15d3dce1536c4322ce affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 0941150100173d4eaf3fe08ff4b16740e7c3026f affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before abe7554da62cb489712a54de69ef5665c250e564 affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 1a5a3dfd9f172dcb115072f0aea5e27d3083c20e affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 061a6159cea583f1155f67d1915917a6b9282662 affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 88c09e4812d72c3153afc8e5a45ecac2d0eae3ff affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 453f0920ffc1a28e28ddb9c3cd5562472b2895b0 affected from a6ff8ddcf3f38ec84337e5e7eb3e0e9a73754cf5, before 2def44d3aec59e38d2701c568d65540783f90f2f
Other versions: unaffected
|
| Linux |
affected 4.13 unaffected before 4.13 unaffected from 4.14.283 up to and including 4.14.* unaffected from 4.19.247 up to and including 4.19.* unaffected from 5.4.198 up to and including 5.4.* unaffected from 5.10.121 up to and including 5.10.* unaffected from 5.15.46 up to and including 5.15.* unaffected from 5.17.14 up to and including 5.17.* unaffected from 5.18.3 up to and including 5.18.* unaffected 5.19 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-2022-49493 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2022-49493
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-2022-49493
trivy image --scanners vuln IMAGE | grep CVE-2022-49493
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/236d29c5857f02e0a53fdf15d3dce1536c4322ce git.kernel.org
- https://git.kernel.org/stable/c/0941150100173d4eaf3fe08ff4b16740e7c3026f git.kernel.org
- https://git.kernel.org/stable/c/abe7554da62cb489712a54de69ef5665c250e564 git.kernel.org
- https://git.kernel.org/stable/c/1a5a3dfd9f172dcb115072f0aea5e27d3083c20e git.kernel.org
- https://git.kernel.org/stable/c/061a6159cea583f1155f67d1915917a6b9282662 git.kernel.org
- https://git.kernel.org/stable/c/88c09e4812d72c3153afc8e5a45ecac2d0eae3ff git.kernel.org
- https://git.kernel.org/stable/c/453f0920ffc1a28e28ddb9c3cd5562472b2895b0 git.kernel.org
- https://git.kernel.org/stable/c/2def44d3aec59e38d2701c568d65540783f90f2f git.kernel.org
Source: the record CVE-2022-49493 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse