CVE-2024-26689·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: ceph: prevent use-after-free in encode_cap_msg() In fs/ceph/caps.c, in encode_cap_msg(), "use after free" error was caught by KASAN at this line - 'ceph_buffer_get(arg->xattr_buf);'. This implies before the refcount could be increment here, it was freed. In same file, in "handle_cap_grant()" refcount is decremented by this line - 'ceph_buffer_put(ci->i_xattrs.blob);'. It appears that a race occurred and resource was freed by the latter line before the former line could increment it. encode_cap_msg() is called by __send_cap() and __send_cap() is called by ceph_check_caps() after calling __prep_cap(). __prep_cap() is where arg->xattr_buf is assigned to ci->i_xattrs.blob. This is the spot where the refcount must be increased to prevent "use after free" error.
- Severity
- high
- Software
- Kernel
- Fixed in
- 6.7.6
- Published
- 2024-04-03
Affected versions
From: 6.7
Until: 6.7.6
Fixed in: 6.7.6
How to fix this CVE
Update your Linux kernel to version 6.7.6 or later to resolve a use-after-free vulnerability in the Ceph filesystem capability messaging code. This race condition could allow local privilege escalation if multiple kernel subsystems access shared buffer resources concurrently. Apply the patch immediately on systems running kernel versions 6.7 through 6.7.5.
sudo dnf update kernel kernel-develDefensia detects this vulnerability
How to check if you are affected
- Run 'uname -r' to check your current kernel version. If it shows 6.7.0 through 6.7.5, you are vulnerable.
- Check if Ceph filesystem is mounted with 'mount | grep ceph'. If present, the vulnerable code path can be triggered.
- Search kernel logs for KASAN warnings with 'dmesg | grep -i "use-after-free\|kasan\|ceph"' to detect exploitation attempts.
- After patching, verify the new kernel version with 'uname -r' and confirm it is 6.7.6 or later, then reboot if needed.
FAQ
What is CVE-2024-26689?
CVE-2024-26689 is a use-after-free vulnerability in the Linux kernel's Ceph filesystem driver where a reference-counted buffer can be freed by one kernel path while another path attempts to increment its reference count, leading to memory corruption.
Is CVE-2024-26689 being actively exploited?
No, according to CISA's KEV catalog, CVE-2024-26689 is not currently being exploited in the wild, and no public proof-of-concept exploits are available.
What versions of Kernel are affected by CVE-2024-26689?
Linux kernel versions 6.7 through 6.7.5 are affected. Version 6.7.6 and later contain the fix.
How do I check if my server is vulnerable to CVE-2024-26689?
Run 'uname -r' and check if the output is between 6.7 and 6.7.5; also verify Ceph is in use with 'mount | grep ceph' or 'lsmod | grep ceph'.
Does Defensia detect CVE-2024-26689?
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-2024-26689 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/70e329b440762390258a6fe8c0de93c9fdd56c77
- https://git.kernel.org/stable/c/7958c1bf5b03c6f1f58e724dbdec93f8f60b96fc
- https://git.kernel.org/stable/c/8180d0c27b93a6eb60da1b08ea079e3926328214
- https://git.kernel.org/stable/c/ae20db45e482303a20e56f2db667a9d9c54ac7e7
- https://git.kernel.org/stable/c/cda4672da1c26835dcbd7aec2bfed954eda9b5ef
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2024-26689. Free for 1 server.
Get started free