CVE-2019-25162·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: i2c: Fix a potential use after free Free the adap structure only after we are done using it. This patch just moves the put_device() down a bit to avoid the use after free. [wsa: added comment to the code, added Fixes tag]
- Severity
- high
- Software
- Kernel
- Fixed in
- 5.19.2
- Published
- 2024-02-26
Affected versions
From: 5.19.0
Until: 5.19.2
Fixed in: 5.19.2
How to fix this CVE
Update your Linux kernel to version 5.19.2 or later to resolve a use-after-free vulnerability in the i2c subsystem that could allow local privilege escalation. The i2c adapter structure was being freed prematurely while still in use, creating a window for memory corruption. Apply the kernel update immediately on all affected systems.
sudo dnf update kernelDefensia detects this vulnerability
How to check if you are affected
- Step 1: Check your current kernel version with `uname -r` and compare against the affected range 5.19.0-5.19.2
- Step 2: Verify i2c device exposure by running `lsmod | grep i2c` to confirm the i2c modules are loaded on your system
- Step 3: Search kernel logs for i2c-related crashes or memory faults using `sudo dmesg | grep -i 'i2c\|use.after.free\|UAF'`
- Step 4: After patching, reboot the system with `sudo reboot` and confirm the new kernel version with `uname -r` to ensure 5.19.2 or later is running
FAQ
What is CVE-2019-25162?
This is a use-after-free vulnerability in the Linux kernel's i2c (Inter-Integrated Circuit) bus driver where the adapter device structure was being freed while still being referenced by other code paths, potentially allowing local attackers with low privileges to cause a denial of service or gain elevated privileges.
Is CVE-2019-25162 being actively exploited?
No, according to CISA's Known Exploited Vulnerabilities catalog, this vulnerability is not currently being actively exploited in the wild, though the high CVSS score warrants prompt patching.
What versions of Kernel are affected by CVE-2019-25162?
Linux kernel versions 5.19.0, 5.19.1, and 5.19.2-rc versions are affected. The vulnerability was patched in 5.19.2 release.
How do I check if my server is vulnerable to CVE-2019-25162?
Run `uname -r` to display your kernel version. If the output shows 5.19.0 or 5.19.1, your system is vulnerable and requires an immediate kernel update to 5.19.2 or newer.
Does Defensia detect CVE-2019-25162?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the Linux kernel is installed on a monitored server, CVE-2019-25162 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/12b0606000d0828630c033bf0c74c748464fe87d
- https://git.kernel.org/stable/c/23a191b132cd87f746c62f3dc27da33683d85829
- https://git.kernel.org/stable/c/35927d7509ab9bf41896b7e44f639504eae08af7
- https://git.kernel.org/stable/c/81cb31756888bb062e92d2dca21cd629d77a46a9
- https://git.kernel.org/stable/c/871a1e94929a27bf6e2cd99523865c840bbc2d87
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2019-25162. Free for 1 server.
Get started free